Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

https://github.com/gkjohnson/unity-dithered-transparency-shader

Unity material and shader for applying clipped, dithered transparency
https://github.com/gkjohnson/unity-dithered-transparency-shader

3d amplify-shader-editor dither graphics rendering shaderforge shaders transparency unity unity3d

Last synced: 4 months ago
JSON representation

Unity material and shader for applying clipped, dithered transparency

Lists

README

        

# unity-dithered-transparency-shader

![example](./docs/example.gif)

Unity shader to enable a dithered transparency when rendering transparent objects

## Use

Uses the material's alpha to determine whether a pixel should be discarded or not. Either a dither matrix or dither texture can be used.

## Dither Options
**Dither Texture**

Texture defining the dither pattern. The "red" channel is used from the texture to compare against the materials alpha.

**Dither Scale**

The scale of the dither texture in screen-space pixels.

## Extending and Reuse
The functions for performing the dither effect are available in the [Dither Functions.cginc](./Assets/DitherFunctions/Shaders/Dither%20Functions.cginc) so they can easily be added to and used with other shaders and functions.

### In Visual Shader Builders

[Amplify Shader Editor](/docs/AmplifyShaderEditor.md)

[ShaderForge](/docs/ShaderForge.md)