26 #ifndef _ODE_ODECPP_H_
27 #define _ODE_ODECPP_H_
36 class dWorldSimpleIDContainer {
40 dWorldSimpleIDContainer(): _id(0) {}
41 ~dWorldSimpleIDContainer() { destroy(); }
51 class dWorldDynamicIDContainer:
public dWorldSimpleIDContainer {
53 virtual ~dWorldDynamicIDContainer() {}
56 template <
class dWorldTemplateBase>
57 class dWorldTemplate:
public dWorldTemplateBase {
59 dWorldTemplate (
const dWorldTemplate<dWorldTemplateBase> &);
60 void operator= (
const dWorldTemplate<dWorldTemplateBase> &);
63 dWorldID get_id()
const {
return dWorldTemplateBase::_id; }
64 void set_id(
dWorldID value) { dWorldTemplateBase::_id = value; }
75 void setGravity (dReal x, dReal y, dReal z)
77 void setGravity (
const dVector3 g)
78 { setGravity (g[0], g[1], g[2]); }
79 void getGravity (dVector3 g)
const
82 void setERP (dReal erp)
87 void setCFM (dReal cfm)
92 void step (dReal stepsize)
95 void quickStep(dReal stepsize)
97 void setQuickStepNumIterations(
int num)
99 int getQuickStepNumIterations()
const
101 void setQuickStepW(dReal over_relaxation)
103 dReal getQuickStepW()
const
106 void setAutoDisableLinearThreshold (dReal threshold)
108 dReal getAutoDisableLinearThreshold()
const
110 void setAutoDisableAngularThreshold (dReal threshold)
112 dReal getAutoDisableAngularThreshold()
const
114 void setAutoDisableSteps (
int steps)
116 int getAutoDisableSteps()
const
118 void setAutoDisableTime (dReal time)
120 dReal getAutoDisableTime()
const
122 void setAutoDisableFlag (
int do_auto_disable)
124 int getAutoDisableFlag()
const
127 dReal getLinearDampingThreshold()
const
129 void setLinearDampingThreshold(dReal threshold)
131 dReal getAngularDampingThreshold()
const
133 void setAngularDampingThreshold(dReal threshold)
135 dReal getLinearDamping()
const
137 void setLinearDamping(dReal scale)
139 dReal getAngularDamping()
const
141 void setAngularDamping(dReal scale)
143 void setDamping(dReal linear_scale, dReal angular_scale)
146 dReal getMaxAngularSpeed()
const
148 void setMaxAngularSpeed(dReal max_speed)
151 void setContactSurfaceLayer(dReal depth)
153 dReal getContactSurfaceLayer()
const
156 void impulseToForce (dReal stepsize, dReal ix, dReal iy, dReal iz,
162 class dBodySimpleIDContainer {
166 dBodySimpleIDContainer(): _id(0) {}
167 ~dBodySimpleIDContainer() { destroy(); }
177 class dBodyDynamicIDContainer:
public dBodySimpleIDContainer {
179 virtual ~dBodyDynamicIDContainer() {}
182 template <
class dBodyTemplateBase,
class dWorldTemplateBase>
183 class dBodyTemplate:
public dBodyTemplateBase {
185 dBodyTemplate (
const dBodyTemplate<dBodyTemplateBase, dWorldTemplateBase> &);
186 void operator= (
const dBodyTemplate<dBodyTemplateBase, dWorldTemplateBase> &);
189 dBodyID get_id()
const {
return dBodyTemplateBase::_id; }
190 void set_id(
dBodyID value) { dBodyTemplateBase::_id = value; }
192 void destroy() { dBodyTemplateBase::destroy(); }
199 dBodyTemplate (dWorldTemplate<dWorldTemplateBase>& world)
206 void create (dWorldTemplate<dWorldTemplateBase>& world) {
215 void setData (
void *data)
217 void *getData()
const
220 void setPosition (dReal x, dReal y, dReal z)
222 void setPosition (
const dVector3 p)
223 { setPosition(p[0], p[1], p[2]); }
225 void setRotation (
const dMatrix3 R)
227 void setQuaternion (
const dQuaternion q)
229 void setLinearVel (dReal x, dReal y, dReal z)
231 void setLinearVel (
const dVector3 v)
232 { setLinearVel(v[0], v[1], v[2]); }
233 void setAngularVel (dReal x, dReal y, dReal z)
235 void setAngularVel (
const dVector3 v)
236 { setAngularVel (v[0], v[1], v[2]); }
238 const dReal * getPosition()
const
240 const dReal * getRotation()
const
242 const dReal * getQuaternion()
const
244 const dReal * getLinearVel()
const
246 const dReal * getAngularVel()
const
249 void setMass (
const dMass *mass)
251 void setMass (
const dMass &mass)
253 dMass getMass ()
const
256 void addForce (dReal fx, dReal fy, dReal fz)
258 void addForce (
const dVector3 f)
259 { addForce (f[0], f[1], f[2]); }
260 void addTorque (dReal fx, dReal fy, dReal fz)
262 void addTorque (
const dVector3 t)
263 { addTorque(t[0], t[1], t[2]); }
265 void addRelForce (dReal fx, dReal fy, dReal fz)
267 void addRelForce (
const dVector3 f)
268 { addRelForce (f[0], f[1], f[2]); }
269 void addRelTorque (dReal fx, dReal fy, dReal fz)
271 void addRelTorque (
const dVector3 t)
272 { addRelTorque (t[0], t[1], t[2]); }
274 void addForceAtPos (dReal fx, dReal fy, dReal fz,
275 dReal px, dReal py, dReal pz)
277 void addForceAtPos (
const dVector3 f,
const dVector3 p)
278 { addForceAtPos (f[0], f[1], f[2], p[0], p[1], p[2]); }
280 void addForceAtRelPos (dReal fx, dReal fy, dReal fz,
281 dReal px, dReal py, dReal pz)
283 void addForceAtRelPos (
const dVector3 f,
const dVector3 p)
284 { addForceAtRelPos (f[0], f[1], f[2], p[0], p[1], p[2]); }
286 void addRelForceAtPos (dReal fx, dReal fy, dReal fz,
287 dReal px, dReal py, dReal pz)
289 void addRelForceAtPos (
const dVector3 f,
const dVector3 p)
290 { addRelForceAtPos (f[0], f[1], f[2], p[0], p[1], p[2]); }
292 void addRelForceAtRelPos (dReal fx, dReal fy, dReal fz,
293 dReal px, dReal py, dReal pz)
295 void addRelForceAtRelPos (
const dVector3 f,
const dVector3 p)
296 { addRelForceAtRelPos (f[0], f[1], f[2], p[0], p[1], p[2]); }
298 const dReal * getForce()
const
300 const dReal * getTorque()
const
302 void setForce (dReal x, dReal y, dReal z)
304 void setForce (
const dVector3 f)
305 { setForce (f[0], f[1], f[2]); }
306 void setTorque (dReal x, dReal y, dReal z)
308 void setTorque (
const dVector3 t)
309 { setTorque (t[0], t[1], t[2]); }
315 bool isKinematic()
const
322 bool isEnabled()
const
325 void getRelPointPos (dReal px, dReal py, dReal pz, dVector3 result)
const
327 void getRelPointPos (
const dVector3 p, dVector3 result)
const
328 { getRelPointPos (p[0], p[1], p[2], result); }
330 void getRelPointVel (dReal px, dReal py, dReal pz, dVector3 result)
const
332 void getRelPointVel (
const dVector3 p, dVector3 result)
const
333 { getRelPointVel (p[0], p[1], p[2], result); }
335 void getPointVel (dReal px, dReal py, dReal pz, dVector3 result)
const
337 void getPointVel (
const dVector3 p, dVector3 result)
const
338 { getPointVel (p[0], p[1], p[2], result); }
340 void getPosRelPoint (dReal px, dReal py, dReal pz, dVector3 result)
const
342 void getPosRelPoint (
const dVector3 p, dVector3 result)
const
343 { getPosRelPoint (p[0], p[1], p[2], result); }
345 void vectorToWorld (dReal px, dReal py, dReal pz, dVector3 result)
const
347 void vectorToWorld (
const dVector3 p, dVector3 result)
const
348 { vectorToWorld (p[0], p[1], p[2], result); }
350 void vectorFromWorld (dReal px, dReal py, dReal pz, dVector3 result)
const
352 void vectorFromWorld (
const dVector3 p, dVector3 result)
const
353 { vectorFromWorld (p[0], p[1], p[2], result); }
355 void setFiniteRotationMode (
bool mode)
358 void setFiniteRotationAxis (dReal x, dReal y, dReal z)
360 void setFiniteRotationAxis (
const dVector3 a)
361 { setFiniteRotationAxis (a[0], a[1], a[2]); }
363 bool getFiniteRotationMode()
const
365 void getFiniteRotationAxis (dVector3 result)
const
368 int getNumJoints()
const
370 dJointID getJoint (
int index)
const
373 void setGravityMode (
bool mode)
375 bool getGravityMode()
const
378 bool isConnectedTo (
dBodyID body)
const
381 void setAutoDisableLinearThreshold (dReal threshold)
383 dReal getAutoDisableLinearThreshold()
const
385 void setAutoDisableAngularThreshold (dReal threshold)
387 dReal getAutoDisableAngularThreshold()
const
389 void setAutoDisableSteps (
int steps)
391 int getAutoDisableSteps()
const
393 void setAutoDisableTime (dReal time)
395 dReal getAutoDisableTime()
const
397 void setAutoDisableFlag (
bool do_auto_disable)
399 bool getAutoDisableFlag()
const
402 dReal getLinearDamping()
const
404 void setLinearDamping(dReal scale)
406 dReal getAngularDamping()
const
408 void setAngularDamping(dReal scale)
410 void setDamping(dReal linear_scale, dReal angular_scale)
412 dReal getLinearDampingThreshold()
const
414 void setLinearDampingThreshold(dReal threshold)
const
416 dReal getAngularDampingThreshold()
const
418 void setAngularDampingThreshold(dReal threshold)
420 void setDampingDefaults()
423 dReal getMaxAngularSpeed()
const
425 void setMaxAngularSpeed(dReal max_speed)
428 bool getGyroscopicMode()
const
430 void setGyroscopicMode(
bool mode)
436 class dJointGroupSimpleIDContainer {
440 dJointGroupSimpleIDContainer(): _id(0) {}
441 ~dJointGroupSimpleIDContainer() { destroy(); }
451 class dJointGroupDynamicIDContainer:
public dJointGroupSimpleIDContainer {
453 virtual ~dJointGroupDynamicIDContainer() {}
456 template <
class dJo
intGroupTemplateBase>
457 class dJointGroupTemplate:
public dJointGroupTemplateBase {
459 dJointGroupTemplate (
const dJointGroupTemplate<dJointGroupTemplateBase> &);
460 void operator= (
const dJointGroupTemplate<dJointGroupTemplateBase> &);
463 dJointGroupID get_id()
const {
return dJointGroupTemplateBase::_id; }
464 void set_id(dJointGroupID value) { dJointGroupTemplateBase::_id = value; }
466 void destroy() { dJointGroupTemplateBase::destroy(); }
469 dJointGroupTemplate ()
477 dJointGroupID id()
const
479 operator dJointGroupID()
const
489 class dJointSimpleIDContainer {
493 dJointSimpleIDContainer(): _id(0) {}
494 ~dJointSimpleIDContainer() { destroy(); }
504 class dJointDynamicIDContainer:
public dJointSimpleIDContainer {
506 virtual ~dJointDynamicIDContainer() {}
509 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
510 class dJointTemplate:
public dJointTemplateBase {
513 dJointTemplate (
const dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &) ;
514 void operator= (
const dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
517 dJointID get_id()
const {
return dJointTemplateBase::_id; }
518 void set_id(dJointID value) { dJointTemplateBase::_id = value; }
520 void destroy() { dJointTemplateBase::destroy(); }
529 operator dJointID()
const
532 int getNumBodies()
const
537 void attach (dBodyTemplate<dBodyTemplateBase, dWorldTemplateBase>& body1, dBodyTemplate<dBodyTemplateBase, dWorldTemplateBase>& body2)
538 { attach(body1.id(), body2.id()); }
544 bool isEnabled()
const
547 void setData (
void *data)
549 void *getData()
const
552 dJointType getType()
const
555 dBodyID getBody (
int index)
const
564 virtual void setParam (
int, dReal) {};
565 virtual dReal getParam (
int)
const {
return 0; }
569 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
570 class dBallJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
573 dBallJointTemplate (
const dBallJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
574 void operator= (
const dBallJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
577 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
579 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
580 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
582 void destroy() { dBaseTemplate::destroy(); }
585 dBallJointTemplate() { }
586 dBallJointTemplate (
dWorldID world, dJointGroupID group=0)
588 dBallJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
591 void create (
dWorldID world, dJointGroupID group=0) {
595 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
596 { create(world.id(), group); }
598 void setAnchor (dReal x, dReal y, dReal z)
600 void setAnchor (
const dVector3 a)
601 { setAnchor (a[0], a[1], a[2]); }
602 void getAnchor (dVector3 result)
const
603 { dJointGetBallAnchor (get_id(), result); }
604 void getAnchor2 (dVector3 result)
const
605 { dJointGetBallAnchor2 (get_id(), result); }
606 virtual void setParam (
int parameter, dReal value)
608 virtual dReal getParam (
int parameter)
const
614 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
615 class dHingeJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
618 dHingeJointTemplate (
const dHingeJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
619 void operator = (
const dHingeJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
622 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
624 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
625 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
627 void destroy() { dBaseTemplate::destroy(); }
630 dHingeJointTemplate() { }
631 dHingeJointTemplate (
dWorldID world, dJointGroupID group=0)
633 dHingeJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
636 void create (
dWorldID world, dJointGroupID group=0) {
640 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
641 { create(world.id(), group); }
643 void setAnchor (dReal x, dReal y, dReal z)
645 void setAnchor (
const dVector3 a)
646 { setAnchor (a[0], a[1], a[2]); }
647 void getAnchor (dVector3 result)
const
649 void getAnchor2 (dVector3 result)
const
652 void setAxis (dReal x, dReal y, dReal z)
654 void setAxis (
const dVector3 a)
655 { setAxis(a[0], a[1], a[2]); }
656 void getAxis (dVector3 result)
const
659 dReal getAngle()
const
661 dReal getAngleRate()
const
664 virtual void setParam (
int parameter, dReal value)
666 virtual dReal getParam (
int parameter)
const
670 void addTorque (dReal torque)
675 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
676 class dSliderJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
679 dSliderJointTemplate (
const dSliderJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
680 void operator = (
const dSliderJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
683 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
685 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
686 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
688 void destroy() { dBaseTemplate::destroy(); }
691 dSliderJointTemplate() { }
692 dSliderJointTemplate (
dWorldID world, dJointGroupID group=0)
694 dSliderJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
697 void create (
dWorldID world, dJointGroupID group=0) {
701 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
702 { create(world.id(), group); }
704 void setAxis (dReal x, dReal y, dReal z)
706 void setAxis (
const dVector3 a)
707 { setAxis (a[0], a[1], a[2]); }
708 void getAxis (dVector3 result)
const
711 dReal getPosition()
const
713 dReal getPositionRate()
const
716 virtual void setParam (
int parameter, dReal value)
718 virtual dReal getParam (
int parameter)
const
722 void addForce (dReal force)
727 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
728 class dUniversalJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
731 dUniversalJointTemplate (
const dUniversalJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
732 void operator = (
const dUniversalJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
735 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
737 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
738 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
740 void destroy() { dBaseTemplate::destroy(); }
743 dUniversalJointTemplate() { }
744 dUniversalJointTemplate (
dWorldID world, dJointGroupID group=0)
746 dUniversalJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
749 void create (
dWorldID world, dJointGroupID group=0) {
753 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
754 { create(world.id(), group); }
756 void setAnchor (dReal x, dReal y, dReal z)
758 void setAnchor (
const dVector3 a)
759 { setAnchor(a[0], a[1], a[2]); }
760 void setAxis1 (dReal x, dReal y, dReal z)
762 void setAxis1 (
const dVector3 a)
763 { setAxis1 (a[0], a[1], a[2]); }
764 void setAxis2 (dReal x, dReal y, dReal z)
766 void setAxis2 (
const dVector3 a)
767 { setAxis2 (a[0], a[1], a[2]); }
769 void getAnchor (dVector3 result)
const
771 void getAnchor2 (dVector3 result)
const
773 void getAxis1 (dVector3 result)
const
775 void getAxis2 (dVector3 result)
const
778 virtual void setParam (
int parameter, dReal value)
780 virtual dReal getParam (
int parameter)
const
784 void getAngles(dReal *angle1, dReal *angle2)
const
787 dReal getAngle1()
const
789 dReal getAngle1Rate()
const
791 dReal getAngle2()
const
793 dReal getAngle2Rate()
const
796 void addTorques (dReal torque1, dReal torque2)
801 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
802 class dHinge2JointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
805 dHinge2JointTemplate (
const dHinge2JointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
806 void operator = (
const dHinge2JointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
809 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
811 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
812 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
814 void destroy() { dBaseTemplate::destroy(); }
817 dHinge2JointTemplate() { }
818 dHinge2JointTemplate (
dWorldID world, dJointGroupID group=0)
820 dHinge2JointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
823 void create (
dWorldID world, dJointGroupID group=0) {
827 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
828 { create(world.id(), group); }
830 void setAnchor (dReal x, dReal y, dReal z)
832 void setAnchor (
const dVector3 a)
833 { setAnchor(a[0], a[1], a[2]); }
834 void setAxis1 (dReal x, dReal y, dReal z)
836 void setAxis1 (
const dVector3 a)
837 { setAxis1 (a[0], a[1], a[2]); }
838 void setAxis2 (dReal x, dReal y, dReal z)
840 void setAxis2 (
const dVector3 a)
841 { setAxis2 (a[0], a[1], a[2]); }
843 void getAnchor (dVector3 result)
const
845 void getAnchor2 (dVector3 result)
const
847 void getAxis1 (dVector3 result)
const
849 void getAxis2 (dVector3 result)
const
852 dReal getAngle1()
const
854 dReal getAngle1Rate()
const
856 dReal getAngle2Rate()
const
859 virtual void setParam (
int parameter, dReal value)
861 virtual dReal getParam (
int parameter)
const
865 void addTorques(dReal torque1, dReal torque2)
870 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
871 class dPRJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
874 dPRJointTemplate (
const dPRJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
875 void operator = (
const dPRJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
878 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
880 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
881 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
883 void destroy() { dBaseTemplate::destroy(); }
886 dPRJointTemplate() { }
887 dPRJointTemplate (
dWorldID world, dJointGroupID group=0)
889 dPRJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
892 void create (
dWorldID world, dJointGroupID group=0) {
896 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
897 { create(world.id(), group); }
899 void setAnchor (dReal x, dReal y, dReal z)
901 void setAnchor (
const dVector3 a)
902 { setAnchor (a[0], a[1], a[2]); }
903 void setAxis1 (dReal x, dReal y, dReal z)
905 void setAxis1 (
const dVector3 a)
906 { setAxis1(a[0], a[1], a[2]); }
907 void setAxis2 (dReal x, dReal y, dReal z)
909 void setAxis2 (
const dVector3 a)
910 { setAxis2(a[0], a[1], a[2]); }
912 void getAnchor (dVector3 result)
const
914 void getAxis1 (dVector3 result)
const
916 void getAxis2 (dVector3 result)
const
919 dReal getPosition()
const
921 dReal getPositionRate()
const
924 dReal getAngle()
const
926 dReal getAngleRate()
const
929 virtual void setParam (
int parameter, dReal value)
931 virtual dReal getParam (
int parameter)
const
937 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
938 class dPUJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase>
942 dPUJointTemplate (
const dPUJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
943 void operator = (
const dPUJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
946 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
948 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
949 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
951 void destroy() { dBaseTemplate::destroy(); }
954 dPUJointTemplate() { }
955 dPUJointTemplate (
dWorldID world, dJointGroupID group=0)
957 dPUJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
960 void create (
dWorldID world, dJointGroupID group=0)
965 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
966 { create(world.id(), group); }
968 void setAnchor (dReal x, dReal y, dReal z)
970 void setAnchor (
const dVector3 a)
971 { setAnchor (a[0], a[1], a[2]); }
972 void setAxis1 (dReal x, dReal y, dReal z)
974 void setAxis1 (
const dVector3 a)
975 { setAxis1(a[0], a[1], a[2]); }
976 void setAxis2 (dReal x, dReal y, dReal z)
978 void setAxis3 (dReal x, dReal y, dReal z)
980 void setAxis3 (
const dVector3 a)
981 { setAxis3(a[0], a[1], a[2]); }
982 void setAxisP (dReal x, dReal y, dReal z)
984 void setAxisP (
const dVector3 a)
985 { setAxisP(a[0], a[1], a[2]); }
987 virtual void getAnchor (dVector3 result)
const
989 void getAxis1 (dVector3 result)
const
991 void getAxis2 (dVector3 result)
const
993 void getAxis3 (dVector3 result)
const
995 void getAxisP (dVector3 result)
const
998 dReal getAngle1()
const
1000 dReal getAngle1Rate()
const
1002 dReal getAngle2()
const
1004 dReal getAngle2Rate()
const
1007 dReal getPosition()
const
1009 dReal getPositionRate()
const
1012 virtual void setParam (
int parameter, dReal value)
1014 virtual dReal getParam (
int parameter)
const
1023 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1024 class dPistonJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase>
1028 dPistonJointTemplate (
const dPistonJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1029 void operator = (
const dPistonJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1032 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1034 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1035 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1037 void destroy() { dBaseTemplate::destroy(); }
1040 dPistonJointTemplate() { }
1041 dPistonJointTemplate (
dWorldID world, dJointGroupID group=0)
1043 dPistonJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1046 void create (
dWorldID world, dJointGroupID group=0)
1051 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1052 { create(world.id(), group); }
1054 void setAnchor (dReal x, dReal y, dReal z)
1056 void setAnchor (
const dVector3 a)
1057 { setAnchor (a[0], a[1], a[2]); }
1058 void getAnchor (dVector3 result)
const
1060 void getAnchor2 (dVector3 result)
const
1063 void setAxis (dReal x, dReal y, dReal z)
1065 void setAxis (
const dVector3 a)
1066 { setAxis(a[0], a[1], a[2]); }
1067 void getAxis (dVector3 result)
const
1070 dReal getPosition()
const
1072 dReal getPositionRate()
const
1075 virtual void setParam (
int parameter, dReal value)
1077 virtual dReal getParam (
int parameter)
const
1081 void addForce (dReal force)
1087 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1088 class dFixedJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase>
1092 dFixedJointTemplate (
const dFixedJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1093 void operator = (
const dFixedJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1096 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1098 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1099 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1101 void destroy() { dBaseTemplate::destroy(); }
1104 dFixedJointTemplate() { }
1105 dFixedJointTemplate (
dWorldID world, dJointGroupID group=0)
1107 dFixedJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1110 void create (
dWorldID world, dJointGroupID group=0) {
1114 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1115 { create(world.id(), group); }
1120 virtual void setParam (
int parameter, dReal value)
1121 { dJointSetFixedParam (get_id(), parameter, value); }
1123 virtual dReal getParam (
int parameter)
const
1129 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1130 class dContactJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
1133 dContactJointTemplate (
const dContactJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1134 void operator = (
const dContactJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1137 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1139 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1140 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1142 void destroy() { dBaseTemplate::destroy(); }
1145 dContactJointTemplate() { }
1146 dContactJointTemplate (
dWorldID world, dJointGroupID group,
dContact *contact)
1148 dContactJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group,
dContact *contact)
1156 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group,
dContact *contact)
1157 { create(world.id(), group, contact); }
1161 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1162 class dNullJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
1165 dNullJointTemplate (
const dNullJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1166 void operator = (
const dNullJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1169 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1171 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1172 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1174 void destroy() { dBaseTemplate::destroy(); }
1177 dNullJointTemplate() { }
1178 dNullJointTemplate (
dWorldID world, dJointGroupID group=0)
1179 { set_id(dJointCreateNull(world, group)); }
1180 dNullJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1181 { set_id(dJointCreateNull (world.id(), group)); }
1183 void create (
dWorldID world, dJointGroupID group=0) {
1185 set_id(dJointCreateNull(world, group));
1187 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1188 { create(world.id(), group); }
1192 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1193 class dAMotorJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
1196 dAMotorJointTemplate (
const dAMotorJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1197 void operator = (
const dAMotorJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1200 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1202 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1203 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1205 void destroy() { dBaseTemplate::destroy(); }
1208 dAMotorJointTemplate() { }
1209 dAMotorJointTemplate (
dWorldID world, dJointGroupID group=0)
1211 dAMotorJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1214 void create (
dWorldID world, dJointGroupID group=0) {
1218 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1219 { create(world.id(), group); }
1221 void setMode (
int mode)
1226 void setNumAxes (
int num)
1228 int getNumAxes()
const
1231 void setAxis (
int anum,
int rel, dReal x, dReal y, dReal z)
1233 void setAxis (
int anum,
int rel,
const dVector3 a)
1234 { setAxis(anum, rel, a[0], a[1], a[2]); }
1235 void getAxis (
int anum, dVector3 result)
const
1237 int getAxisRel (
int anum)
const
1240 void setAngle (
int anum, dReal angle)
1242 dReal getAngle (
int anum)
const
1244 dReal getAngleRate (
int anum)
1247 void setParam (
int parameter, dReal value)
1249 dReal getParam (
int parameter)
const
1253 void addTorques(dReal torque1, dReal torque2, dReal torque3)
1258 template <
class dJo
intTemplateBase,
class dWorldTemplateBase,
class dBodyTemplateBase>
1259 class dLMotorJointTemplate :
public dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> {
1262 dLMotorJointTemplate (
const dLMotorJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1263 void operator = (
const dLMotorJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> &);
1266 typedef dJointTemplate<dJointTemplateBase, dWorldTemplateBase, dBodyTemplateBase> dBaseTemplate;
1268 dJointID get_id()
const {
return dBaseTemplate::get_id(); }
1269 void set_id(dJointID value) { dBaseTemplate::set_id(value); }
1271 void destroy() { dBaseTemplate::destroy(); }
1274 dLMotorJointTemplate() { }
1275 dLMotorJointTemplate (
dWorldID world, dJointGroupID group=0)
1277 dLMotorJointTemplate (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1280 void create (
dWorldID world, dJointGroupID group=0) {
1284 void create (dWorldTemplate<dWorldTemplateBase>& world, dJointGroupID group=0)
1285 { create(world.id(), group); }
1287 void setNumAxes (
int num)
1289 int getNumAxes()
const
1292 void setAxis (
int anum,
int rel, dReal x, dReal y, dReal z)
1294 void setAxis (
int anum,
int rel,
const dVector3 a)
1295 { setAxis(anum, rel, a[0], a[1], a[2]); }
1296 void getAxis (
int anum, dVector3 result)
const
1299 void setParam (
int parameter, dReal value)
1301 dReal getParam (
int parameter)
const
1308 #if !defined(dODECPP_WORLD_TEMPLATE_BASE)
1310 #if defined(dODECPP_BODY_TEMPLATE_BASE) || defined(dODECPP_JOINTGROUP_TEMPLATE_BASE) || defined(dODECPP_JOINT_TEMPLATE_BASE)
1311 #error All the odecpp template bases must be defined or not defined together
1314 #define dODECPP_WORLD_TEMPLATE_BASE dWorldDynamicIDContainer
1315 #define dODECPP_BODY_TEMPLATE_BASE dBodyDynamicIDContainer
1316 #define dODECPP_JOINTGROUP_TEMPLATE_BASE dJointGroupDynamicIDContainer
1317 #define dODECPP_JOINT_TEMPLATE_BASE dJointDynamicIDContainer
1319 #else // #if defined(dODECPP_WORLD_TEMPLATE_BASE)
1321 #if !defined(dODECPP_BODY_TEMPLATE_BASE) || !defined(dODECPP_JOINTGROUP_TEMPLATE_BASE) || !defined(dODECPP_JOINT_TEMPLATE_BASE)
1322 #error All the odecpp template bases must be defined or not defined together
1325 #endif // #if defined(dODECPP_WORLD_TEMPLATE_BASE)
1328 typedef dWorldTemplate<dODECPP_WORLD_TEMPLATE_BASE> dWorld;
1329 typedef dBodyTemplate<dODECPP_BODY_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE> dBody;
1330 typedef dJointGroupTemplate<dODECPP_JOINTGROUP_TEMPLATE_BASE> dJointGroup;
1331 typedef dJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dJoint;
1332 typedef dBallJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dBallJoint;
1333 typedef dHingeJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dHingeJoint;
1334 typedef dSliderJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dSliderJoint;
1335 typedef dUniversalJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dUniversalJoint;
1336 typedef dHinge2JointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dHinge2Joint;
1337 typedef dPRJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dPRJoint;
1338 typedef dPUJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dPUJoint;
1339 typedef dPistonJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dPistonJoint;
1340 typedef dFixedJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dFixedJoint;
1341 typedef dContactJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dContactJoint;
1342 typedef dNullJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dNullJoint;
1343 typedef dAMotorJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dAMotorJoint;
1344 typedef dLMotorJointTemplate<dODECPP_JOINT_TEMPLATE_BASE, dODECPP_WORLD_TEMPLATE_BASE, dODECPP_BODY_TEMPLATE_BASE> dLMotorJoint;
ODE_API dReal dBodyGetAngularDamping(dBodyID b)
Get the body's angular damping scale.
Definition: ode.cpp:1034
ODE_API dReal dJointGetUniversalAngle1Rate(dJointID)
Get time derivative of angle.
ODE_API dReal dJointGetAMotorAngle(dJointID, int anum)
Get the current angle for axis.
ODE_API const dReal * dBodyGetAngularVel(dBodyID)
Get the angular velocity of a body.
Definition: ode.cpp:475
ODE_API void dWorldSetAngularDamping(dWorldID w, dReal scale)
Set the world's angular damping scale.
Definition: ode.cpp:1992
ODE_API dReal dJointGetPUPositionRate(dJointID)
Get the PR linear position's time derivative.
ODE_API void dBodyAddRelTorque(dBodyID, dReal fx, dReal fy, dReal fz)
Add torque at centre of mass of body in coordinates relative to body.
Definition: ode.cpp:542
ODE_API void dJointGetPistonAnchor2(dJointID, dVector3 result)
Get the joint anchor w.r.t. body 2.
ODE_API dReal dJointGetPUAngle1Rate(dJointID)
ODE_API void dBodyDisable(dBodyID)
Manually disable a body.
Definition: ode.cpp:854
ODE_API void dJointAddHinge2Torques(dJointID joint, dReal torque1, dReal torque2)
Applies torque1 about the hinge2's axis 1, torque2 about the hinge2's axis 2.
ODE_API int dBodyGetAutoDisableSteps(dBodyID)
Get auto steps a body must be thought of as idle to disable.
Definition: ode.cpp:951
ODE_API void dBodyEnable(dBodyID)
Manually enable a body.
Definition: ode.cpp:844
ODE_API dJointID dJointCreateLMotor(dWorldID, dJointGroupID)
Create a new joint of the L-motor type.
Definition: ode.cpp:1248
ODE_API dReal dJointGetBallParam(dJointID, int parameter)
get joint parameter
ODE_API int dBodyGetAutoDisableFlag(dBodyID)
Get auto disable flag.
Definition: ode.cpp:979
ODE_API void dBodySetPosition(dBodyID, dReal x, dReal y, dReal z)
Set position of a body.
Definition: ode.cpp:345
ODE_API dReal dWorldGetAngularDamping(dWorldID w)
Get the world's angular damping scale.
Definition: ode.cpp:1986
ODE_API void dJointAddSliderForce(dJointID joint, dReal force)
Applies the given force in the slider's direction.
ODE_API dReal dJointGetUniversalAngle2(dJointID)
Get angle.
ODE_API void dBodyAddRelForce(dBodyID, dReal fx, dReal fy, dReal fz)
Add force at centre of mass of body in coordinates relative to body.
Definition: ode.cpp:527
ODE_API const dReal * dBodyGetLinearVel(dBodyID)
Get the linear velocity of a body.
Definition: ode.cpp:468
ODE_API dReal dJointGetPUParam(dJointID, int parameter)
get joint parameter
ODE_API void dBodySetGyroscopicMode(dBodyID b, int enabled)
Enable/disable the body's gyroscopic term.
Definition: ode.cpp:1136
ODE_API void dBodySetAngularDampingThreshold(dBodyID b, dReal threshold)
Set the body's angular damping threshold.
Definition: ode.cpp:1076
ODE_API void dWorldSetAutoDisableSteps(dWorldID, int steps)
Set auto disable steps for newly created bodies.
Definition: ode.cpp:1906
ODE_API int dJointIsEnabled(dJointID)
Check wether a joint is enabled.
ODE_API void dBodySetAutoDisableAngularThreshold(dBodyID, dReal angular_average_threshold)
Set auto disable angular average threshold.
Definition: ode.cpp:906
ODE_API void dJointGroupDestroy(dJointGroupID)
Destroy a joint group.All joints in the joint group will be destroyed.
Definition: ode.cpp:1312
ODE_API void dJointDisable(dJointID)
Manually disable a joint.
ODE_API void dBodySetDynamic(dBodyID)
Set rigid body to dynamic state (default).
Definition: ode.cpp:824
ODE_API dReal dJointGetPUAngle2(dJointID)
Get angle.
ODE_API dReal dJointGetPRPositionRate(dJointID)
Get the PR linear position's time derivative.
ODE_API dReal dBodyGetLinearDampingThreshold(dBodyID b)
Get the body's linear damping threshold.
Definition: ode.cpp:1057
ODE_API void dJointSetAMotorNumAxes(dJointID, int num)
set the nr of axes
ODE_API void dWorldSetContactSurfaceLayer(dWorldID, dReal depth)
Set the depth of the surface layer around all geometry objects.
Definition: ode.cpp:2068
ODE_API void dBodySetFiniteRotationMode(dBodyID, int mode)
controls the way a body's orientation is updated at each timestep.
Definition: ode.cpp:759
ODE_API dReal dJointGetHinge2Angle2Rate(dJointID)
Get time derivative of angle.
ODE_API int dBodyGetNumJoints(dBodyID b)
Get the number of joints that are attached to this body.
Definition: ode.cpp:805
ODE_API dReal dBodyGetLinearDamping(dBodyID b)
Get the body's linear damping scale.
Definition: ode.cpp:1018
ODE_API void dJointSetPUAxis1(dJointID, dReal x, dReal y, dReal z)
set the axis for the first axis or the universal articulation
ODE_API void dBodyDestroy(dBodyID)
Destroy a body.
ODE_API void dWorldGetGravity(dWorldID, dVector3 gravity)
Get the gravity vector for a given world.
Definition: ode.cpp:1624
ODE_API void dBodySetAngularDamping(dBodyID b, dReal scale)
Set the body's angular damping scale.
Definition: ode.cpp:1040
ODE_API void dWorldSetGravity(dWorldID, dReal x, dReal y, dReal z)
Set the world's global gravity vector.
Definition: ode.cpp:1615
ODE_API dReal dJointGetPRAngleRate(dJointID)
Get the PR angular position's time derivative.
ODE_API dReal dJointGetUniversalAngle1(dJointID)
Get angle.
ODE_API void dJointSetHinge2Axis1(dJointID, dReal x, dReal y, dReal z)
set axis
ODE_API dReal dWorldGetAutoDisableAngularThreshold(dWorldID)
Get auto disable angular threshold for newly created bodies.
Definition: ode.cpp:1871
ODE_API void dBodySetTorque(dBodyID b, dReal x, dReal y, dReal z)
Set the body torque accumulation vector.
Definition: ode.cpp:662
ODE_API dReal dWorldGetLinearDamping(dWorldID w)
Get the world's linear damping scale.
Definition: ode.cpp:1970
ODE_API void dJointSetPistonAxis(dJointID, dReal x, dReal y, dReal z)
set the joint axis
ODE_API void dJointSetAMotorAxis(dJointID, int anum, int rel, dReal x, dReal y, dReal z)
set axis
ODE_API dReal dJointGetHingeAngle(dJointID)
Get the hinge angle.
ODE_API void dJointSetData(dJointID, void *data)
Set the user-data pointer.
ODE_API int dBodyIsKinematic(dBodyID)
Check wether a body is in kinematic state.
Definition: ode.cpp:838
ODE_API void dJointGetPUAxis1(dJointID, dVector3 result)
Get the first axis of the universal component of the joint.
ODE_API dJointID dJointCreatePR(dWorldID, dJointGroupID)
Create a new joint of the PR (Prismatic and Rotoide) type.
Definition: ode.cpp:1210
ODE_API void dWorldDestroy(dWorldID world)
Destroy a world and everything in it.
ODE_API dReal dJointGetPUPosition(dJointID)
Get the PU linear position (i.e. the prismatic's extension)
ODE_API int dWorldGetAutoDisableFlag(dWorldID)
Get auto disable flag for newly created bodies.
Definition: ode.cpp:1927
ODE_API void dBodySetDampingDefaults(dBodyID b)
Resets the damping settings to the current world's settings.
Definition: ode.cpp:1082
ODE_API void dJointGetPistonAnchor(dJointID, dVector3 result)
Get the joint anchor.
ODE_API dReal dWorldGetAutoDisableTime(dWorldID)
Get auto disable time for newly created bodies.
Definition: ode.cpp:1913
ODE_API dReal dJointGetPRPosition(dJointID)
Get the PR linear position (i.e. the prismatic's extension)
ODE_API const dReal * dBodyGetForce(dBodyID)
Return the current accumulated force vector.
Definition: ode.cpp:639
ODE_API void dJointGetUniversalAxis2(dJointID, dVector3 result)
Get axis.
ODE_API dJointType dJointGetType(dJointID)
Get the type of the joint.
ODE_API void dJointSetUniversalAnchor(dJointID, dReal x, dReal y, dReal z)
set anchor
ODE_API void * dJointGetData(dJointID)
Get the user-data pointer.
ODE_API dJointGroupID dJointGroupCreate(int max_size)
Create a joint group.
Definition: ode.cpp:1304
ODE_API dJointID dJointCreateSlider(dWorldID, dJointGroupID)
Create a new joint of the slider type.
Definition: ode.cpp:1179
ODE_API void dBodySetLinearVel(dBodyID, dReal x, dReal y, dReal z)
Set the linear velocity of a body.
Definition: ode.cpp:389
ODE_API void dJointSetPRParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dJointSetHingeAxis(dJointID, dReal x, dReal y, dReal z)
Set hinge axis.
ODE_API void dBodyAddRelForceAtRelPos(dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz)
Add force at specified point in body in local coordinates.
Definition: ode.cpp:617
ODE_API void dJointGetHingeAnchor(dJointID, dVector3 result)
Get the hinge anchor point, in world coordinates.
ODE_API dJointID dJointCreateUniversal(dWorldID, dJointGroupID)
Create a new joint of the universal type.
Definition: ode.cpp:1204
ODE_API void dJointGetUniversalAxis1(dJointID, dVector3 result)
Get axis.
ODE_API dReal dBodyGetAutoDisableLinearThreshold(dBodyID)
Get auto disable linear average threshold.
Definition: ode.cpp:885
ODE_API void dBodyGetPointVel(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
Get velocity vector in global coords of a globally specified point on a body.
Definition: ode.cpp:704
ODE_API dReal dJointGetHingeParam(dJointID, int parameter)
get joint parameter
ODE_API void dWorldSetAutoDisableTime(dWorldID, dReal time)
Set auto disable time for newly created bodies.
Definition: ode.cpp:1920
ODE_API void dJointSetUniversalAxis1(dJointID, dReal x, dReal y, dReal z)
set axis
ODE_API void dJointSetAMotorMode(dJointID, int mode)
set mode
ODE_API void dJointSetHingeAnchor(dJointID, dReal x, dReal y, dReal z)
Set hinge anchor parameter.
ODE_API void dBodySetQuaternion(dBodyID, const dQuaternion q)
Set the orientation of a body.
Definition: ode.cpp:373
ODE_API void dBodyGetFiniteRotationAxis(dBodyID, dVector3 result)
Get the finite rotation axis.
Definition: ode.cpp:796
ODE_API void dWorldSetERP(dWorldID, dReal erp)
Set the global ERP value, that controls how much error correction is performed in each time step...
Definition: ode.cpp:1633
ODE_API void dWorldSetQuickStepW(dWorldID, dReal over_relaxation)
Set the SOR over-relaxation parameter.
Definition: ode.cpp:2040
Definition: ode/src/objects.h:161
ODE_API void dJointSetPistonParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dJointAttach(dJointID, dBodyID body1, dBodyID body2)
Attach the joint to some new bodies.If the joint is already attached, it will be detached from the ol...
ODE_API dReal dJointGetUniversalAngle2Rate(dJointID)
Get time derivative of angle.
ODE_API void dBodySetForce(dBodyID b, dReal x, dReal y, dReal z)
Set the body force accumulation vector.
Definition: ode.cpp:653
ODE_API void dJointGetHingeAnchor2(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API void dBodySetLinearDamping(dBodyID b, dReal scale)
Set the body's linear damping scale.
Definition: ode.cpp:1024
ODE_API void dBodySetDamping(dBodyID b, dReal linear_scale, dReal angular_scale)
Convenience function to set linear and angular scales at once.
Definition: ode.cpp:1050
ODE_API int dJointGetLMotorNumAxes(dJointID)
Get nr of axes.
ODE_API dReal dWorldGetCFM(dWorldID)
Get the constraint force mixing value.
Definition: ode.cpp:1654
ODE_API dReal dWorldGetERP(dWorldID)
Get the error reduction parameter.
Definition: ode.cpp:1640
ODE_API void dJointDestroy(dJointID)
Destroy a joint.disconnects it from its attached bodies and removing it from the world. However, if the joint is a member of a group then this function has no effect - to destroy that joint the group must be emptied or destroyed.
ODE_API void dJointAddAMotorTorques(dJointID, dReal torque1, dReal torque2, dReal torque3)
Applies torque0 about the AMotor's axis 0, torque1 about the AMotor's axis 1, and torque2 about the A...
ODE_API void dBodyVectorToWorld(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
Convert from local to world coordinates.
Definition: ode.cpp:733
ODE_API dJointID dJointCreatePiston(dWorldID, dJointGroupID)
Create a new joint of the Piston type.
Definition: ode.cpp:1222
ODE_API void dBodyGetPosRelPoint(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
takes a point in global coordinates and returns the point's position in body-relative coordinates...
Definition: ode.cpp:720
ODE_API void dBodyGetRelPointPos(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
Get world position of a relative point on body.
Definition: ode.cpp:671
ODE_API void dJointSetBallParam(dJointID, int parameter, dReal value)
Param setting for Ball joints.
ODE_API void dJointGetSliderAxis(dJointID, dVector3 result)
Get the slider axis.
ODE_API void dBodyAddTorque(dBodyID, dReal fx, dReal fy, dReal fz)
Add torque at centre of mass of body in absolute coordinates.
Definition: ode.cpp:518
ODE_API int dWorldGetQuickStepNumIterations(dWorldID)
Get the number of iterations that the QuickStep method performs per step.
Definition: ode.cpp:2033
ODE_API void dJointSetUniversalParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void * dBodyGetData(dBodyID)
Get the body's user-data pointer.
Definition: ode.cpp:338
ODE_API void dBodySetGravityMode(dBodyID b, int mode)
Set whether the body is influenced by the world's gravity or not.
Definition: ode.cpp:868
ODE_API void dBodyVectorFromWorld(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
Convert from world to local coordinates.
Definition: ode.cpp:746
ODE_API void dJointSetPistonAnchor(dJointID, dReal x, dReal y, dReal z)
set the joint anchor
ODE_API void dJointSetFeedback(dJointID, dJointFeedback *)
Sets the datastructure that is to receive the feedback.
ODE_API void dJointSetAMotorAngle(dJointID, int anum, dReal angle)
Tell the AMotor what the current angle is along axis anum.
ODE_API void dBodyAddRelForceAtPos(dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz)
Add force at specified point in body in global coordinates.
Definition: ode.cpp:596
ODE_API dReal dJointGetPRAngle(dJointID)
Get the PR angular position (i.e. the twist between the 2 bodies)
ODE_API dReal dJointGetSliderPosition(dJointID)
Get the slider linear position (i.e. the slider's extension)
ODE_API dReal dJointGetLMotorParam(dJointID, int parameter)
get joint parameter
ODE_API dReal dBodyGetAngularDampingThreshold(dBodyID b)
Get the body's angular damping threshold.
Definition: ode.cpp:1070
ODE_API void dBodyGetRelPointVel(dBodyID, dReal px, dReal py, dReal pz, dVector3 result)
Get velocity vector in global coords of a relative point on body.
Definition: ode.cpp:687
ODE_API dReal dWorldGetAutoDisableLinearThreshold(dWorldID)
Get auto disable linear threshold for newly created bodies.
Definition: ode.cpp:1857
ODE_API void dBodySetMaxAngularSpeed(dBodyID b, dReal max_speed)
Set the body's maximum angular speed.
Definition: ode.cpp:1099
ODE_API void dJointGetPRAnchor(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API int dJointGetAMotorMode(dJointID)
Get the angular motor mode.
ODE_API dReal dJointGetAMotorParam(dJointID, int parameter)
get joint parameter
ODE_API void dJointSetPUParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dJointSetHinge2Anchor(dJointID, dReal x, dReal y, dReal z)
set anchor
ODE_API dJointID dJointCreateContact(dWorldID, dJointGroupID, const dContact *)
Create a new joint of the contact type.
Definition: ode.cpp:1186
ODE_API dReal dJointGetSliderParam(dJointID, int parameter)
get joint parameter
ODE_API dReal dJointGetHinge2Param(dJointID, int parameter)
get joint parameter
ODE_API void dBodySetAutoDisableFlag(dBodyID, int do_auto_disable)
Set auto disable flag.
Definition: ode.cpp:986
ODE_API void dJointSetHinge2Axis2(dJointID, dReal x, dReal y, dReal z)
set axis
ODE_API int dJointGetAMotorNumAxes(dJointID)
Get the number of angular axes that will be controlled by the AMotor.
ODE_API dReal dJointGetAMotorAngleRate(dJointID, int anum)
Get the current angle rate for axis anum.
ODE_API void dWorldSetQuickStepNumIterations(dWorldID, int num)
Set the number of iterations that the QuickStep method performs per step.
Definition: ode.cpp:2026
ODE_API dReal dWorldGetQuickStepW(dWorldID)
Get the SOR over-relaxation parameter.
Definition: ode.cpp:2047
Definition: ode/src/objects.h:131
ODE_API int dWorldStep(dWorldID w, dReal stepsize)
Step the world.
Definition: ode.cpp:1803
ODE_API void dWorldSetLinearDamping(dWorldID w, dReal scale)
Set the world's linear damping scale.
Definition: ode.cpp:1976
ODE_API dReal dJointGetFixedParam(dJointID, int parameter)
get joint parameter
ODE_API void dBodyAddForce(dBodyID, dReal fx, dReal fy, dReal fz)
Add force at centre of mass of body in absolute coordinates.
Definition: ode.cpp:509
ODE_API int dWorldQuickStep(dWorldID w, dReal stepsize)
Quick-step the world.
Definition: ode.cpp:1822
ODE_API int dBodyGetFiniteRotationMode(dBodyID)
Get the way a body's orientation is updated each timestep.
Definition: ode.cpp:789
ODE_API void dBodySetLinearDampingThreshold(dBodyID b, dReal threshold)
Set the body's linear damping threshold.
Definition: ode.cpp:1063
ODE_API void dJointGetUniversalAnchor2(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API void dJointGetPUAnchor(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API dJointFeedback * dJointGetFeedback(dJointID)
Gets the datastructure that is to receive the feedback.
ODE_API void dJointSetPRAnchor(dJointID, dReal x, dReal y, dReal z)
set anchor
ODE_API void dJointGetPRAxis1(dJointID, dVector3 result)
Get the prismatic axis.
ODE_API void dBodySetMass(dBodyID, const dMass *mass)
Set the mass of a body.
Definition: ode.cpp:482
ODE_API void dJointAddPistonForce(dJointID joint, dReal force)
Applies the given force in the slider's direction.
ODE_API void dJointGetAMotorAxis(dJointID, int anum, dVector3 result)
Get the AMotor axes.
ODE_API dReal dJointGetSliderPositionRate(dJointID)
Get the slider linear position's time derivative.
ODE_API void dJointGetHinge2Anchor(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API void dBodyAddForceAtRelPos(dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz)
Add force at specified point in body in local coordinates.
Definition: ode.cpp:575
ODE_API dJointID dJointCreateHinge2(dWorldID, dJointGroupID)
Create a new joint of the hinge2 type.
Definition: ode.cpp:1197
ODE_API void dJointEnable(dJointID)
Manually enable a joint.
ODE_API dReal dJointGetHingeAngleRate(dJointID)
Get the hinge angle time derivative.
ODE_API int dJointGetAMotorAxisRel(dJointID, int anum)
Get axis.
ODE_API void dJointSetFixed(dJointID)
Call this on the fixed joint after it has been attached to remember the current desired relative offs...
ODE_API void dJointAddUniversalTorques(dJointID joint, dReal torque1, dReal torque2)
Applies torque1 about the universal's axis 1, torque2 about the universal's axis 2.
ODE_API dReal dWorldGetLinearDampingThreshold(dWorldID w)
Get the world's linear damping threshold.
Definition: ode.cpp:1946
ODE_API void dJointSetPRAxis1(dJointID, dReal x, dReal y, dReal z)
set the axis for the prismatic articulation
ODE_API dReal dBodyGetAutoDisableTime(dBodyID)
Get auto disable time.
Definition: ode.cpp:965
ODE_API void dBodySetFiniteRotationAxis(dBodyID, dReal x, dReal y, dReal z)
sets the finite rotation axis for a body.
Definition: ode.cpp:773
ODE_API void dBodyGetMass(dBodyID, dMass *mass)
Get the mass of a body.
Definition: ode.cpp:502
ODE_API void dBodySetKinematic(dBodyID)
Set rigid body to kinematic state. When in kinematic state the body isn't simulated as a dynamic body...
Definition: ode.cpp:831
ODE_API dReal dWorldGetAngularDampingThreshold(dWorldID w)
Get the world's angular damping threshold.
Definition: ode.cpp:1958
ODE_API void dJointGetPistonAxis(dJointID, dVector3 result)
Get the prismatic axis (This is also the rotoide axis.
ODE_API dJointID dJointCreateHinge(dWorldID, dJointGroupID)
Create a new joint of the hinge type.
Definition: ode.cpp:1172
ODE_API void dJointSetAMotorParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API int dWorldGetAutoDisableSteps(dWorldID)
Get auto disable steps for newly created bodies.
Definition: ode.cpp:1899
ODE_API void dJointGetLMotorAxis(dJointID, int anum, dVector3 result)
Get axis.
ODE_API void dJointGroupEmpty(dJointGroupID)
Empty a joint group.All joints in the joint group will be destroyed, but the joint group itself will ...
Definition: ode.cpp:1319
ODE_API void dJointSetPUAxis3(dJointID, dReal x, dReal y, dReal z)
set the axis for the prismatic articulation
ODE_API void dJointSetLMotorNumAxes(dJointID, int num)
Set the number of axes that will be controlled by the LMotor.
ODE_API void dJointGetPUAxis3(dJointID, dVector3 result)
Get the prismatic axis.
ODE_API dJointID dJointCreatePU(dWorldID, dJointGroupID)
Create a new joint of the PU (Prismatic and Universal) type.
Definition: ode.cpp:1216
ODE_API const dReal * dBodyGetTorque(dBodyID)
Return the current accumulated torque vector.
Definition: ode.cpp:646
ODE_API void dJointGetPRAxis2(dJointID, dVector3 result)
Get the Rotoide axis.
ODE_API dJointID dJointCreateFixed(dWorldID, dJointGroupID)
Create a new joint of the fixed type.
Definition: ode.cpp:1228
ODE_API void dWorldSetAutoDisableAngularThreshold(dWorldID, dReal angular_threshold)
Set auto disable angular threshold for newly created bodies.
Definition: ode.cpp:1878
ODE_API void dJointSetLMotorAxis(dJointID, int anum, int rel, dReal x, dReal y, dReal z)
Set the AMotor axes.
ODE_API dReal dJointGetPRParam(dJointID, int parameter)
get joint parameter
ODE_API dReal dJointGetUniversalParam(dJointID, int parameter)
get joint parameter
ODE_API dJointID dJointCreateAMotor(dWorldID, dJointGroupID)
Create a new joint of the A-motor type.
Definition: ode.cpp:1242
ODE_API void dBodySetAutoDisableSteps(dBodyID, int steps)
Set auto disable steps.
Definition: ode.cpp:958
ODE_API void dJointSetPRAxis2(dJointID, dReal x, dReal y, dReal z)
set the axis for the rotoide articulation
ODE_API const dReal * dBodyGetRotation(dBodyID)
Get the rotation of a body.
Definition: ode.cpp:424
ODE_API void dWorldSetAutoDisableLinearThreshold(dWorldID, dReal linear_threshold)
Set auto disable linear threshold for newly created bodies.
Definition: ode.cpp:1864
ODE_API void dJointGetHinge2Axis2(dJointID, dVector3 result)
Get joint axis.
ODE_API void dJointGetHinge2Axis1(dJointID, dVector3 result)
Get joint axis.
ODE_API dReal dJointGetHinge2Angle1Rate(dJointID)
Get time derivative of angle.
ODE_API int dAreConnected(dBodyID, dBodyID)
Utility function.
Definition: ode.cpp:1547
ODE_API void dJointSetHinge2Param(dJointID, int parameter, dReal value)
set joint parameter
ODE_API dBodyID dJointGetBody(dJointID, int index)
Return the bodies that this joint connects.
ODE_API void dJointGetHinge2Anchor2(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates. This returns the point on body 2. If the joint is perfectly satisfied, this will return the same value as dJointGetHinge2Anchor. If not, this value will be slightly different. This can be used, for example, to see how far the joint has come apart.
ODE_API dReal dJointGetPistonPositionRate(dJointID)
Get the piston linear position's time derivative.
ODE_API void dBodySetData(dBodyID, void *data)
Set the body's user-data pointer.
Definition: ode.cpp:331
ODE_API void dBodySetAutoDisableLinearThreshold(dBodyID, dReal linear_average_threshold)
Set auto disable linear average threshold.
Definition: ode.cpp:892
ODE_API void dWorldImpulseToForce(dWorldID, dReal stepsize, dReal ix, dReal iy, dReal iz, dVector3 force)
Converts an impulse to a force.
Definition: ode.cpp:1842
ODE_API void dBodySetAngularVel(dBodyID, dReal x, dReal y, dReal z)
Set the angular velocity of a body.
Definition: ode.cpp:398
ODE_API void dBodySetAutoDisableTime(dBodyID, dReal time)
Set auto disable time.
Definition: ode.cpp:972
ODE_API void dJointSetSliderParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dJointSetUniversalAxis2(dJointID, dReal x, dReal y, dReal z)
set axis
ODE_API dJointID dJointCreateBall(dWorldID, dJointGroupID)
Create a new joint of the ball type.
Definition: ode.cpp:1165
ODE_API dReal dJointGetPistonParam(dJointID, int parameter)
get joint parameter
ODE_API void dJointSetBallAnchor(dJointID, dReal x, dReal y, dReal z)
Set the joint anchor point.The joint will try to keep this point on each body together. The input is specified in world coordinates.
ODE_API void dWorldSetLinearDampingThreshold(dWorldID w, dReal threshold)
Set the world's linear damping threshold.
Definition: ode.cpp:1952
ODE_API void dJointSetPUAxis2(dJointID, dReal x, dReal y, dReal z)
set the axis for the second axis or the universal articulation
ODE_API dReal dJointGetPistonPosition(dJointID)
Get the Piston linear position (i.e. the piston's extension)
ODE_API dReal dJointGetPUAngle1(dJointID)
Get angle.
ODE_API void dJointSetPUAnchor(dJointID, dReal x, dReal y, dReal z)
set anchor
ODE_API int dBodyGetGravityMode(dBodyID b)
Get whether the body is influenced by the world's gravity or not.
Definition: ode.cpp:876
ODE_API dReal dJointGetHinge2Angle1(dJointID)
Get angle.
ODE_API dReal dBodyGetMaxAngularSpeed(dBodyID b)
Get the body's maximum angular speed.
Definition: ode.cpp:1093
ODE_API void dJointSetSliderAxis(dJointID, dReal x, dReal y, dReal z)
set the joint axis
ODE_API void dJointGetHingeAxis(dJointID, dVector3 result)
get axis
ODE_API void dWorldSetDamping(dWorldID w, dReal linear_scale, dReal angular_scale)
Convenience function to set body linear and angular scales.
Definition: ode.cpp:2002
ODE_API void dJointGetUniversalAngles(dJointID, dReal *angle1, dReal *angle2)
Get both angles at the same time.
ODE_API void dBodySetRotation(dBodyID, const dMatrix3 R)
Set the orientation of a body.
Definition: ode.cpp:358
ODE_API void dJointSetHingeParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dWorldSetAngularDampingThreshold(dWorldID w, dReal threshold)
Set the world's angular damping threshold.
Definition: ode.cpp:1964
ODE_API void dJointSetLMotorParam(dJointID, int parameter, dReal value)
set joint parameter
ODE_API void dJointAddHingeTorque(dJointID joint, dReal torque)
Applies the torque about the hinge axis.
ODE_API dReal dBodyGetAutoDisableAngularThreshold(dBodyID)
Get auto disable angular average threshold.
Definition: ode.cpp:899
ODE_API dWorldID dWorldCreate(void)
Create a new, empty world and return its ID number.
Definition: ode.cpp:1571
ODE_API dReal dJointGetPUAngle2Rate(dJointID)
ODE_API void dWorldSetAutoDisableFlag(dWorldID, int do_auto_disable)
Set auto disable flag for newly created bodies.
Definition: ode.cpp:1934
ODE_API dBodyID dBodyCreate(dWorldID)
Create a body in given world.
ODE_API void dWorldSetCFM(dWorldID, dReal cfm)
Set the global CFM (constraint force mixing) value.
Definition: ode.cpp:1647
ODE_API dJointID dBodyGetJoint(dBodyID, int index)
Return a joint attached to this body, given by index.
Definition: ode.cpp:814
ODE_API int dBodyIsEnabled(dBodyID)
Check wether a body is enabled.
Definition: ode.cpp:861
ODE_API dReal dWorldGetContactSurfaceLayer(dWorldID)
Get the depth of the surface layer around all geometry objects.
Definition: ode.cpp:2075
ODE_API int dBodyGetGyroscopicMode(dBodyID b)
Get the body's gyroscopic state.
Definition: ode.cpp:1130
ODE_API int dJointGetNumBodies(dJointID)
Return the number of bodies attached to the joint.
ODE_API const dReal * dBodyGetPosition(dBodyID)
Get the position of a body.
Definition: ode.cpp:407
ODE_API dReal dWorldGetMaxAngularSpeed(dWorldID w)
Get the default maximum angular speed.
Definition: ode.cpp:2009
ODE_API void dWorldSetMaxAngularSpeed(dWorldID w, dReal max_speed)
Set the default maximum angular speed for new bodies.
Definition: ode.cpp:2015
ODE_API const dReal * dBodyGetQuaternion(dBodyID)
Get the rotation of a body.
Definition: ode.cpp:450
ODE_API void dJointGetUniversalAnchor(dJointID, dVector3 result)
Get the joint anchor point, in world coordinates.
ODE_API void dBodyAddForceAtPos(dBodyID, dReal fx, dReal fy, dReal fz, dReal px, dReal py, dReal pz)
Add force at specified point in body in global coordinates.
Definition: ode.cpp:557
ODE_API void dJointGetPUAxis2(dJointID, dVector3 result)
Get the second axis of the Universal component of the joint.