otdavies/UnityChromakey

Make shader lit

Againstyou opened this issue · 4 comments

Thanks for your work!
I testing your shader and it works great.
But in my enviroment i need some Reflections, so it would be nice making a lit version of the shader. Is that possible?
I wonder if it would even work for proper shadows but this could result in a black box instead of the actual cutout?

grafik

What do you think, is it possible to transform the shader to lit?

Leaving this here for reference regarding the shadows: https://cyangamedev.wordpress.com/2020/06/05/urp-shader-code/10/
There is likely a way to use an alpha cutoff or the likes to make sure we get a pretty believable shadow. I'll create a version of the shader that is lit so that it will work with screen space / planar reflections hopefully.

Thank you for your reply!
That sounds great, especially because your shader is one which support HDRP which is really useful to implement a realistic and believable enviroment.
As i've seen your reference is about URP, do you think it will be possible for HDRP too?
Thanks for your great work!

https://github.com/RemyUnity/SG-HDRP-Lit

Maybe that helps. Its a ShaderGraph Version of the LitShader. Maybe its possible to adjust for Chromakey and keep the lighting stuff. But it looks a bit outdated.