My issue is that the transparency in the mask image is not affecting the stencil buffer which makes the mask write out it’s entire rectangle to stencil buffer,
rather than only the opaque parts of the mesh.
Hi @sebavan . I’m trying to only show the background mesh when it falls inside of the mask meshes opaque region. I just tried disabling color write in the playground above, but it didn’t yield the proper result. The proper result would look like:
Thank you for the comments so far as this was a very difficult problem for me and it took over a day to discover this trick. Hopefully this thread can help people in the future.