[ODE] one way collision

Megan Fox shalinor at gmail.com
Tue Mar 20 05:41:01 MST 2007


Pretty much exactly what David said (you're probably going to want to
like I and I assume he did, and make a bunch of different object
classes and throw in a lot of if-then passthroughs that totally skip
collision for speed gains), but be aware that one-way collisions
between dynamic bodies can be problematic.

Consider the case where you have two boxes, one one-way collidable,
one not, both dynamic.  Consider that the "I collide with other boxes"
box is nearest a (rigid) wall, with the "I don't know about other
boxes" box being pushed toward it.  The moving box will push the other
towards the wall, and into the wall, and then... problem.  The "I see
other boxes" box has no where to move but is still receiving (very
significant) force from the other, and will most likely rocket off
into parts unknown or possibly just snap to NaN.

So - yeah, it totally works and is very useful, but be CAREFUL with
how you apply it.

On 3/20/07, David Walters <hidden.asbestos at googlemail.com> wrote:
> > I have two types of object that I want to collide. I only want one of
> > the objects to bounce of and the other other object to continue like
> > before, without contact joints being created and changing its
> > simulation.
> >
> > We are using it to create some client side particle effects and want
> > to keep the effects out of the deterministic part of our simulation.
> >
> > Any suggestions on how to achieve this?
>
> Hi, yeah - if you create a contact joint between body_a and NULL
> instead of body_a and body_b; then body_b will be unaffected by the
> constraint and happily keep steamrollering along while body_a will fly
> away or whatever.
>
> In my engine I determine 'immovable' rigid bodies by an instance of a
> class associated to the geom with 'dGeomSetData'. I ended up having a
> moderately complicated structure here where the class I bind has
> methods to determine specific response taken from Lua scripting - but
> if you want a very simple solution just use 'dGeomSetData' with a
> struct or even a bool :-)
>
> I hope that covers everything, I'll elaborate if I've not made sense...
>
> Regards,
> David Walters
>
> p.s. Toribash is great (despite me being terrible at it), well done
> with that :-)
> _______________________________________________
> ODE mailing list
> ODE at ode.org
> http://mooshika.org/mailman/listinfo/ode
>


-- 
-Megan Fox
Idyllon, LLC
http://shalinor.circustent.us/megan/resume/


More information about the ODE mailing list