We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8f960f8 commit a5fc4c9Copy full SHA for a5fc4c9
1 file changed
packages/shader-shaderlab/src/shaders/shadingPBR/BTDF.glsl
@@ -23,6 +23,9 @@
23
24
// Sample the opaque texture to get the transmitted light
25
vec3 refractionTransmitted = texture2D(camera_OpaqueTexture, refractionCoords).rgb;
26
+ #ifndef ENGINE_IS_COLORSPACE_GAMMA
27
+ refractionTransmitted = gammaToLinear(vec4(refractionTransmitted, 1.0)).rgb;
28
+ #endif
29
refractionTransmitted *= brdfData.diffuseColor;
30
31
// Use specularFGD as an approximation of the fresnel effect
0 commit comments