summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1
diff options
context:
space:
mode:
authorRunitai Linden <davep@lindenlab.com>2021-12-08 15:35:25 -0600
committerRunitai Linden <davep@lindenlab.com>2021-12-08 15:35:25 -0600
commit1a6ef9a1fbecadaff00b733c51fd6b980905f102 (patch)
treec49e42662469641ed891561fae356acac12e7063 /indra/newview/app_settings/shaders/class1
parent25e993cd3a961a08d625ac18c31e92a0342a1fe1 (diff)
SL-16468 Fix for crash when enabling highlight transparent (add rigged mesh support to highlight transparent).
Diffstat (limited to 'indra/newview/app_settings/shaders/class1')
-rw-r--r--indra/newview/app_settings/shaders/class1/interface/highlightV.glsl13
1 files changed, 13 insertions, 0 deletions
diff --git a/indra/newview/app_settings/shaders/class1/interface/highlightV.glsl b/indra/newview/app_settings/shaders/class1/interface/highlightV.glsl
index 9bf7b60eb7..0b362cf46c 100644
--- a/indra/newview/app_settings/shaders/class1/interface/highlightV.glsl
+++ b/indra/newview/app_settings/shaders/class1/interface/highlightV.glsl
@@ -31,10 +31,23 @@ ATTRIBUTE vec2 texcoord0;
VARYING vec2 vary_texcoord0;
+#ifdef HAS_SKIN
+mat4 getObjectSkinnedTransform();
+uniform mat4 projection_matrix;
+uniform mat4 modelview_matrix;
+#endif
+
void main()
{
//transform vertex
+#ifdef HAS_SKIN
+ mat4 mat = getObjectSkinnedTransform();
+ mat = modelview_matrix * mat;
+ vec4 pos = mat * vec4(position.xyz,1.0);
+ gl_Position = projection_matrix * pos;
+#else
gl_Position = modelview_projection_matrix * vec4(position.xyz, 1.0);
+#endif
vary_texcoord0 = (texture_matrix0 * vec4(texcoord0,0,1)).xy;
}