+1
Terminé

Two-sided sign node

zoltan erdokovy il y a 10 ans mis à jour par AntonioEffectsFX il y a 6 ans 11

In double sided shaders it would be useful to tell the two sides apart.


If the node is called "TwoSidedSign" then it should produce 1 for front side and -1 for backside.

If the name ends up being something like "IsBackSide" then 0 for front, 1 for back. (This approach would make it simpler to use it in Lerps.)

Solution

+1
Solution
Terminé
This has now been fixed in 1.18. No more artifacts + this node :)

Hi,

is there another way to achieve this node with math ?
Because like in the UDK it is use for custom lighting shader with transmission.
Really really thank you Joachim, it work like a charm.
And long live to SF. :-)

Almost working in fact.
There are some strange artefacts cause of depth problem I think.

Are you using Alpha Clipping or Alpha?
Actually it's most likely because the normal was facing away from the camera, though the face is still facing the camera due to interpolation. The solution I put up there is a bit of a hack.

In general - just using a double-sided mesh when creating the mesh, is usually enough, and works just as well, if not better :)
+1
Solution
Terminé
This has now been fixed in 1.18. No more artifacts + this node :)

I was making an effect with Face Sign. How would I go about making material not turn with the camera when I attach it. I was just trying to make the material double sided in shuriken

Happens when I attach the material to a mesh.