[ODE] New ODE Collision detection

Erwin de Vries erwin at vo.com
Mon Aug 26 17:02:01 2002


> great stuff. exactly what i'm looking for. just a few comments/questions.
>
> what is the motivation for locking a space?  i'm thinking it would be
handy because i could...
>
> - do ray checks and get the results immediately

Yes. But not limited to rays. You could also use it for volume checking. "Is
object X inside volume Y?"

> - avoid static vs static geom collisions.

Not yet. But i will probably add the flag i suggested earlier.

> is that what you're after? anything else?

It is also for consitency, and to give spaces more freedom to optimize. I'm
really wondering what will happen when you remove (and delete!) a geom from
a hashspace in the current ODE implementation while in a nearcallback. If
i'm correct this causes a crash. Locking enforces correct behavior. It also
allows you to do multiple collision queries while only setting up once. The
space containing GeomGroups also need to know when a 'frame' starts to
precompute their internal AABB's once (and lock themselves) for every
external queries within that 'frame'. It all makes perfect sense in the end.

> AFAICT, big things (AABBs too big for hash table) *REALLY* slow down
collisions. if that's true, then breaking apart a tri-list into smaller
tri-lists is crucial.  Perhaps it would be possible to create a geom group,
with its own internal hash space, and put the smaller tri-lists there.  That
way, the application still gets a single geom pointer back.  Does this
interest you?

I'm wondering how much faster this would be. And how much trouble it would
be to implement this! And currently the hashspace doesnt implement a fast
external collision query. I abstracted the space functions to behave largely
like geom classes. For speed reasons internal includes are required.
Implementing a new space is much more straightforward now.

> A minor thing that might be handy is if the tri-list accepted a "stride"
so you could more easily share data with your graphics pipeline.

The new version already does. Someone on this list (probably you) suggested
it a while ago, so i decided i should add it.

> Please let me know if I can help code or test.

I will.