Changeset 2368 for GTP/trunk/App/Demos/Illum/Ogre/Media/materials
- Timestamp:
- 05/12/07 14:22:06 (18 years ago)
- Location:
- GTP/trunk/App/Demos/Illum/Ogre/Media/materials
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Illum/Ogre/Media/materials/GTPCaustic/GTPCaustic.hlsl
r2357 r2368 1 #include ".\\dummy.hlsl"2 3 1 struct Shaded_OUT 4 2 { -
GTP/trunk/App/Demos/Illum/Ogre/Media/materials/GTPCaustic/GTPCaustic.material
r2337 r2368 128 128 fragment_program_ref GTP/EnvMap/Localized_Refraction_PS 129 129 { 130 130 param_named_auto cameraPos camera_position 131 131 param_named lastCenter float3 0 0 0 132 132 param_named sFresnel float 0.1 133 <<<<<<< .mine134 133 param_named sRefraction float 0.85 135 ======= 136 param_named sRefraction float 0.8 137 >>>>>>> .r2314 134 138 135 } 139 136 //Cube map for reflections and refractions -
GTP/trunk/App/Demos/Illum/Ogre/Media/materials/programs/GameTools_Blur.hlsl
r2138 r2368 1 #define samplesU 72 #define samplesV 71 #define samplesU 3 2 #define samplesV 3 3 3 4 4 struct VS_INPUT { … … 67 67 uniform float height, 68 68 uniform float face ) : COLOR 69 { 70 69 { 70 /* 71 71 float2 pixel = float2(2.0 / width, 2.0 / height); 72 72 float2 uv = IN.Position + pixel * 0.5; … … 89 89 } 90 90 91 92 sum /= samplesU * samplesV; 91 */ 92 float pixel = 2.0 / width; 93 float2 uv = IN.Position; 94 float3 u; 95 float3 v; 96 float3 pos; 97 if (face == 0){u = float3(0,0,-1); v = float3(0,1,0); pos = float3(1,uv.y,-uv.x);} 98 if (face == 1){u = float3(0,0,1); v = float3(0,1,0); pos = float3(-1,uv.y,uv.x);} 99 if (face == 2){u = float3(1,0,0); v = float3(0,0,-1); pos = float3(uv.x,1,-uv.y);} 100 if (face == 3){u = float3(1,0,0); v = float3(0,0,1); pos = float3(uv.x,-1,uv.y);} 101 if (face == 4){u = float3(1,0,0); v = float3(0,1,0); pos = float3(uv.x,uv.y,1);} 102 if (face == 5){u = float3(-1,0,0); v = float3(0,1,0); pos = float3(-uv.x,uv.y,-1);} 103 u *= pixel; 104 v *= pixel; 105 float4 sum = float4(0,0,0,0); 106 sum += texCUBE(Texture, pos); 107 sum += texCUBE(Texture, pos + u); 108 sum += texCUBE(Texture, pos + v); 109 sum += texCUBE(Texture, pos + u + v); 110 sum /= 4.0; 93 111 94 112 return sum;
Note: See TracChangeset
for help on using the changeset viewer.