[ODE] adding direction parameter to CCylinder geom?
Graham Fyffe
gfyffe at gmail.com
Wed Dec 28 10:42:20 MST 2005
Hi everyone! I am playing with adding a specified direction to the
CCylinder geom. I started by changing the struct from this:
struct dxCCylinder : public dxGeom {
dReal radius,lz; // radius, length along z axis
dxCCylinder (dSpaceID space, dReal _radius, dReal _length);
void computeAABB();
};
to this:
struct dxCCylinder : public dxGeom {
int direction; // 1 = x, 2 = y, 3 = z
dReal radius,ld; // radius, length along direction axis
dxCCylinder (dSpaceID space, int _direction, dReal _radius, dReal _length);
void computeAABB();
};
and then I made 36 more changes to collision_std.cpp and 5 changes to
collision_trimesh_ccylinder.
Anyhow, it doesn't quite work. Even trying to roll a ccylinder along
a simple plane geom looks all wonky if I use any axis other than Z. I
probably missed some changes in the zillions of hard coded matrix
indeces inside collision_std.cpp.
My question is, has anyone else ever made a patch like this? I mean,
one that works? :)
- Graham
More information about the ODE
mailing list