Skip to content
Snippets Groups Projects
Commit fe37ea5b authored by David Parks's avatar David Parks
Browse files

SL-18790 Fix for transparent objects casting shadows when they ought not.

parent 2ab42449
No related branches found
No related tags found
2 merge requests!3Update to main branch,!2Rebase onto current main branch
......@@ -48,6 +48,24 @@ void main()
discard;
}
#if !defined(IS_FULLBRIGHT)
alpha *= vertex_color.a;
#endif
if (alpha < 0.05) // treat as totally transparent
{
discard;
}
if (alpha < 0.88) // treat as semi-transparent
{
if (fract(0.5*floor(target_pos_x / post_pos.w )) < 0.25)
{
discard;
}
}
frag_color = vec4(1,1,1,1);
#if !defined(DEPTH_CLAMP)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment