[ODE] ODE GUI Editor #2...

Nate W coding at natew.com
Fri Feb 27 08:58:27 MST 2004


On Fri, 27 Feb 2004, Amund [ISO-8859-1] Børsand wrote:

> [...] when the load/save functions are implemented into ODE (without
> bugs), nobody needs to worry about the complexity of the format
> itself. I can see the point of a ascii-readable format for debugging,
> but as long as ODE has a bug-free load/save routine and perhaps a dump
> utility to see what a file contains, I think a 3ds-like format would
> be great.

There are two distinct goals being discussed here:

1) An easily understood (but not necessarily fast) format for interchange
between different ODE editors and runtimes;

2) A fast and trivial-to-use format for use when speed is important and
interoperability is irrelevant.

I think XML makes sense for the first, and any simple binary format can be
used for the second. 

> Does ODE have internal unique ID-numbers for different bodies, joints
> etc? 

You can just cast the dBodyID / dGeomID values to integers and use them as
unique IDs.

> That's something I found a challenge in when loading/saving, i.e. to
> find the right body the joint is supposed to be connected to when
> loading it back in. Also, if we want to connect meshes and other
> things, we need to know which object it's connected to.

With Juice, and with another non-ODE-related project I'm working on, I
save each object with the ID it has at save-time, and the IDs of the
'connected' objects.  At load time, I build a hash table that maps the old
IDs to the new IDs, and I use that to re-connect everything.  I've used
this method in a few projects actually, it works just fine.

-- 

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





More information about the ODE mailing list