Page 1 of 1
Z-corridors
Posted: Sun May 22, 2011 3:52 pm
by noattack
I came across the following term in a book on virtual / video game spaces:
...those familiar with FPS games know that unrealistic space display can undermine the realistic features of a game. So-called Z-corridors are used to separate the graphical display of two rooms or large spaces only because computational limits require it.
I'm unfamiliar with 'Z-corridors' and Google is yielding no useful results. What is this programming / graphics technique and how does it work?
Posted: Sun May 22, 2011 6:27 pm
by Hangin10
Sounds like they either mean a "portal engine".
Posted: Sun May 22, 2011 7:32 pm
by tepples
Or maybe by "Z corridors" they mean a Z-shaped room layout like that seen at the entrance to a public restroom, which limits the potential visible set on either side:
Code: Select all
__ __
| |
| |
|___ |
> _ | |
| | |_|
| |___ <
| |
__| |__
The Z corridor between the two rooms is made of three convex sectors:
Code: Select all
| [solid] |
|_______ |
. 1 .| |
.___ . | |
| | | |
| | 2 |___|
| | . 3 .
| |.______.
| |
| [solid] |
A camera in the left room or in sector 1 can't see past sector 3, and a camera in sector 3 or the right room can't see past sector 1.
Posted: Sun May 22, 2011 8:04 pm
by noattack
Makes sense. Seems similar to backface culling, in that it limits the amount of rendering that needs to be done in any given frame.
Strange that I can't find much online, though. The book tosses off the term like it's common programmer parlance.
Posted: Mon May 23, 2011 5:58 am
by qbradq
This was used all the time when true 3D games first came out. Back in the days of Doom it didn't matter. Doom's ray caster had to run once per pixel for the width of the screen, and only in very exceptional cases did the geometry of the level impact the speed of that routine very much.
When Quake came out the game changed. Now every triangular face in the scene had to be transformed, lit and then blitted to the screen from back to front. Now every triangle rendered that was ultimately covered up was wasting frame rate, and it became vital to the game to reduce the visible set.
Z corridors is one way to achieve what the book was really talking about: vis blocking. Blocking the visibility between two scenes. This can also be done with holes, completely opaque curtains or liquid surfaces or even by artificially limiting the draw distance (as was used on many PS1 / PS2 games, see Silent Hill).
Posted: Mon May 23, 2011 6:14 am
by RushJet1
If you play the Conduit for Wii, there are TONS of z-corridors in its later levels....