SnutiHQ / Toon-Shader

A character focused Toon Shader for Unity using Shader Graph.
https://www.youtube.com/watch?v=g8eBXCgWwrk
MIT License
445 stars 58 forks source link

Interesting Behaviour #3

Open nzcoward opened 4 years ago

nzcoward commented 4 years ago

First off, very cool. I am still playing with it, but it's looking gorgeous.

I'm not entirely certain about the Ambient node. I was stuck for a while trying to work out why everything was tinted blue (I added an invert color node to test what on earth was happening).

image

You can see that the result in the Add node does not match the final result. Which is very odd in of itself.

I found that if I removed the Ambient light node, everything worked as expected. So I had a bit of a hunt, and found that even though my Environmental Lighting (EL) was set to use the Skybox color, I had been playing with an ambient color a little while back. If I changed the EL to black, it resolved the problem also.

image

So even though I wasn't using the Ambient color in EL, this node still applied it. Why it didn't apply it to the result of the Add node, I do not know. But maybe an option to scale it in here is a solution (a multiply node to reduce the effect of the ambient light?)

image

It's odd that it is applied even though the Ambient light is not being used in the scene, and perhaps there is a way to prevent it from happening, but there are some pretty cool effects you can create by allowing scaling of the ambient lighting (perhaps not intuitive, but fun!)

ecker00 commented 4 years ago

Very cool seeing what you've been experimenting with, and scaling the ambient light pretty smart. I've noticed strange behavior with this myself, which is why I added the "Everything looks bright and washedout" section to the Readme. I've also modified this setup a bit in our own project to make it look right, but it seems to depend quite a bit on other configuration in the project like you mention.

No idea what's going on with the inverting node though. 😅