45 #ifndef CBulletGenericObjectH 46 #define CBulletGenericObjectH 50 #include "btBulletDynamicsCommon.h" 125 virtual void setMass(
const double a_mass);
192 void setDamping(
const double& a_dampingLin,
const double& a_dampingAng);
Definition: CBulletGenericObject.h:75
double getDampingLin()
This method returns the linear damping term for this object.
Definition: CBulletGenericObject.cpp:288
bool m_static
If true then object is static and does not move, false otherwise.
Definition: CBulletGenericObject.h:237
double getDampingAng()
This method returns the angular damping term for this object.
Definition: CBulletGenericObject.cpp:307
cVector3d getInertia()
This method returns the inertia properties of this object.
Definition: CBulletGenericObject.h:134
cBulletDynamicModelType
Bullet geometry used for dynamic collision computation.
Definition: CBulletGenericObject.h:71
Definition: CBulletGenericObject.h:73
double getMass() const
This method returns the mass value for this object.
Definition: CBulletGenericObject.h:128
void addExternalForce(const cVector3d &a_force)
This method applies an external force at the center of mass of this object.
Definition: CBulletGenericObject.cpp:238
virtual void updatePositionFromDynamics()
This method updates the CHAI3D position representation from the Bullet dynamics engine.
Definition: CBulletGenericObject.h:152
virtual bool getStatic() const
This method returns true if the object is static, false otherwise.
Definition: CBulletGenericObject.h:146
cVector3d m_inertia
Inertia properties.
Definition: CBulletGenericObject.h:243
void setDamping(const double &a_dampingLin, const double &a_dampingAng)
This method assigns a linear and angular damping term to the object.
Definition: CBulletGenericObject.cpp:271
void addExternalForceAtPoint(const cVector3d &a_force, const cVector3d &a_relativePos)
This method applies an external force at a given position described in global coordinates to this obj...
Definition: CBulletGenericObject.cpp:221
cBulletGenericObject(cBulletWorld *a_world)
Constructor of cBulletGenericBody.
Definition: CBulletGenericObject.h:102
This class implements an Bullet dynamic world.
Definition: CBulletWorld.h:81
virtual void setMass(const double a_mass)
This method assigns a mass value to this object.
Definition: CBulletGenericObject.cpp:112
virtual void estimateInertia()
This method estimates the inertia properties for this object.
Definition: CBulletGenericObject.cpp:152
double getSurfaceFriction()
This method returns the coefficient of friction for this object.
Definition: CBulletGenericObject.cpp:342
Definition: CBulletGenericObject.h:76
virtual void setStatic(bool a_static)
This method enables of disables the object to be static in the world.
Definition: CBulletGenericObject.cpp:178
btDefaultMotionState * m_bulletMotionState
Bullet motion state.
Definition: CBulletGenericObject.h:217
virtual void buildDynamicModel()
This method builds a dynamic representation of the object in the Bullet world.
Definition: CBulletGenericObject.cpp:193
Definition: CBulletGenericObject.h:93
void addExternalTorque(const cVector3d &a_torque)
This method applies an external torque at the center of mass of of this object.
Definition: CBulletGenericObject.cpp:254
virtual void setMassInertia(const double a_mass, const cVector3d &a_inertia)
This method assigns a mass and an inertia to this object.
Definition: CBulletGenericObject.cpp:139
virtual ~cBulletGenericObject()
Destructor of cBulletGenericBody.
Definition: CBulletGenericObject.cpp:88
cBulletWorld * m_dynamicWorld
Bullet world.
Definition: CBulletGenericObject.h:208
Definition: CBulletGenericObject.h:77
virtual void setInertia(const cVector3d &a_inertia)
This method assigns an inertia properties to this object.
Definition: CBulletGenericObject.cpp:125
virtual void updateBodyPosition(void)
This method updates the position and orientation from the Bullet model to CHAI3D model.
Definition: CBulletGenericObject.h:115
double m_mass
Mass property.
Definition: CBulletGenericObject.h:240
virtual void initialize(cBulletWorld *a_world)
This method initializes the Bullet object.
Definition: CBulletGenericObject.cpp:61
btCollisionShape * m_bulletCollisionShape
Bullet collision shape.
Definition: CBulletGenericObject.h:214
btRigidBody * m_bulletRigidBody
Bullet rigid body.
Definition: CBulletGenericObject.h:211
Definition: CBulletGenericObject.h:74
void setSurfaceFriction(const double a_friction)
This method assign a coefficient of friction to this object.
Definition: CBulletGenericObject.cpp:325