summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/objects/bumpV.glsl
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2024-06-15 18:20:47 +0300
committerGitHub <noreply@github.com>2024-06-15 18:20:47 +0300
commit847a8458ecbcefd989a02c727e50f96c606d9d39 (patch)
tree1561a55fe1e62356089d4912cd8216cc15b57e09 /indra/newview/app_settings/shaders/class1/objects/bumpV.glsl
parentc4fc76efefd12c7cb1224dc8a748da2958f4a7f0 (diff)
parentbfadb935560003e94197a0c9532a7ba086c6720a (diff)
Merge pull request #1774 from secondlife/marchcat/b-merge
Release (Materials featurette) -> Maint B sync
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/objects/bumpV.glsl')
-rw-r--r--indra/newview/app_settings/shaders/class1/objects/bumpV.glsl5
1 files changed, 4 insertions, 1 deletions
diff --git a/indra/newview/app_settings/shaders/class1/objects/bumpV.glsl b/indra/newview/app_settings/shaders/class1/objects/bumpV.glsl
index 834c20e14d..95cdfb6fae 100644
--- a/indra/newview/app_settings/shaders/class1/objects/bumpV.glsl
+++ b/indra/newview/app_settings/shaders/class1/objects/bumpV.glsl
@@ -23,6 +23,7 @@
* $/LicenseInfo$
*/
+uniform mat4 modelview_matrix;
uniform mat4 texture_matrix0;
uniform mat4 modelview_projection_matrix;
@@ -32,11 +33,11 @@ in vec2 texcoord1;
out vec2 vary_texcoord0;
out vec2 vary_texcoord1;
+out vec3 vary_position;
#ifdef HAS_SKIN
mat4 getObjectSkinnedTransform();
uniform mat4 projection_matrix;
-uniform mat4 modelview_matrix;
#endif
void main()
@@ -46,8 +47,10 @@ void main()
mat4 mat = getObjectSkinnedTransform();
mat = modelview_matrix * mat;
vec4 pos = mat * vec4(position.xyz, 1.0);
+ vary_position = pos.xyz;
gl_Position = projection_matrix * pos;
#else
+ vary_position = (modelview_matrix * vec4(position.xyz, 1.0)).xyz;
gl_Position = modelview_projection_matrix*vec4(position.xyz, 1.0);
#endif
vary_texcoord0 = (texture_matrix0 * vec4(texcoord0,0,1)).xy;