Hi Peter,

I presume what you are up against is the use of a Camera Manipulator
that is setting the viewer's Camera's View Matrix on each frame.

If you don't want the standard manipulator then don't register one,
and instead set the view matrix on each frame i.e

  viewer.realize();
  while(!viewer.done())
  {
     osg::Matrixd myViewMatrix = ....; // compute in some way.
     viewer.getCamera()->setViewMatrix(myViewMatrx);
     viewer.frame();
  }

Or alternatively you could just set the home position of the camera manipulator.

Robert.

On 7/28/07, Peter Gebauer <[EMAIL PROTECTED]> wrote:
> Hi all!
>
> I've found the Viewer very useful in creating quick, browsable scenegraphs,
> but I've hit a problem.
>
> The viewer camera always translates and rotates to fit the entire
> scenegraph at startup. This is a problem when I want to start with more
> distance or slightly skewed angles. The result is that all my transforms
> are "nullified" by the camera compensating for it when starting.
>
> I can move about the scenegraph using the default controls, that's not a
> problem, the problem is only that the starting scenegraph render is not what
> I want or what my manual scenegraph transforms should produce.
>
> Is there any way to get the default camera of the viewer and disable this
> automatic transform? Maybe I can do it directly on the viewer instance?
>
> /Peter
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to