[ODE] camera position

Nate W coding at natew.com
Thu Mar 13 00:34:02 2003


On Thu, 13 Mar 2003 first@cove.org wrote:

> I converted the matrix info from dBodyGetRotation(body[0]) into a euler
> angle with some success, but should I do this? Is there a way to use the
> matrix info directly to position the camera?

Yes, have a look at the setTransform function in drawstuff.  Just pass in
the parameters for the body.  Basically, instead of calling setCamera in
dsDrawFrame, call setTransform () instead, passing in the data for the
body you want to "carry" the camera.

But, there comes a point when you're better off starting from scratch than
hacking new functionality into drawstuff.  :-) I think you're approaching
that point if you haven't passed it already.

-- 

Nate Waddoups
Redmond WA USA
http://www.natew.com