I want to build an app which should have one camera (or two identical, meaning 
that they are at the same position, facing the same direction, if that is more 
convenient) and multiple screens. The screens will be aligned in a 90 degree 
angle towards each other. So they are perpendicular:
top view:

Code:

          | <- 1 
          |          2
          |          |
          |          v
          |________


O



Where O is the eye or camera. It's like looking at a box with holes in all 
sides and you want to see the inside. And the screens on which I want to 
project are the sides of the box. 
It's a bit like the PcubeE, but then with only two screens:
http://hct.ece.ubc.ca/research/pcubee/ and 
http://www.youtube.com/watch?v=2iV0Icy41JM
I've been messing with ViewMatrix, ViewProjectionMatrix, frustums etc. but I 
cannot get the result I want. I've looked at dozens of examples (like 
3rdperson, windows, sidebyside, compositeviewer, etc.) but I do not really get 
the idea how to set this up, quite lost in all the possibilities at the moment.
In the PcubeE paper 
(http://hct.ece.ubc.ca/publications/pdf/stavness-lam-fels-CHI2010.pdf) they say:
To generate perspective-corrected images on each screen of pCubee, we use a 
standard off-axis projection scheme as described by Deering [9]. This is done 
in OSG by creating three View objects that correspond to the three visible 
screens on pCubee. The camera for each View is located at the user’s 
eye-position (which I will set manually at like right in the middle of the two 
screens, so at 45 degrees), oriented perpendicular to its corresponding virtual 
screen, and given a view frustum that passes through the corners of its virtual 
screen. 
Setting the near-clip plane coincident with the screen plane prevents rendering 
of virtual objects in front of the screens, which would cause occlusion issues 
at the screen edges. Synchronization between screens is handled within OSG: the 
separate  Views are contained within a single  CompositeViewer object and the 
camera parameters in each View are updated before a single call is made to  
CompositeViewer to update all the Views simultaneously. 

Well my question is: how do you do that in code. I'm sorry, I just started 
programming for OSG so I'm a noob :(.

[/i]

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=34800#34800





_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to