orels1 / orels-Unity-Shaders

A collection of practical Unity shaders for your next project
https://shaders.orels.sh
Other
168 stars 13 forks source link

Add 2-Pass Transparency Toon shader #35

Closed orels1 closed 11 months ago

orels1 commented 11 months ago

2-Pass Transparency is very common in avatar shaders, since you often need to have something like semi-transparent hair together with outlines and other things.

Non-convex meshes are ill-suited for regular transparency as they will encounter sorting issues. Adding a separate pass that renders backfaces only allows you to separate the two and create a stable mesh that can act both as a transparent and an opaque object without issue