I have a Shader Graph that is used to render far away terrain. I want to prevent it from getting clipped by the far plane.
This is very simple in shader code:
output.positionCS = TransformWorldToHClip(positionWS);
#if defined(UNITY_REVERSED_Z)
output.positionCS.z = max(0.000001f, output.positionCS.z);
#else
output.positionCS.z = min(output.positionCS.w - 0.00001, output.positionCS.z);
#endif
But I don't see this being possible to replicate in Shader Graph, since it doesn't let you modify the HClip position, only the object space position.
Any ideas for the best approach to achieve this in Shader Graph?