[Bf-committers] Patch 6258 - OdePhysicsEnvironment.cpp does not
compile.
Early Ehlinger
early at respower.com
Wed Mar 14 19:48:47 CET 2007
https://projects.blender.org/tracker/?func=detail&aid=6258&group_id=9&atid=127
In PHY_Ode project
(source/gameengine/Physics/BlOde/OdePhysicsEnvironment.cpp), void
ODEPhysicsEnvironment::removeConstraint(int constraintid) is
implemented, although in the corresponding header, this function takes a
void*. This is illegal in C++, and so the code doesn't compile.
My assumption is that either the header is correct, or the .cpp file is
correct. I'm not positive about which one is correct, since I am not an
expert in the engine's internals. I investigated the code from a "high
level" and came up with this analysis:
The function casts constraintid to type dJointID, which is defined in
extern/ode/dist/include/ode/common.h as typedef struct dxJoint *dJointID;
This implies that the header and not the .cpp file is correct -
removeConstraint should take a pointer rather than an int.
This patch codifies my research, although to be honest, I don't know
much about the physics engine's internals. Hopefully somebody who knows
more than syntactically what's going on can verify that this is the
right call.
-- Early Ehlinger, President, ResPower, Inc.
More information about the Bf-committers
mailing list