[ODE] Huge world vs precision problems

J. Perkins starkos at gmail.com
Fri Mar 10 07:38:47 MST 2006


On 3/10/06, Anders Olofsson <anders.olofsson at biologigrand.ac> wrote:
> I just made a little graphic test (OpenGL), 2 rotating
> triangles one at origin and one at the far edge of the world. Ofocuse the
> one at the far edge wobbled, kind of obvious. Then I tried specify the
> triangles using doubles, no difference, still wobbling!.

What I am doing now -- an idea I got from someone else, maybe Tom
Hubina? -- is storing all object positions with doubles. Before
rendering, I subtract the object position from the camera position and
use that to build my modelview matrix for OpenGL. This works fine for
rendering. I use ODE with doubles which so far seems fine for boxes
and spheres; I haven't attempted trimeshes yet. It would seem that you
might be able to get away with a similar approach: move one trimesh
into the coordinate space of the other, then do the collision. There
is probably no other way to manage it.

It would be nice if ODE had an option to use double for positions and
float for everything else.

Jason



More information about the ODE mailing list