take ibl amount into account for translucent opacity

This commit is contained in:
AzaezelX 2025-12-13 20:52:36 -06:00
parent 9f29bee45f
commit fad8e12667
4 changed files with 12 additions and 10 deletions

View file

@ -605,10 +605,11 @@ vec4 computeForwardProbes(Surface surface,
finalColor *= surface.ao;
if(isCapturing == 1)
return vec4(lerp((finalColor), surface.baseColor.rgb,surface.metalness),0);
return vec4(lerp((finalColor), surface.baseColor.rgb,surface.metalness),surface.baseColor.a);
else
{
return vec4(finalColor, 0);
float reflectionOpacity = min(max(surface.baseColor.a,length(specular+irradiance)),1.0);
return vec4(finalColor, reflectionOpacity);
}
}

View file

@ -610,10 +610,11 @@ float4 computeForwardProbes(Surface surface,
finalColor *= surface.ao;
if(isCapturing == 1)
return float4(lerp((finalColor), surface.baseColor.rgb,surface.metalness),0);
return float4(lerp((finalColor), surface.baseColor.rgb,surface.metalness),surface.baseColor.a);
else
{
return float4(finalColor, 0);
float reflectionOpacity = min(max(surface.baseColor.a,length(specular+irradiance)),1.0);
return float4(finalColor, reflectionOpacity);
}
}