The effect is a post process that blends based on the objects intersection. I add a single parameter into the material so that it can transmit the objects “id” at runtime. Otherwise I wouldn’t know where one object starts, and another ends in the post process.
It’s designed and optimized for gaming, but i have cinematic version also. Uses about ~0.50 ms at 2560x1440