DITHERED tRANSPARENCY

This project was created as a method for optimizing the rendering of transparent objects at runtime. It is meant to be a part of Farbridge Inc.’s institutional codebase, not for any one project but for multiple ones.

UpDown.gif

Discrete Levels

Rather than having a smooth blend from 0 to 1, the dithering method has discrete steps. Transparency is achieved by providing a “chance” for a pixel to be colored based on a lookup matrix.

ZoomIn.gif

Depth

Unlike the usual method of rendering transparent objects in Unity, this shader still writes to the z-buffer, allowing for distance based fading. This way objects do not pop out when at clipping distance and clipping through an object is less jarring.

In continued experimentation and optimization of code I was able to get it to where this shader performed slightly better than normal transparency shaders but with some give and take. Being able to write transparent objects to the depth buffer made room for use with more effects. But, because dithering is performed in screen space object of lower opacity using the same method of rendering will not appear behind more opaque objects, at least in this implementation. The use of screen space also makes this effect a possible pain point in VR for some users by way of its similarity to the screen door effect.