Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Reputeless committed Feb 3, 2024
1 parent 1319566 commit 70d58dd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ float CalculateShadow(vec3 worldPosition)
{
vec4 projectedPosition = (vec4(worldPosition, 1.0) * g_worldToProjectedShadow);

if (any(greaterThan(abs(projectedPosition.xyz - clamp(projectedPosition.xyz, 0.0, 1.0)), vec3(0.0))))
if (any(notEqual(clamp(projectedPosition.xyz, 0.0, 1.0), projectedPosition.xyz)))
{
return 1.0;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ float CalculateShadow(vec3 worldPosition)
{
vec4 projectedPosition = (vec4(worldPosition, 1.0) * g_worldToProjectedShadow);

if (any(greaterThan(abs(projectedPosition.xyz - clamp(projectedPosition.xyz, 0.0, 1.0)), vec3(0.0))))
if (any(notEqual(clamp(projectedPosition.xyz, 0.0, 1.0), projectedPosition.xyz)))
{
return 1.0;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ float CalculateShadow(vec3 worldPosition)
{
vec4 projectedPosition = (vec4(worldPosition, 1.0) * g_worldToProjectedShadow);

if (any(greaterThan(abs(projectedPosition.xyz - clamp(projectedPosition.xyz, 0.0, 1.0)), vec3(0.0))))
if (any(notEqual(clamp(projectedPosition.xyz, 0.0, 1.0), projectedPosition.xyz)))
{
return 1.0;
}
Expand Down

0 comments on commit 70d58dd

Please sign in to comment.