Edge Detect Effect Normals
This version of the Edge Detect image effect creates outlines around edges by taking the scene geometry into account. Edges are not determined by colour differences but by the surface normals and distance from camera of neighbouring pixels (the surface normal is an "arrow" that indicates the direction the surface is facing at a given pixel position). Generally, where two adjacent pixels have significantly different normals and/or distances from the camera, there is an edge in the scene.
As with the other image effects, this effect is only available in Unity Pro and you must have the Pro Standard Assets installed before it becomes available.
Scene without edge detection
The same scene showing the detected edges
This effect uses the ImageEffectOpaque attribute which enables image effects to be executed before the transparent render passes. By default, image effects are executed after both opaque and transparent passes have been fully rendered.
Properties
Mode | Chose between Thin and Thick. Thick will take more samples into consideration to construct outlines. |
Edge Sensitivity | |
Depth | The minimum difference between the distances of adjacent pixels that will indicate an edge. |
Normals | The minimum difference between the normals of adjacent pixels that will indicate an edge. |
Background options | |
Edges only | Blend the background with a fixed color. |
Background | The color used when Edges only is > 0. |
Hardware support
This effect requires a graphics card with pixel shaders (2.0) or OpenGL ES 2.0. Additionally, depth texture support is required. PC: NVIDIA cards since 2004 (GeForce 6), AMD cards since 2004 (Radeon 9500), Intel cards since 2006 (GMA X3000); Mobile: OpenGL ES 2.0 with depth texture support; Consoles: Xbox 360, PS3.
All image effects automatically disable themselves when they can not run on end-users graphics card.
Page last updated: 2012-01-09