Hi all,
Could somebody help me. I try to understand stencil buffer. I have put in shader something like this:
For moving object:
Properties
{
_Ref(“Layer”, int) = 0
_Comp(“ComparitionEnum”, Int) = 6
}
Stencil
{
Ref [_Ref]
Comp [_Comp] //notequal
Pass Keep
}
For walls:
Properties
{
_Ref(“Layer”, int) = 0
}
Stencil
{
Ref [_Ref]
Comp Always
Pass replace
}
Unfortunately stencils sometimes are overlay and I have situation like below:
Somebody know how to achieve That with stencils.

