basically the way i was thinkn would work like this (with FBO extensions)
This would all be drawn not on screen, but on the FBO texture ->
1. Load all Main textures, keep a copy of them all unchanged.
2. generate 2 FBO's with a new texture wrapped to each one, ill attach another example, but i think its best to understand the tutorial as well as go through the lwjgl version of it (the link from before).
3.
before starting draw the main scene texture onto both of the FBOs (as thiese are the textures that will be minipulated during runtime).
4. When minipulating the scene (again this wont make much sence till you go through the tutorial):
you would bind the first FBO.
a. "Cut out" Images would be drawn before the main scene, at a z = 1 (therefore closer to the viewer) with the color mask set to false.
b. the second FBO texture (copy of the scene) would be drawn at z = 0.
c. "stairs" would be drawn after the scene but still with a z = 1 (same 'z' as "cut out" images).
then you would draw the first FBO onto the second. (this is done because if you draw the scene onto the new scene, Im guessing there will be errors, its good to have the "temp" copy refering to step (b)).
Note: The way the stairs are drawn can be different, you could disable depthTesting, and not worry about its z value, but it might be confusing tryn to track weather on not depth testing is currently enabled, so I suggest just do it the way i explained for starters, you can always tweek the code later.
Once you have drawn to the texture the way you would like it using the FBO extension, you can then just draw the new scene as it will be stored into its own texture (either of the FBO wrapped textures, as the should look the same at this step).
Ill attach an FBO example but i still think in order to get a grasp you should go through the tutorial.
As for collision detection, Im guessing that will be per pixel, so you would need to get the value of each indivual pixel you want to test at a time, and check if its alpha value is = 0, or if you want you could make it if alpha < 0.25f (as that should be close enough). The 0.25f would also look cool, cuz you could have them going through semi-transperant tunnels and not getting blocked
