Ambient Occlusion Masking in Unreal 4

14. January 2016 Materials 0
Ambient Occlusion Masking in Unreal 4

Hey, so this is just a quick post. I got some interest in an effect I had used in this last weeks post so I thought I’d share how I achieved it. In 4.9, Unreal added the ability to access it’s pre-computed ambient occlusion maps from within the material editor, which allows for some pretty cool things. I used it in my White Room map to make the walls appear as thought the’d been drawn on with a BIC pen.

To do this first make sure that ‘Use Ambient Occlusion’ and ‘Generate Ambient Occlusion Material Mask’ are both turned on in your world settings under Lightmass Settings. I created two separate materials in substance designer:

2016-01-14_0137_001
A simple paper like material

and:

A scribbled up material

Then from within Unreal’s material editor I Lerp’d between the two based on how much ambient occlusion they were receiving.

Switch
I realized after I took this pic that the roughness node is wrong…. Just ignore that part.

The final result looks a little like this:

Anyway I hope this helps someone out there. I thought it was pretty cool.


Comment on this post!