Entering the third dimension

Entering the third dimension

By Guillaume Gourand

August 30th 2011 at 9:59AM

Darkworks co-founder Guillaume Gourand looks at how to get games going in all three dimensions


Over the past year there has been much debate over 3D and how it will affect the gaming experience.

While everyone is entitled to an opinion, ultimately video game technology is improving, and as a result the way we see and interact with games is changing.

In fact, in the last five years players have gone from playing games in standard-definition to high-definition, and more recently we have witnessed all major consoles incorporate motion control thanks to the success of the Nintendo Wii.

Now, with the global 3D TV market expected to top $100bn by 2014, (according to a report by Research and Markets) the next logical step is to start adding a third dimension to the existing gaming experience.


To understand the fundamentals of 3D, we should first take a look at how our eyes are able to distinguish between two and three-dimensional images.

The process is called Binocular Single Vision and it allows us to view three-dimensional images based on the fact that we have two distinct eyes positioned inches apart from one another. When an object is viewed, each eye has a slightly different line-of-sight giving us two different perspectives of the same image.

Our brains don’t see the two images as double, instead the images are fused together to form a single perception. This allows us to not only distinguish the length, width and height of objects, but the depth and distance between them as well.

Using these same principles, TriOviz for Games is able to accomplish this through a method known as 2D + depth rendering. TriOviz is the market’s only solution for allowing game makers to quickly and cost-effectively produce console games that render stereoscopic images on 3D TVs, PCs and even on ordinary 2D HDTVs via INFICOLOR 3D glasses.

The solution works by processing the depth buffer to create a dynamic disparity buffer which is then used to offset pixels and fill gaps in the resulting images. For the INFICOLOR 3D mode, colour correction and depth of field steps are added to the process.

And because the effect is calculated at the end of the post-process chain from a disparity map, it can be entirely and dynamically tweaked. The main tweaking parameters are the overall effect strength, the amount of negative and positive parallax (how much object appears in front of or behind the screen), how the depth budget is to be allocated, and finally where the focal point should be set.


All calculations are made on the GPU. GPU performances are pixel bound which means that the numbers won't change with the scene complexity and no extra overhead can happen during the process. It’s important to note, as TriOviz is being called at the end of the post-process chain, UI needs to be displayed twice, once for each eye, except for INFICOLOR colour filter mode (as only one image gets outputted from TriOviz).

TriOviz requires 2.1MB of local memory on PS3 and Xbox 360. The full resolution framepacking mode (i.e. 1280 x 1470) requires 3.4MB of additional local memory for each display buffer (i.e. 6.8MB for double buffering or 10.3MB for triple buffering).

Downscaled 3D resolutions are also available on PS3 down to 640 x 1470 (that is 0.2MB of additional local memory). The Xbox 360 does not support the framepacking mode, so there is no need for extra memory allocation beyond the 2.1MB.

TriOviz effect needs to be contacted at the end of your post-process chain and be provided with the scene color and depth buffer as well as the larger targets for the HDMI 1.4 mode on PS3. When integrating the library into a game, some of the TriOviz functions need to be overloaded (mainly memory allocation functions and debug display functions for the library debug menu).

Other functions can also be overloaded to provide greater controls on the library’s inner workings.
While 3D has a big impact on the visuals of a game, careful tweaking is required in order to obtain an effect which is both enjoyable and that limits eye strain. The effect should of course be fine-tuned on a game by game basis to obtain the best results.