Thank you Robert, so I decided to tried it with the CameraManipulator as
you said, but when I call
osgViewer::Viewer viewer;
viewer.getCameraManipulator()->setHomePosition( eye, center, up );
my program crashs, also when I want to get the home position. Is there
no camera manipulator in the normal viewer?
Robert Osfield schrieb:
On 6/21/07, Marcus Fritzen <[EMAIL PROTECTED]> wrote:
> viewer->getCamera()->setProjectionMatrixAsLookAt(..);
for me this function not exists. Perhaps you meant
setViewMatrixAsLookAt?
Yes setViewMatrixAsLookAt() :-)
When I use this, nothing changes for me. My
camera is still the normal viewer camera position. I tried this with
If you have a camera manipulator registers with the viewer then it'll
set the view matrix on each frame for the camera manipulator, so
whatever you set on the camera will be overriden - the manipulator
doesn't know that about the changes you've made.
If you want a manipulator then just set the position of the
manipulator directly, if you always way to set the view matrix
yourself then simply don't register a manipulator and just set the
view matrix in the main frame loop, or via a update callback.
Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/
--
----------------------------------------------------------------
Marcus Fritzen E-mail: [EMAIL PROTECTED]
University Koblenz Mobil: +491786867360
Triererstr. 105, 56072 Koblenz,
HIWI FB4 Herr Jackel
----------------------------------------------------------------
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/