It is sometimes desirable to use a stencil buffer with an
EffectLayer, but this isn’t currently supported.
For example: Babylon.js Playground
In this demo, the post-process glow isn’t masked properly by the stencil settings since the underlying texture doesn’t have stenciling enabled.
This can be fixed by allowing
EffectLayers to enable stenciling. Here is what that might look like:
I can create a PR for this if desired.