diff options
author | Dave Parks <davep@lindenlab.com> | 2011-08-08 15:39:02 -0500 |
---|---|---|
committer | Dave Parks <davep@lindenlab.com> | 2011-08-08 15:39:02 -0500 |
commit | f076bdf609ec1fe114a7d0222a318483c97c7a26 (patch) | |
tree | 93dbd2a949d60daaf6aaa025ca7cf036cf90a929 /indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl | |
parent | f302e119627090c22325df59c40e1762402a08c6 (diff) | |
parent | b9439ac006ac64179180ec2a47f6bd92468de455 (diff) |
merge
Diffstat (limited to 'indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl')
-rw-r--r-- | indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl b/indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl index f49e74406f..72a18c6858 100644 --- a/indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl +++ b/indra/newview/app_settings/shaders/class2/objects/fullbrightShinyV.glsl @@ -13,23 +13,28 @@ uniform vec4 origin; varying float vary_texture_index; +attribute vec4 position; +attribute vec3 normal; +attribute vec4 diffuse_color; +attribute vec2 texcoord0; + void main() { //transform vertex - vec4 vert = vec4(gl_Vertex.xyz,1.0); - vary_texture_index = gl_Vertex.w; - gl_Position = gl_ModelViewProjectionMatrix*vert; - + vec4 vert = vec4(position.xyz,1.0); + vary_texture_index = position.w; vec4 pos = (gl_ModelViewMatrix * vert); - vec3 norm = normalize(gl_NormalMatrix * gl_Normal); + gl_Position = gl_ModelViewProjectionMatrix*vec4(position.xyz, 1.0); + + vec3 norm = normalize(gl_NormalMatrix * normal); vec3 ref = reflect(pos.xyz, -norm); - gl_TexCoord[0] = gl_TextureMatrix[0] * gl_MultiTexCoord0; + gl_TexCoord[0] = gl_TextureMatrix[0] * vec4(texcoord0,0,1); gl_TexCoord[1] = gl_TextureMatrix[1]*vec4(ref,1.0); calcAtmospherics(pos.xyz); - gl_FrontColor = gl_Color; + gl_FrontColor = diffuse_color; gl_FogFragCoord = pos.z; } |