a quote from Robert: "ABSOLTE_RF means that the when the cull traversal 
encounters a Transform node it ignores the inherited modelview matrix so that 
the local transform matrix on the Transform node becomes the new modelview 
matrix. This means that the Transform nodes subgraph is placed in new 
coordinate frame rather than that of it's parents. " 

This is probably what you want. This way your camera is not affected by any 
other nodes (it sort of resets the view-matrix) There are probably some 
situations where it might be useful to go for the relative reference frame, but 
in your case it isn't.

about orthogonal and perspective, here is nice explanation, look at the 
pictures too. 

http://blender.stackexchange.com/questions/648/what-are-the-differences-between-orthographic-and-perspective-views

basically orthogonal camera renders everything in a box, looking exactly from 
one side, without perspective correction (so stuff that's far away is not any 
smaller than stuff closer to the camera).
In perspective there is a correction for depth, like in real life, where stuff 
in the distance looks smaller.

For these axis of yours, I think perspective might look slightly better, 
specially if they have anything 3d to the look of them (if they are just 3 
drawn lines, then it might be hard to see the perspective... 

In the case of orthogonal you set it to render a 300 by 300 area with 
setProjectionMatrix( osg::Matrix::ortho2D( 0, 300, 0, 300 ) ); , so to make 
sure the axes are rendered at the correct size, just make the axis the correct 
size (or pick a larger box to render)
you set the viewport the same size as the orthogonal rendering box, so then it 
quite literary translates; if you draw a line from (0,0,0) to (10,10,0) you 
will see a line from (0,0) to (10,10) on your screen.

if you go for  perspective, you can also just choose re-size the axes to your 
liking, but you can also move the camera further away, because there is 
perspective correction. I personally use the 
camera->setViewMatrixAsLookAt(eye,center,up) to set up and move my camera  the 
way I want. In my world z = up, so the up vector is always (0,0,1). The eye is 
the position of the camera, and the center is the place where you want to point 
your camera at.

I don't really have a good book that I can recommend you, sorry, but there must 
be some good ones out there I guess.

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





_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to