summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2024-11-12 17:26:38 -0600
committerGitHub <noreply@github.com>2024-11-12 15:26:38 -0800
commit2b255535efbce4634cdd2c671f597774e1783372 (patch)
tree24be217e4002dcb9ee7d78df4d305a4740038a68 /indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl
parent13c0708cc70078e5118dd88de57d4ffd52f85024 (diff)
2590 mac intel and radeon pro 5300m horrible fps 2 (#3030)
* OpenGL 3.3 compatibility pass. Fix for FBO driven downscaling corrupting textures. * Increase maximum texture bias, immediately scale down when textures are loaded higher resolution than desired * #2590 Fix for some frame stalls on Intel Macs
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl')
-rw-r--r--indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl3
1 files changed, 2 insertions, 1 deletions
diff --git a/indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl b/indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl
index 410c447c64..b434479511 100644
--- a/indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl
+++ b/indra/newview/app_settings/shaders/class1/deferred/pbrterrainF.glsl
@@ -162,6 +162,7 @@ in vec4[2] vary_coords;
#endif
void mirrorClip(vec3 position);
+vec4 encodeNormal(vec3 norm, float gbuffer_flag);
float terrain_mix(TerrainMix tm, vec4 tms4);
@@ -429,7 +430,7 @@ void main()
#endif
frag_data[0] = max(vec4(pbr_mix.col.xyz, 0.0), vec4(0)); // Diffuse
frag_data[1] = max(vec4(mix_orm.rgb, base_color_factor_alpha), vec4(0)); // PBR linear packed Occlusion, Roughness, Metal.
- frag_data[2] = vec4(tnorm, GBUFFER_FLAG_HAS_PBR); // normal, flags
+ frag_data[2] = encodeNormal(tnorm, GBUFFER_FLAG_HAS_PBR); // normal, flags
frag_data[3] = max(vec4(mix_emissive,0), vec4(0)); // PBR sRGB Emissive
}