Menu

camera

Dany
2010-04-26
2013-04-30
  • Dany

    Dany - 2010-04-26

    Hi I wanted to ask you a simple thing.
    How do I remove the camera? I would like to see the Boid from a greater distance .
    Devo modificare qui?

    OpenSteerDemo::camera.mode = Camera::cmFixed;
    OpenSteerDemo::camera.fixedDistDistance = OpenSteerDemo::cameraTargetDistance;
    OpenSteerDemo::camera.fixedDistVOffset = 0;
    OpenSteerDemo::camera.lookdownDistance = 20;
    OpenSteerDemo::camera.aimLeadTime = 0.5;
    OpenSteerDemo::camera.povOffset.set (0, 0.5, -2);

     
  • Craig Reynolds

    Craig Reynolds - 2010-04-26

    Set OpenSteerDemo::camera.fixedDistDistance to some bigger value. The default value (OpenSteerDemo::cameraTargetDistance) is 13, so you might try a value 2 or 3 times bigger. If you set it too large the scene may disappear due to near/far clipping and you would have to adjust those values, apparently set in reshapeFunc.

     
  • Dany

    Dany - 2010-04-27

    thanks for the advice, but changing the value that you told me, nothing changes. I would like to see the Boid from but I can not have a greater distance

     
  • Craig Reynolds

    Craig Reynolds - 2010-04-29

    Oops, sorry, I missed the "camera.mode = Camera::cmFixed;"  The parameters for that "non tracking" camera mode are fixedPosition (camera position) and fixedTarget (place that camera is pointed at).  So try something like:

    OpenSteerDemo::camera.fixedPosition = Vec3 (100, 50, 100);
    OpenSteerDemo::camera.fixedTarget = Vec3 ();

    Adjust the coordinates of the first Vec3 to be where you want it.  Remember that you can interactively adjust the camera position - hold down the "control" key on the keyboard then left-drag the mouse (as described on http://opensteer.sourceforge.net/doc.html#UsingOpenSteerDemo or http://opensteer.sourceforge.net/stref.html)

     

Log in to post a comment.

MongoDB Logo MongoDB