[osg-users] Spatial View SVI autosteroscopic display support.

Steffen Kim mailto.stk at web.de
Mon Sep 22 13:01:20 PDT 2008


Hi Chris.

I spent quite some time on doing just what you are planning to do - getting an OpenSceneGraph-application to work with a Spatial View display. In the end I was successful.
I don't know at the moment if I can provide you with any code but of course I can tell you how I am doing it. I have no idea if this is the best way but it works quite well.

I use 5 RTT-cameras to save the five views in textures that later become input for the interlacer. You can position these 5 cameras using the SVI camera API or calculate the view and projection matrixes yourself. You then let the SVI interlacer render the result from the 5 textures. Everytime the master camera (the main osg camera) changes you also have to recalculate the matrixes of your slave cameras. The important part is that you take care on when you do call the API functions. You have to do this in a part of your program where the OpenGL context was set accordingly by OSG. You can use a PostRender-CameraCallback for this. See the osgteapot-example for some code on how to do this.

Good luck.
________________________________________________________________________
Schon gehört? Bei WEB.DE gibt' s viele kostenlose Spiele:
http://games.entertainment.web.de/de/entertainment/games/free/index.html




More information about the osg-users mailing list