Unity shader blend-mode problem

My English is not good, the following texts are all translated by Google.
I encountered a problem when creating alpha Blend mode with Amplify Shader Editor.
image
This is a circular model
image
From different perspectives, get different renderings
image
image
I have inquired about the relevant information.
————————————————————————————
image
The effect of the above picture is not the effect I want.
The effect of the picture below is what I want.
image
Although I found a solution from the book, I can’t use it in the Amplify Shader Editor with my current ability.
The following is the solution



Ask everyone to help me, thank you
I will attach the shader and model I used now and the texture.
https://mega.nz/#!MV4wxCbT!XOsqW_m1DMUzchgKquIhj71kOyi3eZH3bLqmyXwNuHI
Shader please open with Amplify Shader Editor

1 Like

I never used Amplify, but can you not open the .shader file and edit it outside of the tool?

As wyvery boi said, you always can edit with the text editor you are using (Notepad, monoDevelop, visualStudio…)
But if you want to mess with ZTest in Amplify, open the “Depth” tab:
(Thats your shader untouched, well touched the ZTest like on the gif xD)

1 Like

By other way, i didnt understood what was the problem with the first images, but if the problem is the different colors, you already done some corrections for it to be same :smiley:

(Note that in this gif you can see how the “invisble” parts of the mesh are in front because of the ZTest)

(This is how it looks without the ZTesting)

Have a good dev!

Because I have never touched the code, so I can’t do anything about it.
Open Extra Depth Pass I tried, but there will be another problem.
image
It will make my model look like

The problem is not the color, this color is just because it can make the problem better exposed.

Z Test vs Z Write

try (Z Write : Off)
image

Z test = Depth Test ; you want that
Z write = Depth Write : you will not want this

Z Write I have closed
Z Test I tried everything but didn’t solve my problem.

Perhaps amplify is better then I think, but for as far as I know amplify cannot solve this problem.

The problem you’re facing, is that transparent rendering has no way to know what pixel of an object is closer to an object then other pixels of that same object.
The solution you found uses two passes to (I believe) first render the depth values like a solid object after which it renders the object transparently into the back buffer using those earlier values to figure out which ones are in the front.
Unless Amplify has this solution pre-programmed, or if they allow the use of multiple passes, it will be impossible to implement this exact solution.

As you said amplify cannot solve this problem.
amplify Looks like no way two passes.
I should not think that amplify can solve all problems,Thank you very much ,And others。

is the extra Depth pass able to get the: ColorMask 0?

ColorMask

ColorMask RGB | A | 0 | any combination of R, G, B, A

Set color channel writing mask. Writing ColorMask 0 turns off rendering to all color channels. Default mode is writing to all channels (RGBA), but for some special effects you might want to leave certain channels unmodified, or disable color writes completely.

http://wiki.amplify.pt/index.php?title=Unity_Products:Amplify_Shader_Editor/Manual#Output_Node

image

append*
Unity addresses this; similar solution basis

I think Custom SubShader Tags would seem tags to allow ‘colormask 0’ would be added to the 2nd pass
image