I followed this guy’s tutorial as it’s the simplest way to do a snow effect. After creating the component mask, added noise etc. but now want to use the mask as one for my normal map, however whatever I try ends up with the same error PixelNormalWS is for normal.
If you place the node “World Aligned Blend” you will notice that is has a mode called “Explicit Normal” for this.
The error happens because you cannot use the WorldNormal to blend between different normals, that would be a cyclical expression. So instead you need to specify which normal map to use.
You can’t use PixelNormalWS because they are generated from normals. So try VertexNormalWS instead. Tough it will not contain the details from Normal map if you use one. But I guess you can manually mix it in.
May be you can convert VertexNormalWS to tangent space trough Transform node, then mix it with your normal map with BlendAngleCorrectedNormals and convert back to worlds space with another Transform node.
You would just transform the normal map from tangent to world space to do that. Thats what the ‘world aligned blend’ function does when you use the explicit normal pin. yes,I meant to use it to replace what you have. Its a pretty self explanatory node. plug in your normal map to the explicit normal input and then use the explicit normal output for your blend.
I think the problem is using a lerp. I just assume I can blend the normal map with a blue vector using the alpha. Looks to me that the PixelNormalWS is used in WorldAlignedBlend anyway, and the graph looks complicated although one thing I like is the bias so I can expand the angle.
I’m still getting the same error “Invalid node PixelNormalWS used for normal input”.
This just leaves me wondering how I can mask a normal map ?
Please re read my posts. You cannot use pixel normal WS in the normal blend. World Aligned Blend only uses it for the other inputs, the explicit normal path I mentioned does not use it. It will work fine is you use only the output with the word Explicit in it.
It doesn’t have to be a different texture, it can be one of the normals that gets lerped too. it just cant include the lerp since that would be a cyclical expression.
I don’t see anything different about that video than doing this. Looks like he just combines the PixelNormal.B component with a tiling texture to add some variation. You could do the same thing with another detail normal added to the explicit normal.
try setting Clamped = False on the function then you can copy the rest of the video exactly. The only reason he doesnt have snow on the bottom is because he isn’t clamping the pixelnormal.B before lerping to it, and his texture never goes either full white or black. personally I think its a bit messy built like that since it depends on a narrow range of content. You can also use HeightLerp to do this in a more controlled way.
A minor note about the WorldAlignedBlend function: using it, I opened it up to see how it was made and looks like the Alpha input is not plugged to the outputs other than w/ Explicit Normal. For the chain that leads to the w/ Explicit Normals output, the Alpha input is being combined with a Multiply. But for the other two outputs, it’s being multiplied in chains that end up with Lerps not plugged to anything, like those nodes you leave there while testing results. Is it intentional or you just forgot / didn’t mind plugging to the other outputs?
I’m creating some snow cover in a material, but anyways I’m using w/ Explicit Normals. Just posted here in the case anyone may be puzzled by the Alpha input not having any effect w/ the Alpha and w/ Vertex Normals outputs.