diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-09-28 22:24:12 +0300 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2020-09-28 22:24:12 +0300 |
commit | 32cb17e3bb86e1d3e7b945f49aa39df7868059ce (patch) | |
tree | 04c2823be5069e50ccb3363a28c4df2e48ec8cea /indra/newview/app_settings/shaders/class1/objects/simpleV.glsl | |
parent | 7f2388194136fc45d204f09fe63a6bd32d7e99ff (diff) | |
parent | bac6652cdcd2d8333df04c3ebd3a6a7b752328b3 (diff) |
Merge branch 'master' into DRTVWR-513-maint
# Conflicts:
# indra/newview/llgroupmgr.cpp
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/objects/simpleV.glsl')
-rw-r--r-- | indra/newview/app_settings/shaders/class1/objects/simpleV.glsl | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/indra/newview/app_settings/shaders/class1/objects/simpleV.glsl b/indra/newview/app_settings/shaders/class1/objects/simpleV.glsl index a59bd9c0a6..9ef7704b70 100644 --- a/indra/newview/app_settings/shaders/class1/objects/simpleV.glsl +++ b/indra/newview/app_settings/shaders/class1/objects/simpleV.glsl @@ -1,4 +1,4 @@ -/** +/** * @file simpleV.glsl * * $LicenseInfo:firstyear=2007&license=viewerlgpl$ @@ -28,6 +28,9 @@ uniform mat4 texture_matrix0; uniform mat4 modelview_matrix; uniform mat4 modelview_projection_matrix; +// render_hud_attachments() -> HUD objects set LLShaderMgr::NO_ATMO; used in LLDrawPoolAlpha::beginRenderPass() +uniform int no_atmo; + ATTRIBUTE vec3 position; void passTextureIndex(); ATTRIBUTE vec2 texcoord0; @@ -46,19 +49,23 @@ void main() { //transform vertex vec4 vert = vec4(position.xyz,1.0); - passTextureIndex(); - vec4 pos = (modelview_matrix * vert); gl_Position = modelview_projection_matrix*vec4(position.xyz, 1.0); + + passTextureIndex(); vary_texcoord0 = (texture_matrix0 * vec4(texcoord0, 0, 1)).xy; - - - - vec3 norm = normalize(normal_matrix * normal); - calcAtmospherics(pos.xyz); + // SL-9632 HUDs are affected by Atmosphere + if (no_atmo == 1) + { + vertex_color = diffuse_color; + } + else + { + vec4 pos = (modelview_matrix * vert); + vec3 norm = normalize(normal_matrix * normal); - vec4 color = calcLighting(pos.xyz, norm, diffuse_color); - vertex_color = color; + calcAtmospherics(pos.xyz); - + vertex_color = calcLighting(pos.xyz, norm, diffuse_color); + } } |