Hello,
I am using Ippokratis shaders to get a cartoon effect :
Is there any shader that should allow to get eyes rendered after the hairs to be sure they are always visible and never hidden by the hair?
Thanks a lot…
Hello,
I am using Ippokratis shaders to get a cartoon effect :
Is there any shader that should allow to get eyes rendered after the hairs to be sure they are always visible and never hidden by the hair?
Thanks a lot…
dosent render queue and offset works?
Yes, it’s possible. You’ll have to change the tags of your eyes shader to:
Tags {"Queue"="Transparent"}
This will make sure that the eyes will always be rendered after everything else.
For the eyes I am using the default Unlit - Transparent shader.
I opened it to add the line you mentioned but it seems those are already in and doesn’t provide the wished effect ![]()
Shader "Test/Facial - Transparent - Unlit"
{
Properties {
_MainTex ("Base (RGB) Trans (A)", 2D) = "white" {}
}
SubShader {
Tags {"Queue"="Transparent" "IgnoreProjector"="True" "RenderType"="Transparent"}
LOD 100
ZWrite Off
Blend SrcAlpha OneMinusSrcAlpha
Pass {
Lighting Off
SetTexture [_MainTex] { combine texture }
}
}
}
Below a picture :
To the left : Nothing front of the face.
To the right : The hair are front of the face and the eyes are hidden (but should be renderer front of the cylinder…)
What do you think?

Also tried to play with many render order :
Ensure they’re drawn after Link (but before the rest of the scene - use Queue tag) with ZTest and ZWrite off.
Something like…
Shader "Link"
{
Properties {
_MainTex ("Base (RGB) Trans (A)", 2D) = "white" {}
}
SubShader {
Tags {"Queue"="Geometry-2" "IgnoreProjector"="True" "RenderType"="Opaque"}
Pass {
...
}
}
}
Shader "Link Eyes"
{
Properties {
_MainTex ("Base (RGB) Trans (A)", 2D) = "white" {}
}
SubShader {
Tags {"Queue"="Geometry-1" "IgnoreProjector"="True" "RenderType"="Opaque"}
ZWrite Off
ZTest Always
Blend SrcAlpha OneMinusSrcAlpha
Pass {
...
}
}
}
Shader "Your Regular Shader For Everything Else"
{
Properties {
_MainTex ("Base (RGB) Trans (A)", 2D) = "white" {}
}
SubShader {
Tags {"Queue"="Geometry" "IgnoreProjector"="True" "RenderType"="Opaque"}
Pass {
...
}
}
}
Working great! Thank you much!
No I need to go deeper to be sure the eyes do not go over character models…
Sorry to dig this old thread, but I’ve tested the shaders 2 posts above, and have 2 questions:
Works great, but when using this eye trick on many characters in the same scene, their eyes appear on the other characters hair… Any way to solve this?
An other problem, the eyes appears though the walls and other models in my scene, I suppose I need to use the third shader above, but there are many shaders types for my environments. Is there a way to not have to patch every shader in my scene?
Thanks.