23 link(NxJoint *jointPtr) {
25 _ptr = jointPtr->isD6Joint();
26 _ptr->userData =
this;
32 scene->_joints.add(
this);
41 _ptr->userData =
nullptr;
42 _error_type = ET_released;
45 scene->_joints.remove(
this);
54 nassertv(_error_type == ET_ok);
55 _ptr->saveToDesc(jointDesc._desc);
64 nassertv(_error_type == ET_ok);
65 _ptr->loadFromDesc(jointDesc._desc);
72 set_drive_angular_velocity(
const LVector3f &v) {
74 nassertv(_error_type == ET_ok);
82 set_drive_linear_velocity(
const LVector3f &v) {
84 nassertv(_error_type == ET_ok);
92 set_drive_orientation(
const LQuaternionf &quat) {
94 nassertv(_error_type == ET_ok);
102 set_drive_position(
const LPoint3f &pos) {
104 nassertv(_error_type == ET_ok);
static NxQuat quat_to_nxQuat(const LQuaternionf &q)
Converts from LQuaternionf to NxQuat.
static NxVec3 point3_to_nxVec3(const LPoint3f &p)
Converts from LPoint3f to NxVec3.
A scene is a collection of bodies, constraints, and effectors which can interact.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
static NxVec3 vec3_to_nxVec3(const LVector3f &v)
Converts from LVector3f to NxVec3.
void set_name(const char *name)
Sets a name string for this object.
void save_to_desc(PhysxD6JointDesc &jointDesc) const
Saves the state of the joint object to a descriptor.
TypeHandle is the identifier used to differentiate C++ class types.
void load_from_desc(const PhysxD6JointDesc &jointDesc)
Loads the entire state of the joint from a descriptor with a single call.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.