- Home /
possible to send custom information to Gbuffer?
I've been tearing my hair out over how to implement stylized shading within a deferred rendering path. For example, if I wanted every object to use the same toon shader with the cheap lights that the path offers. I figure it must be possible, as it's been done before.
https://hopooo.tumblr.com/post/166010258719/devblog-7-deferred-rendering-hi-this-last Where would one even begin? It's so abstract I'm unsure how to even wrap my head around it. Is this done at a shader level? command buffer? I'm not experienced with advanced graphical topics and I realize I'm in over my head, but it doesn't seem impossible.
Answer by Namey5 · Jul 27, 2019 at 12:39 PM
Check these two links (that do exactly what you are asking and more, one of which was provided as a source with the example you gave);
https://www.gamasutra.com/blogs/DavidLeon/20170519/298374/NextGen_Cel_Shading_in_Unity_56.php
https://www.gamasutra.com/blogs/DavidLeon/20150702/247602/NextGen_Cel_Shading_in_Unity_5.php
Answer by MacMC · Jul 28, 2019 at 12:44 AM
Found it. Took some digging through UnityGBuffer.cginc. and UnityStandardCore.cginc. the UnityStandardData struct (and fragDeferred function) seem to do the trick as it links directly with the gbuffers.
Your answer
Follow this Question
Related Questions
Can I receive shadows with my unlit shader graph shader? 1 Answer
Cell Shading Using 2D Renderer? 0 Answers
Has cellshading been removed in 5.4? 0 Answers
Custom water shader and SSR 0 Answers
Screenspace Shadowmap cant be replaced 0 Answers