Blender V2.61 - r43446
|
#include <IK_QSegment.h>
An IK_Qsegment encodes information about a segments local coordinate system.
These segments always point along the y-axis.
Here we define the local coordinates of a joint as local_transform = translate(tr1) * rotation(A) * rotation(q) * translate(0,length,0) We use the standard moto column ordered matrices. You can read this as:
Definition at line 65 of file IK_QSegment.h.
IK_QSegment::~IK_QSegment | ( | ) | [virtual] |
Definition at line 282 of file IK_QSegment.cpp.
References m_child, m_parent, m_sibling, NULL, and RemoveChild().
IK_QSegment::IK_QSegment | ( | int | num_DoF, |
bool | translational | ||
) | [protected] |
Definition at line 223 of file IK_QSegment.cpp.
References m_basis, m_locked, m_max_extension, m_orig_basis, m_orig_translation, m_rest_basis, m_start, m_translation, and m_weight.
virtual MT_Vector3 IK_QSegment::Axis | ( | int | dof | ) | const [pure virtual] |
Implemented in IK_QSphericalSegment, IK_QNullSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
Referenced by IK_QOrientationTask::ComputeJacobian(), and IK_QPositionTask::ComputeJacobian().
MT_Matrix3x3 IK_QSegment::BasisChange | ( | ) | const |
Definition at line 272 of file IK_QSegment.cpp.
References m_basis, and m_orig_basis.
Referenced by IK_GetBasisChange().
IK_QSegment* IK_QSegment::Child | ( | ) | const [inline] |
Definition at line 85 of file IK_QSegment.h.
References m_child.
IK_QSegment* IK_QSegment::Composite | ( | ) | const [inline] |
Definition at line 97 of file IK_QSegment.h.
References m_composite.
Referenced by IK_FreeSegment(), IK_GetBasisChange(), IK_GetTranslationChange(), IK_SetLimit(), IK_SetParent(), IK_SetStiffness(), IK_SetTransform(), IK_SolverAddGoal(), and IK_SolverAddGoalOrientation().
int IK_QSegment::DoFId | ( | ) | const [inline] |
Definition at line 105 of file IK_QSegment.h.
References m_DoF_id.
Referenced by IK_QOrientationTask::ComputeJacobian(), and IK_QPositionTask::ComputeJacobian().
const MT_Point3& IK_QSegment::GlobalEnd | ( | ) | const [inline] |
Definition at line 123 of file IK_QSegment.h.
References MT_Transform::getOrigin(), and m_global_transform.
Referenced by IK_QPositionTask::ComputeJacobian(), and IK_QPositionTask::Distance().
const MT_Point3& IK_QSegment::GlobalStart | ( | ) | const [inline] |
Definition at line 120 of file IK_QSegment.h.
References m_global_start.
Referenced by IK_QPositionTask::ComputeJacobian().
const MT_Transform& IK_QSegment::GlobalTransform | ( | ) | const [inline] |
Definition at line 127 of file IK_QSegment.h.
References m_global_transform.
Referenced by IK_QOrientationTask::ComputeJacobian().
virtual void IK_QSegment::Lock | ( | int | , |
IK_QJacobian & | , | ||
MT_Vector3 & | |||
) | [inline, virtual] |
Reimplemented in IK_QSphericalSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
Definition at line 157 of file IK_QSegment.h.
bool IK_QSegment::Locked | ( | int | dof | ) | const [inline] |
Definition at line 135 of file IK_QSegment.h.
References m_locked.
const MT_Scalar IK_QSegment::MaxExtension | ( | ) | const [inline] |
Definition at line 112 of file IK_QSegment.h.
References m_max_extension.
Referenced by IK_QPositionTask::IK_QPositionTask().
int IK_QSegment::NumberOfDoF | ( | ) | const [inline] |
Definition at line 101 of file IK_QSegment.h.
References m_num_DoF.
Referenced by IK_QOrientationTask::ComputeJacobian(), and IK_QPositionTask::ComputeJacobian().
IK_QSegment* IK_QSegment::Parent | ( | ) | const [inline] |
Definition at line 91 of file IK_QSegment.h.
References m_parent.
Referenced by IK_QOrientationTask::ComputeJacobian(), IK_QPositionTask::ComputeJacobian(), and IK_QPositionTask::IK_QPositionTask().
void IK_QSegment::PrependBasis | ( | const MT_Matrix3x3 & | mat | ) |
Definition at line 343 of file IK_QSegment.cpp.
References m_basis, and m_rest_basis.
Referenced by IK_QJacobianSolver::Solve().
void IK_QSegment::RemoveChild | ( | IK_QSegment * | child | ) | [protected] |
Definition at line 312 of file IK_QSegment.cpp.
References m_child, m_sibling, and NULL.
Referenced by SetParent(), and ~IK_QSegment().
void IK_QSegment::Reset | ( | ) |
Definition at line 241 of file IK_QSegment.cpp.
References m_basis, m_child, m_locked, m_orig_basis, m_orig_translation, m_sibling, m_translation, and SetBasis().
void IK_QSegment::Scale | ( | float | scale | ) | [virtual] |
Reimplemented in IK_QTranslateSegment.
Definition at line 348 of file IK_QSegment.cpp.
References MT_Transform::getOrigin(), m_global_start, m_global_transform, m_max_extension, m_orig_translation, m_start, and m_translation.
void IK_QSegment::ScaleWeight | ( | int | dof, |
MT_Scalar | scale | ||
) | [inline] |
Definition at line 145 of file IK_QSegment.h.
References m_weight.
virtual void IK_QSegment::SetBasis | ( | const MT_Matrix3x3 & | basis | ) | [inline, virtual] |
Reimplemented in IK_QNullSegment, IK_QRevoluteSegment, IK_QSwingSegment, and IK_QElbowSegment.
Definition at line 166 of file IK_QSegment.h.
References m_basis.
Referenced by Reset(), and SetTransform().
void IK_QSegment::SetComposite | ( | IK_QSegment * | seg | ) |
Definition at line 307 of file IK_QSegment.cpp.
References m_composite.
Referenced by IK_CreateSegment().
void IK_QSegment::SetDoFId | ( | int | dof_id | ) | [inline] |
Definition at line 108 of file IK_QSegment.h.
References m_DoF_id.
Referenced by IK_QJacobianSolver::Setup().
Reimplemented in IK_QSphericalSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
Definition at line 161 of file IK_QSegment.h.
Referenced by IK_SetLimit().
void IK_QSegment::SetParent | ( | IK_QSegment * | parent | ) |
Definition at line 291 of file IK_QSegment.cpp.
References m_child, m_parent, m_sibling, and RemoveChild().
Referenced by IK_CreateSegment(), and IK_SetParent().
void IK_QSegment::SetTransform | ( | const MT_Vector3 & | start, |
const MT_Matrix3x3 & | rest_basis, | ||
const MT_Matrix3x3 & | basis, | ||
const MT_Scalar | length | ||
) |
Definition at line 253 of file IK_QSegment.cpp.
References length(), MT_Vector3::length(), m_max_extension, m_orig_basis, m_orig_translation, m_rest_basis, m_start, m_translation, and SetBasis().
Referenced by IK_SetTransform().
virtual void IK_QSegment::SetWeight | ( | int | , |
MT_Scalar | |||
) | [inline, virtual] |
Reimplemented in IK_QSphericalSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
Definition at line 164 of file IK_QSegment.h.
Referenced by IK_SetStiffness().
IK_QSegment* IK_QSegment::Sibling | ( | ) | const [inline] |
Definition at line 88 of file IK_QSegment.h.
References m_sibling.
bool IK_QSegment::Translational | ( | ) | const [inline] |
Definition at line 131 of file IK_QSegment.h.
References m_translational.
Referenced by IK_QOrientationTask::ComputeJacobian(), IK_QPositionTask::ComputeJacobian(), IK_GetBasisChange(), IK_GetTranslationChange(), IK_SetLimit(), and IK_SetStiffness().
MT_Vector3 IK_QSegment::TranslationChange | ( | ) | const |
Definition at line 277 of file IK_QSegment.cpp.
References m_orig_translation, and m_translation.
Referenced by IK_GetTranslationChange().
void IK_QSegment::UnLock | ( | ) | [inline] |
Definition at line 138 of file IK_QSegment.h.
References m_locked.
virtual bool IK_QSegment::UpdateAngle | ( | const IK_QJacobian & | , |
MT_Vector3 & | , | ||
bool * | |||
) | [pure virtual] |
Implemented in IK_QSphericalSegment, IK_QNullSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
virtual void IK_QSegment::UpdateAngleApply | ( | ) | [pure virtual] |
Implemented in IK_QSphericalSegment, IK_QNullSegment, IK_QRevoluteSegment, IK_QSwingSegment, IK_QElbowSegment, and IK_QTranslateSegment.
void IK_QSegment::UpdateTransform | ( | const MT_Transform & | global | ) |
Definition at line 329 of file IK_QSegment.cpp.
References MT_Transform::getBasis(), MT_Transform::getOrigin(), m_basis, m_child, m_global_start, m_global_transform, m_rest_basis, m_sibling, m_start, m_translation, MT_Transform::setBasis(), MT_Transform::setOrigin(), and MT_Transform::translate().
Referenced by IK_QJacobianSolver::Solve().
MT_Scalar IK_QSegment::Weight | ( | int | dof | ) | const [inline] |
Definition at line 142 of file IK_QSegment.h.
References m_weight.
MT_Matrix3x3 IK_QSegment::m_basis [protected] |
Definition at line 193 of file IK_QSegment.h.
Referenced by BasisChange(), IK_QSegment(), PrependBasis(), Reset(), IK_QElbowSegment::SetBasis(), IK_QNullSegment::SetBasis(), IK_QSwingSegment::SetBasis(), SetBasis(), IK_QRevoluteSegment::SetBasis(), IK_QSwingSegment::UpdateAngle(), IK_QSphericalSegment::UpdateAngle(), IK_QSwingSegment::UpdateAngleApply(), IK_QElbowSegment::UpdateAngleApply(), IK_QSphericalSegment::UpdateAngleApply(), IK_QRevoluteSegment::UpdateAngleApply(), and UpdateTransform().
IK_QSegment* IK_QSegment::m_child [protected] |
Definition at line 185 of file IK_QSegment.h.
Referenced by Child(), RemoveChild(), Reset(), SetParent(), UpdateTransform(), and ~IK_QSegment().
IK_QSegment* IK_QSegment::m_composite [protected] |
Definition at line 187 of file IK_QSegment.h.
Referenced by Composite(), and SetComposite().
int IK_QSegment::m_DoF_id [protected] |
Definition at line 208 of file IK_QSegment.h.
Referenced by DoFId(), IK_QRevoluteSegment::Lock(), IK_QTranslateSegment::Lock(), IK_QElbowSegment::Lock(), IK_QSphericalSegment::Lock(), IK_QSwingSegment::Lock(), SetDoFId(), IK_QSwingSegment::UpdateAngle(), IK_QTranslateSegment::UpdateAngle(), IK_QSphericalSegment::UpdateAngle(), IK_QRevoluteSegment::UpdateAngle(), and IK_QElbowSegment::UpdateAngle().
MT_Point3 IK_QSegment::m_global_start [protected] |
Definition at line 204 of file IK_QSegment.h.
Referenced by GlobalStart(), Scale(), and UpdateTransform().
MT_Transform IK_QSegment::m_global_transform [protected] |
Definition at line 205 of file IK_QSegment.h.
Referenced by IK_QRevoluteSegment::Axis(), IK_QTranslateSegment::Axis(), IK_QSphericalSegment::Axis(), IK_QSwingSegment::Axis(), IK_QElbowSegment::Axis(), GlobalEnd(), GlobalTransform(), Scale(), and UpdateTransform().
bool IK_QSegment::m_locked[3] [protected] |
Definition at line 210 of file IK_QSegment.h.
Referenced by IK_QSegment(), IK_QRevoluteSegment::Lock(), IK_QTranslateSegment::Lock(), IK_QElbowSegment::Lock(), IK_QSphericalSegment::Lock(), IK_QSwingSegment::Lock(), Locked(), Reset(), UnLock(), IK_QSwingSegment::UpdateAngle(), IK_QTranslateSegment::UpdateAngle(), IK_QSphericalSegment::UpdateAngle(), IK_QRevoluteSegment::UpdateAngle(), and IK_QElbowSegment::UpdateAngle().
MT_Scalar IK_QSegment::m_max_extension [protected] |
Definition at line 201 of file IK_QSegment.h.
Referenced by IK_QSegment(), MaxExtension(), Scale(), and SetTransform().
int IK_QSegment::m_num_DoF [protected] |
Definition at line 208 of file IK_QSegment.h.
Referenced by NumberOfDoF(), and IK_QTranslateSegment::SetWeight().
MT_Matrix3x3 IK_QSegment::m_orig_basis [protected] |
Definition at line 197 of file IK_QSegment.h.
Referenced by BasisChange(), IK_QSegment(), Reset(), and SetTransform().
MT_Vector3 IK_QSegment::m_orig_translation [protected] |
Definition at line 198 of file IK_QSegment.h.
Referenced by IK_QSegment(), Reset(), Scale(), SetTransform(), and TranslationChange().
IK_QSegment* IK_QSegment::m_parent [protected] |
Definition at line 184 of file IK_QSegment.h.
Referenced by Parent(), SetParent(), and ~IK_QSegment().
MT_Matrix3x3 IK_QSegment::m_rest_basis [protected] |
Definition at line 192 of file IK_QSegment.h.
Referenced by IK_QSegment(), PrependBasis(), SetTransform(), and UpdateTransform().
IK_QSegment* IK_QSegment::m_sibling [protected] |
Definition at line 186 of file IK_QSegment.h.
Referenced by RemoveChild(), Reset(), SetParent(), Sibling(), UpdateTransform(), and ~IK_QSegment().
MT_Vector3 IK_QSegment::m_start [protected] |
Definition at line 191 of file IK_QSegment.h.
Referenced by IK_QSegment(), Scale(), SetTransform(), and UpdateTransform().
MT_Vector3 IK_QSegment::m_translation [protected] |
Definition at line 194 of file IK_QSegment.h.
Referenced by IK_QSegment(), Reset(), Scale(), SetTransform(), TranslationChange(), IK_QTranslateSegment::UpdateAngle(), IK_QTranslateSegment::UpdateAngleApply(), and UpdateTransform().
bool IK_QSegment::m_translational [protected] |
Definition at line 211 of file IK_QSegment.h.
Referenced by Translational().
MT_Scalar IK_QSegment::m_weight[3] [protected] |
Definition at line 212 of file IK_QSegment.h.
Referenced by IK_QSegment(), ScaleWeight(), IK_QSwingSegment::SetWeight(), IK_QElbowSegment::SetWeight(), IK_QTranslateSegment::SetWeight(), IK_QSphericalSegment::SetWeight(), IK_QRevoluteSegment::SetWeight(), and Weight().