diff options
author | Runitai Linden <davep@lindenlab.com> | 2021-12-17 09:26:44 -0600 |
---|---|---|
committer | Runitai Linden <davep@lindenlab.com> | 2021-12-17 09:26:44 -0600 |
commit | dd032467357a4aaf69c752c13e53122aff6c4755 (patch) | |
tree | af822bcc384efeb554d7de96f70f189e332f2fe7 /indra/newview/app_settings/shaders/class1 | |
parent | 828e58432981e7c256618bd293f77906abaae699 (diff) |
SL-16478 Fix for octree and render batch debug display not working with rigged meshes.
Diffstat (limited to 'indra/newview/app_settings/shaders/class1')
-rw-r--r-- | indra/newview/app_settings/shaders/class1/interface/debugSkinnedV.glsl | 41 | ||||
-rw-r--r-- | indra/newview/app_settings/shaders/class1/interface/debugV.glsl | 13 |
2 files changed, 13 insertions, 41 deletions
diff --git a/indra/newview/app_settings/shaders/class1/interface/debugSkinnedV.glsl b/indra/newview/app_settings/shaders/class1/interface/debugSkinnedV.glsl deleted file mode 100644 index 74f22aec4f..0000000000 --- a/indra/newview/app_settings/shaders/class1/interface/debugSkinnedV.glsl +++ /dev/null @@ -1,41 +0,0 @@ -/** - * @file debugSkinnedV.glsl - * - * $LicenseInfo:firstyear=2021&license=viewerlgpl$ - * Second Life Viewer Source Code - * Copyright (C) 2011, Linden Research, Inc. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; - * version 2.1 of the License only. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * - * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA - * $/LicenseInfo$ - */ - -uniform mat4 projection_matrix; -uniform mat4 modelview_matrix; - -mat4 getObjectSkinnedTransform(); - -ATTRIBUTE vec3 position; - -void main() -{ - mat4 mat = getObjectSkinnedTransform(); - mat = modelview_matrix * mat; - vec3 pos = (mat*vec4(position.xyz, 1.0)).xyz; - - gl_Position = projection_matrix*vec4(pos, 1.0); -} - diff --git a/indra/newview/app_settings/shaders/class1/interface/debugV.glsl b/indra/newview/app_settings/shaders/class1/interface/debugV.glsl index f4d704577a..153998f1d5 100644 --- a/indra/newview/app_settings/shaders/class1/interface/debugV.glsl +++ b/indra/newview/app_settings/shaders/class1/interface/debugV.glsl @@ -27,8 +27,21 @@ uniform mat4 modelview_projection_matrix; ATTRIBUTE vec3 position; +#ifdef HAS_SKIN +mat4 getObjectSkinnedTransform(); +uniform mat4 projection_matrix; +uniform mat4 modelview_matrix; +#endif + void main() { +#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 } |