In AmplifyShader I can control a Blending mode in material inspector with enum property, Can I do the samething in Shadergraph??
I did lots of experiement for hours but I failed ; ( Please Help me
In AmplifyShader I can control a Blending mode in material inspector with enum property, Can I do the samething in Shadergraph??
I did lots of experiement for hours but I failed ; ( Please Help me
+1 i want to know how to do this too, i have tried as well
Oh I found how to do this, Super simple. There is shader graph template for vfx. If made by this template It can control cull mode, zwrite, blending mode etc … in outside of shader.
Can you tell me where you found the template for vfx?
Kinda late, but I believe this is what you are searching for?
setting ENUM (enumeration)
we mean giving a material direct blending operations
[Source]
[Destination]
operations
render target | Integer, range 0 through 7 | The render target index. |
---|---|---|
state | Off |
Disables blending. |
factor | One |
The value of this input is one. Use this to use the value of the source or the destination color. |
Zero |
The value of this input is zero. Use this to remove either the source or the destination values. | |
SrcColor |
The GPU multiplies the value of this input by the source color value. | |
SrcAlpha |
The GPU multiplies the value of this input by the source alpha value. | |
SrcAlphaSaturate |
The GPU multiplies the value of this input by the minimum value of source alpha and (1 - destination alpha)
|
|
DstColor |
The GPU multiplies the value of this input by the frame buffer source color value. | |
DstAlpha |
The GPU multiplies the value of this input by the frame buffer source alpha value. | |
OneMinusSrcColor |
The GPU multiplies the value of this input by (1 - source color). | |
OneMinusSrcAlpha |
The GPU multiplies the value of this input by (1 - source alpha). | |
OneMinusDstColor |
The GPU multiplies the value of this input by (1 - destination color). | |
OneMinusDstAlpha |
The GPU multiplies the value of this input by (1 - destination alpha). |
i never got that working using nodes
https://docs.unity3d.com/Packages/com.unity.shadergraph@12.0/manual/Keywords.html
there is something about setting the ->ENUM within shadergraph to access the actual blending operations
(better example for what it looks like on a material)
^ Direct blending operations
aha got it, though I’m not sure how to do so with the shader graph
but if we went to debug mode we can see the shader properties on each material
and it seems like enum properties doesn’t have the override property declaration
you are stuck where I am as well; i tried to find _reference nomenclature, something about
Entries vs Reference —I couldn’t figure that out and gave up
I gave it up as well, at least for now
but may I ask why you need it?
I had wanted to give a shaderGraph material odd blending opportunity
dont recall exactly some matcap, fresnel +custom vertex streaming with dissolve remap and and the ability to combine in something that felt ‘shadowy’
maybe it was something like RGB * 2.0f (DstColor) (OneMinusSrcAlpha)
hmm
do you have any example of what you imagine?
it was so long ago. im sorry w/e project I had is long gone/purged
ah that’s a bummer
I actually found a way to do that recently when using custom GUI for the shader you can expose all those hidden properties like this
here is the script
sorry for late reply too*