[ODE] Find position of geom within composite?

Megan Fox shalinor at gmail.com
Fri Nov 11 00:12:42 MST 2005


If you're not using GeomTransforms, then calling dGeomSetPosition maps
directly to calling dBodySetPosition - without transform geoms,
there's no way to offset a geom from the center of the body (well, not
without something from the contribs patches, but I imagine you're not
using that).

WITH transform geoms, calling dGeomGetPosition and such on the geom
(the shape geom - the box, the sphere, the trimesh, whatever - NOT the
transform geom) should give you the local position.

Maybe you're calling dGeomGetPosition() on the transform geom instead
of the shape geom?  That would give the results you're describing.

On 11/11/05, Keith Wiley <kwiley at cs.unm.edu> wrote:
> Well, I think you're misunderstanding a little bit, although I
> appreciate the information.  I'm very new to ODE.  The problem is,
> for ANY geom that is a member of a particular body, dGeomGetPosition
> returns the *same* position, the cog of the entire body...so
> dGeomGetPosition simply does not return positional data that is
> unique to the individual geoms making up a body, no matter how the
> position that is returned might be transformed after the fact.  Maybe
> I'm setting up the composite body wrong to begin with, but I think
> it's straight out of the boxstack example.




More information about the ODE mailing list