Outlines
The outline implementation uses an inverse hull extrusion method, which creates outlines by duplicating and extruding the mesh along its vertex normals. This approach is efficient and widely used, but it’s important to understand that the solutions provided are per-object implementations designed to complement the main shader functionality.
While this works well for many common use cases, there are certain limitations:
- As a per-object solution, each outlined object requires an additional draw call
- Some vertices may split (SEE SOLUTION IN THE NEXT POINT)
- Performance scales linearly with the number of outlined objects
If your project requires advanced outline solutions (such as global screen-space outlines, perfect outline continuity across multiple objects, or specialized edge detection), consider dedicated outline-specific assets that focus solely on this problem domain and provide post-processing outline solutions like Linework.
All In 1 3D Shader offers outlines as part of its comprehensive feature set, but specialized outline assets may provide more robust solutions for projects where outlines are a critical visual element.
A step by step guide, with the two kinds of outline compared and highlighting an object on hover: How to Add Outlines to 3D Models in Unity URP.
Handling Sharp Corners and Non-Smooth Meshes
Section titled “Handling Sharp Corners and Non-Smooth Meshes”Since the outline uses inverse hull normal extrusion, the quality of the outline depends directly on the mesh’s vertex normals. Meshes with sharp corners or flat-shaded normals can create gaps in the outline where vertex normals point in drastically different directions.
Solution: Smooth Shading + Flat Normals Effect
To achieve clean outlines while maintaining a flat-shaded or faceted look for your lighting:
- Set your mesh to Shade Smooth in your 3D modeling software or Unity (in the Mesh Import settings set the Normals to Calculate, the Smoothness Source to From Angle, then choose some Smoothing Angle and press Apply. For better results try different Smoothing Angle values)

- Enable the Flat Normals effect in the shader
- Adjust its Blending slider to control how faceted the lighting appears

This approach gives you the best of both worlds:
- Smooth vertex normals for clean, gap-free outline extrusion
- Flat-shaded appearance for stylized or low-poly aesthetics
- Full control over the degree of flatness through the adjustable slider
Here on the left is a cube with hard normals, like the regular flat shading you’ll find in popular asset packs such as Synty ones. On the right is the setup we just described:

The Flat Normals effect recalculates surface normals per-pixel to create a faceted lighting appearance while preserving the smooth vertex normals used for outline generation.
Outline Types
Section titled “Outline Types”The shader offers three outline types, plus None, each with its own advantages and use cases:

Disables the outline effect entirely. Use this option when you don’t need outlines or want to temporarily disable them without losing your settings.
Simple
Section titled “Simple”A fixed basic implementation that extrudes the mesh along its vertex normals by a customizable width. This is the most common and versatile outline type, suitable for most use cases where a consistent outline is desired. The width is constant in world units and isn’t affected by the object’s scale, so like any object it looks thinner as the camera moves away.
Constant
Section titled “Constant”Creates an outline with constant screen-space width regardless of the object’s distance from the camera, with no distance limit. Max Camera Distance sets how thick that width is: a larger value gives a thinner outline. This is particularly useful for UI-like elements in 3D space or for maintaining consistent outline visibility at any distance. It relies on perspective, so it is meant for perspective cameras.
Fade With Distance
Section titled “Fade With Distance”An outline that thins with distance and disappears at Max Fade Distance. The change is in its width, not its transparency. This creates interesting effects where objects only show prominent outlines when within interaction range, helping guide player attention to nearby interactive elements.
Outline Modes
Section titled “Outline Modes”Each outline type supports two rendering modes, set with Outline Mode, that control how the outline appears:
The shader extrudes an outline-colored mesh behind the original mesh. This is the most straightforward approach and works well for most cases, though the outline may appear on both the silhouette and internal edges visible from certain angles.
Uses the stencil buffer to prevent the outline from appearing on top of the mesh surfaces. The outline only renders around the silhouette where the mesh edges meet the background, creating a cleaner appearance. This mode is ideal for detailed meshes where internal edges would otherwise create visual clutter.

URP Setup
Section titled “URP Setup”For URP projects, the outline feature requires specific Render Features in your pipeline settings:

The asset will prompt you to auto-configure these features when the editor loads in a URP project. You can also configure them at any time through the asset-window under URP Settings, with the Configure button.
It adds two RenderObjects features to your pipeline asset, named Render Feature - Outline Opaque and Render Feature - Outline Transparent, both filtering on the shader’s OutlinePass. It also sets Depth Priming to Disabled.
