Custom stencil filtering for DBuffer decals

What I want is to have a decal that ignores certain meshes. Turning off “receive decals” is not an option, since I want these meshes to be affected by other decals. So instead I enabled custom stencil and used it like this:

And that worked perfectly fine with translucent blend mode. However when i changed blend mode to dbuffer, so the decal would work correctly with lighting, my custom stencil node only returns zeroes and completely ignores actual stencil value.
Is it supposed to be like that or what am I doing wrong?

I have the same problem. Anyone knows something about this?

My team have encountered this problem too. Anybody knows how to solve it?

You must add a string r.customdepth.order=0 in DefaultEngine.ini

Hey i allready posted in another topic, but it should be here aswell. just in case.

i also ran into the issue and there is one more important setting you need to setup.

Go to project settings and change Custom Depth Stencil Pass to: EnabledWithStencil and then RESTART the editor (that is important too).

2 Likes