Hello everyone! I've been trying to make my own toon shader, and I've been using the CustomLightingCelShader example from Feature Examples (Shader Graph) as a reference. But I've noticed that when applied to a cube, and scene has no directional lighting - the color of the cube breaks and one of the sides becomes extremely bright. The original shader has not been altered in any way shape or form, so I am not sure what's wrong in here. I am using Forward+, scene has no directional lighting. Would appreciate some help, ask if you need any more information.
#Feature Examples - Cel Shader issue
1 messages · Page 1 of 1 (latest)
i have a suspicion that changing this CustomLighting sub graph would fix the issue
but im unsure where to look for the problem
ive managed to heavily mitigate the issue by introducing a direction light with very very low intensity. not enough to affect the scene but just enough to reduce the issue by ~95%. i would still like to get a better way of doing it, since directional lights are a bit of a pain to work with
Just guessing but is this issue dependent on the face or object rotation being exactly axis-aligned?
Yeah that's what I thought too
Only one side is lit and it gets gradually less lit the more it is away from that angle
Currently adding a black colored directional light negates the issue entirely
Weird it happens in the first place tho
it was happening on the -z face
The official Toon shader has a similar error deep in its lighting calculations
But that may just be a coincidence
except this lighting calculation i use came from shader graph samples
official samples
:]
Yes, and the other toon shader with the bug is also official
guess it's just their lighting calculation bug