I have an effect I’m trying to achieve, but I’m not really sure how to go about it. I have a plane (blue) with a sprite manager and some sprites above it (green) and a series of smaller planes above that (red). That’s figure A below. I want to make it so when the camera is far away, the sprites are hidden and the planes are not (Figure B). When the camera gets closer, I want the red planes to be hidden and the sprites to be visible (figure C). The blue plane should always be visible.
My first thought was clipping planes, but I don’t know if it’s possible to exclude things from them. Could I have one plane hide the red planes and still show the sprites, then a second that hides the sprites but shows the planes? And could those move with the camera? Then I thought I could do it with a material, which could work well for the red planes (though I’m not sure how). But I don’t know if a material would work on the sprites.
Any suggestions on a method to try would be appreciated.