custom depth subtility

Hi all,

Say i have 2 actors (A end B) whose CustomDepth is set to true. So via post process volume (PPV) they are rendered through actors contained in that PPV. Is it possible to keep A and B from rendering through an actor C which is in this same PPV ?

It would be pretty straight forward if i could use different CustomDepth arrays in my post process material, but there is only one.

Any help much appreciated.

Ok i found the solution :

  • i set C actor custom depth stencil value to 255, and A and B actors custom depth stencil value to 0.

  • in my Post processing material let’s call X the alpha input in the Lerp() function. I substract Scene Texture : Custom Stencil ->Mask(R) to X