March 13, 2010

udk: edge detection shader

A few months ago I made a post process effect for UDK that uses the scene depth to detect edges. It might be overly complex but the results are pretty good.

It needs to be tweaked for any level it's applied to in order to adjust for scale, fog, and desired level of detail. This version was adapted to VCTF-Sandstorm, one of the maps that comes with UDK.





I used the shader provided in this post as the basis for mine, and this post helped as well. This is another example I found more recently.


Click for full image


It's also possible to use the alpha component of the scene texture node instead of the scene depth node (the scaling values must be changed too).