unity urp outline shader in shader graph
Click here to learn more about Stylized Outlines:
https://u3d.as/2MbT
Stylized Outline is a lightweight, easy to use outline shader. To apply, you simply drag and drop the material into a second material input slot onto any mesh that you would like to receive an outline.
It can be customized on a per-mesh basis. For example, you can have one object with a thin red outline and at the same time have a second object with a thick blue outline.
The outline is configured using world space units and is rendered in world space. In other words, you can easily set the exact size of the outline in world space units. As objects move closer or further from the camera, the outline remains the same size relative to the object.
You can set any outline color on a per-object (i.e., per material) basis.
You can also use the Vertex Color (R) channel to attenuate the outline thickness for more artistic control. A Vertex Color (R) value of 0 fully attenuates the Outline Thickness, whereas a Vertex Color (R) value of 1 applies no attenuation to the Outline Thickness. An example of this functionality is provided with the VP_Sphere in the demo.
You can also scale the outline size down as objects get further away from the camera if you'd like the effect to only appear for nearby objects.
Finally, you can use a noise texture to attenuate the outline thickness based on the vertex distance from the object center. The noise texture is sampled along the x axis only. The Noise Framerate configures how frequently we jump to a new randomly offset position along the x-axis. Set this to zero to disable offset jumping. The Noise Frequency configures the rate at which the distance samples across the x-axis of the noise texture (e.g., setting frequency to 1 causes the shader to sample at a rate of 1 : 1 in world space units - in other words, 1 unit of distance will be equivalent to 1 repeat of the noise texture).
Shader Properties include the following:
_OutlineColor
_OutlineThickness
_UseVertexColors
_AttenuateByDistance
_CompleteFalloffDistance
_NoiseTexture
_NoiseFrequency
_NoiseFramerate
These Shader Properties are all accessible as standard material properties are during runtime, except for the three toggles - _UseVertexColors, _AttenuateByDistance, and _RandomOffset, which are shader feature keywords compiled during build.
OccaSoftware Website
https://www.occasoftware.com/
OccaSoftware Publisher Page
https://assetstore.unity.com/publishers/52431
Free Unity Asset Program
https://www.occasoftware.com/free-unity-asset-program
One-Click Subscribe
https://bit.ly/3pYrdFf
Surprise Me
https://www.occasoftware.com/surprise-me
Unity,Game Dev,Unity Free Assets,Unity Outline Shader,Unity Stylized Outlines,Unity Outline Effect,Unity Outline Shader Graph,unity3d,unity game devlog,Outlines URP,Outlines Unity URP,URP Unity Outline,Unity URP Outline,Outline Effect URP,unity urp outline shader,unity urp outline shader graph,unity outline shader graph,unity urp outline,unity urp outline post processing,urp unity outline,urp unity outline shader,urp unity outline shader graph