Kamali Transition by smkplus - 3

Shaders & Effects

Unity Shader transition between panels

Unity 2018.4.5f1Unknown LicenseUpdated 34 days agoCreated on January 25th, 2020
Go to source

KamaliTransition

I made this by using stencil buffer

Record_2020_01_25_23_27_26_68

Stencil Op/Comparison Values

Comparison Functions

0 - Always
1 - Never
2 - Less
3 - Equal
4 - LEqual
5 - Greater
6 - NotEqual
7 - GEqual
8 - Always // (This is the default for the UI shaders so I suspect this one is technically the 'correct' Always, but any value beyond it will also count as Always)

Stencil Operations

0 - Keep
1 - Zero
2 - Replace
3 - IncrSat
4 - DecrSat
5 - Invert
6 - IncrWrap
7 - DecrWrap

References:

unity forum & khronos

I explained more about UI stencil Buffer here

Adding Enum to Inspector

change your properties like this:

[Enum(UnityEngine.Rendering.CompareFunction)] _StencilComp ("Stencil Comparison", Int) = 0
[Enum(UnityEngine.Rendering.StencilOp)] _StencilOp ("Stencil Operation", Int) = 0

Mask Material

image

Foreground UI Material

image

Masking TextMeshPro

I explained here how to mask Textmesh Pro

image

Show all projects by smkplus