Skip to content
프로젝트

tantaneity/unity-urp-outline-postprocess

GitHub에서 보기

tantaneity/unity-urp-outline-postprocess has 31 GitHub stars and 4 forks. Star changes are not measured yet. Last checked 2026-11-14 12:30 UTC. Last push 2026-01-07.

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
기록 수집 중
in 7 days
기록 수집 중
in 15 days
기록 수집 중
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

소개

Sobel-based edge detection post-process shader for Unity URP with depth and normal detection

창작 및 미디어

README.md

Original

Unity URP Outline Post-Process Shader

Sobel-based edge detection post-process shader for Unity URP with depth and normal detection

A neat little post-process shader for URP that slaps some outlines on your scene. Basically grabs depth and normal info to figure out where edges are, then draws lines around 'em.

Demo

Example

What's this thing do?

So like, the shader peeks at your scene's depth buffer and normals to spot where stuff overlaps or angles change. Then it goes ahead and throws an outline on those edges. Uses Sobel edge detection for smooth, clean edge detection with anti-aliasing.

Getting it working

  1. Chuck the shader file anywhere in your Assets folder
  2. Set up a custom renderer feature:
    • Make a new C# script for the renderer feature thingy
    • Hook up this shader material
    • Toss that feature into your URP Renderer asset
  3. Tweak these knobs till it looks good:
    • Outline Color: What color you want (alpha controls how strong it blends)
    • Depth Threshold: How picky it is about depth differences (scales with distance, lower = catches more edges)
    • Normal Threshold: How picky about surface angles (lower = more sensitive)
    • Outline Thickness: How thicc you want those lines (affects sampling radius)

Example setup

// these values usually slap:
_OutlineColor = new Color(0, 0, 0, 1);
_DepthThreshold = 1.5f;
_NormalThreshold = 0.1f;
_OutlineThickness = 0.6f;

What you need

  • Unity with URP (duh)
  • Depth and Normal textures turned on in your URP Renderer settings

That's pretty much it! Your scene should start showing outlines around stuff right away.

관련 프로젝트 살펴보기