I’ve just upgraded to a newer version of unity and am testing out the shader graph by implementing some existing shaders I wrote in an earlier version. I am surprised to see that there are limited options in the Graph Settings for Blending Modes. I’m wondering if the other options were removed for a reason, and/or if they are reproducible via other means.
In the shader I’m trying to reproduce, I was using Blend DstColor OneMinusSrcAlpha
to produce a glowing effect where a semi-transparent circle was used to light up an area, but we were using DstColor instead of SrcAlpha to keep dark areas dark (to prevent things from looking washed out). If I select Multiply in the Shader Graph Blending Modes, the shader that gets generated has Blend DstColor One
, which rather than fading out correctly, is black where I’d expect transparency. I don’t know if any of the specifics here are helpful, and as I understand it, a practical workaround would be to copy the generated shader code into a new shader and manually change the blending mode, but that sort of defeats the purpose of trying to recreate the shader in Shader Graph. I’d be curious if there were ways to get this effect working, and in general to have more access to the various blending modes for other shaders I may want to make within Shader Graph in the future. In general, a way to access DstColor as a shader parameter would solve my problem and let me do a lot more, but I suspect that’s not accessible without doing things with RenderTextures, but I am new to the URP and would be pleasantly surprised if there’s a way to fiddle with that directly in the ShaderGraph as well.
I can provide more information if necessary, curious if there’s anything obvious I’m missing.