I am making a 3D application for ios and Android.
Each object in the below image has a different material than others.
I want to make the part of object 3 that intersects with object 2 appears and the part that intersects with object 1 disappears.
Notes:
Object 3 is moving up and down.
The 3 objects have the same depth from the camera (same z).