Hi Carlo, On 12/15/06, Carlo Camporesi <[EMAIL PROTECTED]> wrote:
Hi Robert, Sorry for the bad example and for my terrible english. What I'm tring to explain is: - In first Camera I'm setting ortho2D as 1600x1200: text and other quad is rendered correct. - When I attach another camera with viewport (0,0,100,100) I would expect that these values live in 1600x1200 coordinate system not in 1280x800 (Default Viewport value before ortho2D)
The projection and view matrix is what sets to coordinate frame of the scene graph, the viewport then defines the pixel range that this is projected to. If you want the HUD subgraph to work out the same size for two separate regions then you'll need to adjust the projection matrix to account for the changes in the viewport width/height. One trick around this is to use the same values in setting up otho2d as you use from your viewport, this way the HUD subgraph will all be in the same frame. However, I really can't work out what you want, let alone tell you how to do it. The OSG has the flexibility to set up all the required elements - viewport, projection and view matrices, its really up to you as the app developer to work out how you want to manage these. Robert. _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
