- Timestamp:
- 09/01/08 08:58:38 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/globillum.cg
r2887 r2891 29 29 30 30 31 float2 reflect(float2 pt, float2 n)31 float2 myreflect(float2 pt, float2 n) 32 32 { 33 33 // distance to plane … … 67 67 for (int i = 0; i < NUM_SAMPLES; i ++) 68 68 { 69 float2 offset = samples[i]; 69 //float2 offset = samples[i]; 70 float3 offset = float3(samples[i], 0); 70 71 71 72 //sample noisetex; r stores costheta, g stores sintheta 72 //float2 mynoise = tex2D(noiseTexture, IN.texCoord.xy * noiseMultiplier).xy * 2.0f - 1.0f;73 float 2 mynoise = tex2D(noiseTexture, IN.texCoord.xy * noiseMultiplier).xy;73 //float2 mynoise = tex2D(noiseTexture, IN.texCoord.xy * noiseMultiplier).xy; 74 float3 mynoise = float3(tex2D(noiseTexture, IN.texCoord.xy * noiseMultiplier).xy, 0); 74 75 75 76 // rotation … … 133 134 // expand normal 134 135 float3 normal = normalize(norm.xyz); 136 135 137 /// the current view direction 136 float3 viewDir = normalize(IN.view * 2.0f - float3(1.0f));138 float3 viewDir;// = normalize(IN.view); 137 139 138 140 // the current world position
Note: See TracChangeset
for help on using the changeset viewer.