TSL: Using the output of `pass()` in `.colorNode` in screen space

Nice, that’s working, thanks. Although for my actual use case I’m working with a more complicated scene where I may not have so much control over render order of the scene and this neat solution may not always apply. I’m also sometimes wanting to render the mask separately and not display the output in the scene. Do you have any idea why I can’t do something like this inside of material.colorNode?

maskVal = maskScenePass.getTextureNode().sample(screenUV).r