fixed HLSL out variables not always being set

This commit is contained in:
myT 2024-07-02 01:19:47 +02:00
parent 26bfe007c1
commit 68d32e69e9

View file

@ -117,6 +117,7 @@ struct ExtinctionCascade
bool ExtinctionAtMip(float3 position, uint mip, out float ext)
{
ext = 0.0;
if(lowestMipLevel == mip)
{
float3 tc0 = AABoxWorldSpaceToTC(position, cameraPosition, textureSize, worldScale[mip + 0]);
@ -196,6 +197,7 @@ struct SunVShadowCascade
bool TransmittanceAtMip(float3 position, uint mip, out float ext)
{
ext = 0.0;
if(lowestMipLevel == mip)
{
float3 tc0 = AABoxWorldSpaceToTC(position, cameraPosition, textureSize, worldScale[mip + 0]);