About ALPHA in spatial shaders

One point about using ALPHA in shaders, just by setting a value to it force the mesh to be part of the non solid drawing pass and can lead to some interesting drawing artifact like overlapping triangles that should not.

It also have some performance impact, especially on the low-end or mid range GPU, but on busy scene it will also have an impact with a high end GPU.

My experience with it is, if you don’t plan to have anything transparent on the mesh, do not set that value, even if you set it to fully opaque.

It is not critical for this course, but I think it is important to know that unless you really need to use transparent mesh using the alpha channel, do not use the ALPHA variable in a spatial shader.

2 Likes

Privacy & Terms