[ODE] "static" Geom problem

LR logreg at free.fr
Thu Apr 13 15:51:27 MST 2006


Hi,
 
I can give you the way i use: 
 
i have 3 spaces : one contains the static geoms (space 1), another the
dynamic geoms (space2)  and the third contains space 1 and space 2
if space is the static space (witch contains statics geoms) i do not try to
collide:
 
 
if (dGeomIsSpace (o1) || dGeomIsSpace (o2)) 
  {
  dSpaceCollide2 (o1,o2,data,&nearCallback);
  if (dGeomIsSpace (o1)) 
    {
    if((dSpaceID)o1!=StaticSpaceID) dSpaceCollide
((dSpaceID)o1,data,&nearCallback);
    }

  if (dGeomIsSpace (o2)) 
    {
    if((dSpaceID)o2!=StaticSpaceID) dSpaceCollide
((dSpaceID)o2,data,&nearCallback);
    }
  }
else 
  {
  ...
  int n = dCollide (o1,o2,N,(dContactGeom *)
&contacts[0].geom,sizeof(dContact));
  ...
  }


Laurent.

________________________________

De : ode-bounces at q12.org [mailto:ode-bounces at q12.org] De la part de Matthew
Harmon
Envoyé : vendredi 14 avril 2006 00:16
À : ode at q12.org
Objet : [ODE] "static" Geom problem



I’m having some troubles with “static” geoms
 those that are not assigned to
a body. 

 

I’m counting the number of potential collision pairs I get from
dSpaceCollide(), and it seems that if a geom is not assigned to a body it
always generates potential contacts with other similar geoms.  However, if I
assign them to a body, they don’t (unless they get very close, of course.)

 

I’m using a quadtree space, but the same happens for even a simple space.
These are almost all simple box geoms.

 

I tried calling dGeomMove(), just in case these static geoms were all being
put in the root of the quadtree, but that didn’t seem to help.

 

Any thoughts here?






More information about the ODE mailing list