Outline shader disappears at certain viewing angles

Soo i have a simple outline shader that i attached to a duplicate of the object with the outline i also have some 3d models from Sketchfab. Soo basically i duplicated each shape from the 3d model and applied the shader to the duplicates but i got this issue, it only looks good from an certain angle if i rotate the camera it just disappears and appears only if i look at that certain angle.

Tried researching the problem and found out it might be an issue with the render queue, not with the clipping planes of the cam

this is the outline

shader

This is the most basic outline shader setup possible with Shader Graph, so I suggest starting here and modifying it to suit your particular case.


EDIT

Here is a graph that makes sure outline stays identical on every mesh regardless of scale differences and distance to camera.


Renderer Feature

If you have a lot of meshes and don’t want to add 2nd material to every each one of those you might be interested in creating a Renderer Feature to handle that for you automagically:

This shader is confusing to me. And Flip at the end is :blinking_eyes_meme:
Why are you offsetting vertex by a distance that is calculated in such a convoluted way?

Camera rotating changes ±sign of this distance value and this will make the final length of an offset vector change up & down because of that alone.

изображение
aint working