What is AOMaterialMask(generated from Lightmass, stored in Lightmap) and how should I use it?

I already have textureAO which is very high resolution, comparable to NormalMap. TextureAO describes the self-shadow of the object’s surface, which I connected to the “AmbientOcclusion” of the material node.

Also, I’m using Lightmap, and I find that it generates an AOMaterialMask Texture2D that describes occlusion between objects, and I can adjust the “Max Occlusion Sistance” in world settings panel to control its behavior.

But what puzzles me is, how do I use it? I searched for “AOMaterialMask” in the source code file(*.usf, *.ush), only to see that it was read from LightmapVT, and then there was no more:(

I don’t think it’s useful for you to be used in a material. It’s likely used in one of the scene buffers in the engine code to handle the AO. You could get the AO scene texture in a post process volume which it might be present in. In that case you should be able to make “overall” changes to it.

I don’t think you have to use it, but for example The Ascent used baked AO for procedural texturing: