Files
UnrealEngine/Engine/Binaries/ThirdParty/MaterialX/libraries/stdlib/genglsl/mx_aastep.glsl
2025-05-18 13:04:45 +08:00

6 lines
200 B
GLSL

float mx_aastep(float threshold, float value)
{
float afwidth = length(vec2(dFdx(value), dFdy(value))) * 0.70710678118654757;
return smoothstep(threshold-afwidth, threshold+afwidth, value);
}