#include <spNewtonJoint.hpp>
Public Member Functions | |
NewtonDynamicsJoint (const EPhysicsJoints Type, PhysicsBaseObject *ObjectA, PhysicsBaseObject *ObjectB, const SPhysicsJointConstruct &Construct) | |
virtual | ~NewtonDynamicsJoint () |
void | setPosition (const dim::vector3df &Position) |
dim::vector3df | getPosition () const |
void | setLimit (bool Enable) |
bool | getLimit () const |
void | setLimit (f32 Min, f32 Max, bool Enable=true) |
Sets the limitation values. This can be either an angle or linear value. | |
void | getLimit (f32 &Min, f32 &Max) const |
void | setMotor (bool Enable, f32 MotorPower=100.0f) |
bool | getMotor () const |
void | runMotor (f32 Velocity) |
f32 | getLinearValue () const |
Returns the joint linear value. This can also be an angle (for a hinge-joint). | |
Protected Attributes | |
NewtonJoint * | NtJoint_ |
sp::physics::NewtonDynamicsJoint::NewtonDynamicsJoint | ( | const EPhysicsJoints | Type, | |
PhysicsBaseObject * | ObjectA, | |||
PhysicsBaseObject * | ObjectB, | |||
const SPhysicsJointConstruct & | Construct | |||
) |
virtual sp::physics::NewtonDynamicsJoint::~NewtonDynamicsJoint | ( | ) | [virtual] |
bool sp::physics::NewtonDynamicsJoint::getLimit | ( | ) | const [virtual] |
Implements sp::physics::PhysicsJoint.
Implements sp::physics::PhysicsJoint.
f32 sp::physics::NewtonDynamicsJoint::getLinearValue | ( | ) | const [virtual] |
Returns the joint linear value. This can also be an angle (for a hinge-joint).
Implements sp::physics::PhysicsJoint.
bool sp::physics::NewtonDynamicsJoint::getMotor | ( | ) | const [virtual] |
Implements sp::physics::PhysicsJoint.
dim::vector3df sp::physics::NewtonDynamicsJoint::getPosition | ( | ) | const [virtual] |
Implements sp::physics::PhysicsJoint.
void sp::physics::NewtonDynamicsJoint::runMotor | ( | f32 | Velocity | ) | [virtual] |
Implements sp::physics::PhysicsJoint.
void sp::physics::NewtonDynamicsJoint::setLimit | ( | bool | Enable | ) | [virtual] |
Implements sp::physics::PhysicsJoint.
Sets the limitation values. This can be either an angle or linear value.
Implements sp::physics::PhysicsJoint.
void sp::physics::NewtonDynamicsJoint::setMotor | ( | bool | Enable, | |
f32 | MotorPower = 100.0f | |||
) | [virtual] |
Activates the motor interaction.
Enable,: | Specifies whether the hinge motor is to be enabled or disabled. By default disabled. Once the motor is enabled it runs until it will be disabled. | |
MotorPower,: | Specifies the power of the motor. This should be at least the mass of the heaviest rigid body which is connected to this joint. |
Implements sp::physics::PhysicsJoint.
void sp::physics::NewtonDynamicsJoint::setPosition | ( | const dim::vector3df & | Position | ) | [virtual] |
Implements sp::physics::PhysicsJoint.
NewtonJoint* sp::physics::NewtonDynamicsJoint::NtJoint_ [protected] |