[UE4][Shader] Post process: tresholded black and white with sobel edge

This is a post process material I've done on Unreal 4 on my free time.

To make this rendering, this is what I did:
  1. Post process material must be rendered before tone mapping to get "hard edge" on light radius attenuation
  2. Original image is desaturated to black and white
  3. Color masking, here color close enough to red is excluded from desaturation
  4. Image tresholding to keep pixels of a luminance under a predefined step black, the others become white
  5. Outline effect
    1. Sobel operator used to detect edges
    2. Keep only hard enough edge using tresholding again
    3. Edges lit by a light are blacks, others are white


Comments

  1. I would like to try something like this for my game. Would it be possible to see a screenshot of your material nodes?

    ReplyDelete

Post a Comment

Popular posts from this blog

[Unity][Shader] Night Vision

[FPS Maker] Custom FPS Game Engine