Blender V5.0
btTransform.h File Reference
#include "btMatrix3x3.h"

Go to the source code of this file.

Classes

struct  btTransformFloatData
 for serialization More...
struct  btTransformDoubleData

Macros

#define btTransformData   btTransformFloatData

Functions

SIMD_FORCE_INLINE btTransform (const btQuaternion &q, const btVector3 &c=btVector3(btScalar(0), btScalar(0), btScalar(0)))
 Constructor from btQuaternion (optional btVector3 ).
SIMD_FORCE_INLINE btTransform (const btMatrix3x3 &b, const btVector3 &c=btVector3(btScalar(0), btScalar(0), btScalar(0)))
 Constructor from btMatrix3x3 (optional btVector3).
SIMD_FORCE_INLINE btTransform (const btTransform &other)
 Copy constructor.
SIMD_FORCE_INLINE btTransformoperator= (const btTransform &other)
 Assignment Operator.
SIMD_FORCE_INLINE void mult (const btTransform &t1, const btTransform &t2)
 Set the current transform as the value of the product of two transforms.
SIMD_FORCE_INLINE btVector3 operator() (const btVector3 &x) const
 Return the transform of the vector.
SIMD_FORCE_INLINE btVector3 operator* (const btVector3 &x) const
 Return the transform of the vector.
SIMD_FORCE_INLINE btQuaternion operator* (const btQuaternion &q) const
 Return the transform of the btQuaternion.
SIMD_FORCE_INLINE btMatrix3x3getBasis ()
 Return the basis matrix for the rotation.
SIMD_FORCE_INLINE btVector3getOrigin ()
 Return the origin vector translation.
btQuaternion getRotation () const
 Return a quaternion representing the rotation.
void setFromOpenGLMatrix (const btScalar *m)
 Set from an array.
void getOpenGLMatrix (btScalar *m) const
 Fill an array representation.
SIMD_FORCE_INLINE void setOrigin (const btVector3 &origin)
 Set the translational element.
SIMD_FORCE_INLINE btVector3 invXform (const btVector3 &inVec) const
SIMD_FORCE_INLINE void setBasis (const btMatrix3x3 &basis)
 Set the rotational element by btMatrix3x3.
SIMD_FORCE_INLINE void setRotation (const btQuaternion &q)
 Set the rotational element by btQuaternion.
void setIdentity ()
 Set this transformation to the identity.
btTransformoperator*= (const btTransform &t)
 Multiply this Transform by another(this = this * another).
btTransform inverse () const
 Return the inverse of this transform.
btTransform inverseTimes (const btTransform &t) const
 Return the inverse of this transform times the other transform.
btTransform operator* (const btTransform &t) const
 Return the product of this transform and the other.
static const btTransformgetIdentity ()
 Return an identity transform.
void serialize (struct btTransformData &dataOut) const
void serializeFloat (struct btTransformFloatData &dataOut) const
void deSerialize (const struct btTransformData &dataIn)
void deSerializeDouble (const struct btTransformDoubleData &dataIn)
void deSerializeFloat (const struct btTransformFloatData &dataIn)
SIMD_FORCE_INLINE bool operator== (const btTransform &t1, const btTransform &t2)
 Test if two transforms have all elements equal.

Variables

 btTransform
 The btTransform class supports rigid transforms with only translation and rotation and no scaling/shear. It can be used in combination with btVector3, btQuaternion and btMatrix3x3 linear algebra classes.
btVector3 m_origin
 Storage for the translation.

Macro Definition Documentation

◆ btTransformData

#define btTransformData   btTransformFloatData

Definition at line 23 of file btTransform.h.

Referenced by deSerialize(), and serialize().

Function Documentation

◆ btTransform() [1/3]

SIMD_FORCE_INLINE btTransform ( const btMatrix3x3 & b,
const btVector3 & c = btVector3(btScalar(0), btScalar(0), btScalar(0)) )
explicit

Constructor from btMatrix3x3 (optional btVector3).

Parameters
bRotation from Matrix
cTranslation from Vector default (0,0,0)

Definition at line 52 of file btTransform.h.

References b, btMatrix3x3, btVector3, m_origin, and SIMD_FORCE_INLINE.

◆ btTransform() [2/3]

SIMD_FORCE_INLINE btTransform ( const btQuaternion & q,
const btVector3 & c = btVector3(btScalar(0), btScalar(0), btScalar(0)) )
explicit

Constructor from btQuaternion (optional btVector3 ).

Parameters
qRotation from quaternion
cTranslation from Vector (default 0,0,0)

Definition at line 42 of file btTransform.h.

References btVector3, m_origin, and SIMD_FORCE_INLINE.

◆ btTransform() [3/3]

SIMD_FORCE_INLINE btTransform ( const btTransform & other)

Copy constructor.

Definition at line 59 of file btTransform.h.

References btTransform, m_origin, and SIMD_FORCE_INLINE.

◆ deSerialize()

void deSerialize ( const struct btTransformData & dataIn)

References btTransformData.

◆ deSerializeDouble()

void deSerializeDouble ( const struct btTransformDoubleData & dataIn)

◆ deSerializeFloat()

void deSerializeFloat ( const struct btTransformFloatData & dataIn)

◆ getBasis()

SIMD_FORCE_INLINE const btMatrix3x3 & getBasis ( )

Return the basis matrix for the rotation.

Definition at line 108 of file btTransform.h.

References btMatrix3x3, and SIMD_FORCE_INLINE.

Referenced by btHingeConstraint().

◆ getIdentity()

const btTransform & getIdentity ( )
static

Return an identity transform.

Definition at line 197 of file btTransform.h.

References btTransform.

◆ getOpenGLMatrix()

void getOpenGLMatrix ( btScalar * m) const

Fill an array representation.

Parameters
mA pointer to a 16 element array (12 rotation(row major padded on the right by 1), and 3 translation

Definition at line 135 of file btTransform.h.

References m_origin.

◆ getOrigin()

◆ getRotation()

btQuaternion getRotation ( ) const

Return a quaternion representing the rotation.

Definition at line 118 of file btTransform.h.

Referenced by operator*(), and setUpVector().

◆ inverse()

btTransform inverse ( ) const

Return the inverse of this transform.

Return the inverse of the matrix.

Definition at line 182 of file btTransform.h.

References btMatrix3x3, btTransform, and m_origin.

◆ inverseTimes()

SIMD_FORCE_INLINE btTransform btTransform::inverseTimes ( const btTransform & t) const

Return the inverse of this transform times the other transform.

Parameters
tThe other transform return this.inverse() * the other

Definition at line 222 of file btTransform.h.

References btTransform, btVector3, m_origin, and v.

◆ invXform()

SIMD_FORCE_INLINE btVector3 btTransform::invXform ( const btVector3 & inVec) const

Definition at line 215 of file btTransform.h.

References btVector3, m_origin, and v.

◆ mult()

SIMD_FORCE_INLINE void mult ( const btTransform & t1,
const btTransform & t2 )

Set the current transform as the value of the product of two transforms.

Parameters
t1Transform 1
t2Transform 2 This = Transform1 * Transform2

Definition at line 76 of file btTransform.h.

References btTransform, m_origin, and SIMD_FORCE_INLINE.

Referenced by blender::io::usd::dome_light_to_world_material(), and mathutils_array_hash().

◆ operator()()

◆ operator*() [1/3]

SIMD_FORCE_INLINE btQuaternion operator* ( const btQuaternion & q) const

Return the transform of the btQuaternion.

Definition at line 102 of file btTransform.h.

References getRotation(), and SIMD_FORCE_INLINE.

◆ operator*() [2/3]

btTransform operator* ( const btTransform & t) const

Return the product of this transform and the other.

References btTransform.

◆ operator*() [3/3]

SIMD_FORCE_INLINE btVector3 operator* ( const btVector3 & x) const

Return the transform of the vector.

Definition at line 96 of file btTransform.h.

References btVector3, SIMD_FORCE_INLINE, and x.

◆ operator*=()

btTransform & operator*= ( const btTransform & t)

Multiply this Transform by another(this = this * another).

Parameters
tThe other transform

Definition at line 174 of file btTransform.h.

References btTransform, and m_origin.

◆ operator=()

SIMD_FORCE_INLINE btTransform & operator= ( const btTransform & other)

Assignment Operator.

Definition at line 65 of file btTransform.h.

References btTransform, m_origin, and SIMD_FORCE_INLINE.

◆ operator==()

SIMD_FORCE_INLINE bool operator== ( const btTransform & t1,
const btTransform & t2 )

Test if two transforms have all elements equal.

Definition at line 237 of file btTransform.h.

References btTransform, and SIMD_FORCE_INLINE.

◆ serialize()

void serialize ( struct btTransformData & dataOut) const

References btTransformData.

◆ serializeFloat()

void serializeFloat ( struct btTransformFloatData & dataOut) const

◆ setBasis()

SIMD_FORCE_INLINE void setBasis ( const btMatrix3x3 & basis)

Set the rotational element by btMatrix3x3.

Definition at line 154 of file btTransform.h.

References btMatrix3x3, and SIMD_FORCE_INLINE.

◆ setFromOpenGLMatrix()

void setFromOpenGLMatrix ( const btScalar * m)

Set from an array.

Parameters
mA pointer to a 16 element array (12 rotation(row major padded on the right by 1), and 3 translation

Definition at line 127 of file btTransform.h.

References m_origin.

◆ setIdentity()

void setIdentity ( )

Set this transformation to the identity.

Definition at line 166 of file btTransform.h.

References m_origin.

◆ setOrigin()

SIMD_FORCE_INLINE void setOrigin ( const btVector3 & origin)

Set the translational element.

Parameters
originThe vector to set the translation to

Definition at line 146 of file btTransform.h.

References btVector3, m_origin, and SIMD_FORCE_INLINE.

◆ setRotation()

SIMD_FORCE_INLINE void setRotation ( const btQuaternion & q)

Set the rotational element by btQuaternion.

Definition at line 160 of file btTransform.h.

References SIMD_FORCE_INLINE.

Variable Documentation

◆ btTransform

btTransform
Initial value:
{
btMatrix3x3 m_basis
btMatrix3x3
The btMatrix3x3 class implements a 3x3 rotation matrix, to perform linear algebra in combination with...
Definition btMatrix3x3.h:50

The btTransform class supports rigid transforms with only translation and rotation and no scaling/shear. It can be used in combination with btVector3, btQuaternion and btMatrix3x3 linear algebra classes.

No initialization constructor.

Definition at line 29 of file btTransform.h.

Referenced by addChildShape(), btGImpactCompoundShape::addChildShape(), btCollisionWorld::addCollisionObject(), btSoftBody::appendDeformableAnchor(), btSoftBody::appendDeformableAnchor(), GIM_TRIANGLE::apply_transform(), btPrimitiveTriangle::applyTransform(), btTriangleShapeEx::applyTransform(), appy_transform(), GIM_AABB::appy_transform(), b2CollidePolygons(), btGImpactBvh::boxQueryTrans(), btGImpactQuantizedBvh::boxQueryTrans(), GIM_BOX_TREE_TEMPLATE_SET< _GIM_PRIMITIVE_MANAGER_PROTOTYPE, _GIM_BOX_TREE_PROTOTYPE >::boxQueryTrans(), BT_DECLARE_ALIGNED_ALLOCATOR(), btAdjustInternalEdgeContacts(), btCollisionObjectWrapper::btCollisionObjectWrapper(), btCollisionObjectWrapper::btCollisionObjectWrapper(), btCompareTransformsEqual(), btComputeGjkEpaPenetration(), btComputeSupport(), btConeTwistConstraint(), btConeTwistConstraint(), btCreateCompoundFromGimpactShape(), btDefaultMotionState(), btGeneric6DofConstraint(), btGeneric6DofConstraint(), btGeneric6DofSpring2Constraint(), btGeneric6DofSpring2Constraint(), btGeneric6DofSpringConstraint(), btGeneric6DofSpringConstraint(), btHinge2Constraint(), btHingeAccumulatedAngleConstraint(), btHingeAccumulatedAngleConstraint(), btHingeConstraint(), btHingeConstraint(), btPerturbedContactResult::btPerturbedContactResult(), btSingleSweepCallback::btSingleSweepCallback(), btSliderConstraint(), btSliderConstraint(), btTransform(), btTransformAabb(), btTransformAabb(), btTriangleConvexcastCallback::btTriangleConvexcastCallback(), btUniversalConstraint(), calc_from_full_invert(), GIM_BOX_BOX_TRANSFORM_CACHE::calc_from_full_invert(), calc_from_homogenic(), GIM_BOX_BOX_TRANSFORM_CACHE::calc_from_homogenic(), calcAngleInfo2(), btConvexPenetrationDepthSolver::calcPenDepth(), btGjkEpaPenetrationDepthSolver::calcPenDepth(), btMinkowskiPenetrationDepthSolver::calcPenDepth(), btContinuousConvexCollision::calcTimeOfImpact(), btConvexCast::calcTimeOfImpact(), btGjkConvexCast::calcTimeOfImpact(), btSubsimplexConvexCast::calcTimeOfImpact(), btTransformUtil::calculateDiffAxisAngle(), calculateJacobi(), calculateLocalInertia(), calculatePrincipalAxisTransform(), calculatePrincipalAxisTransform(), calculateTemporalAabb(), btCompoundCollisionAlgorithm::calculateTimeOfImpact(), btSoftBodyConcaveCollisionAlgorithm::calculateTimeOfImpact(), calculateTransforms(), btTransformUtil::calculateVelocity(), capsuleCapsuleDistance(), btSoftBody::checkContact(), btSoftBody::checkDeformableContact(), btSoftBody::checkDeformableFaceContact(), btPolyhedralContactClipping::clipFaceAgainstHull(), btPolyhedralContactClipping::clipHullAgainstHull(), btGImpactCollisionAlgorithm::collide_sat_triangles(), btConvexPlaneCollisionAlgorithm::collideSingleContact(), btCollisionWorldImporter::convertAllObjects(), btCollisionWorldImporter::convertCollisionShape(), btCollisionWorld::convexSweepTest(), convexSweepTest(), btCollisionWorldImporter::createCollisionObject(), createPredictiveContactsInternal(), btMultiBodyFixedConstraint::debugDraw(), btMultiBodySliderConstraint::debugDraw(), DebugDrawcallback::DebugDrawcallback(), debugDrawConstraint(), btCollisionWorld::debugDrawObject(), btMultiBodyDynamicsWorld::debugDrawWorld(), btSoftBody::defaultCollisionHandler(), btGjkEpaSolver2::Distance(), btSparseSdf< CELLSIZE >::DistanceToShape(), btSoftColliders::CollideSDF_RD::DoNode(), btSoftColliders::CollideSDF_RDF::DoNode(), btSoftColliders::CollideSDF_RS::DoNode(), btIDebugDraw::drawBox(), btIDebugDraw::drawCapsule(), btIDebugDraw::drawCone(), btConvexCast::CastResult::drawCoordSystem(), btIDebugDraw::drawCylinder(), btIDebugDraw::drawPlane(), btIDebugDraw::drawSphere(), btIDebugDraw::drawSphere(), btIDebugDraw::drawTransform(), EdgeSeparation(), btGImpactBvh::find_collision(), btGImpactQuantizedBvh::find_collision(), GIM_TREE_TREE_COLLIDER< BOX_SET_CLASS0, BOX_SET_CLASS1 >::find_collision(), FindIncidentEdge(), FindMaxSeparation(), btPolyhedralContactClipping::findSeparatingAxis(), get_limit_motor_info2(), get_limit_motor_info2(), btPlaneShape::get_plane_equation_transformed(), btGImpactCompoundShape::CompoundPrimitiveManager::get_primitive_box(), GIM_TRIANGLE::get_triangle_transform(), btConvexInternalAabbCachingShape::getAabb(), btGImpactShapeInterface::getAabb(), btPolyhedralConvexAabbCachingShape::getAabb(), btSdfCollisionShape::getAabb(), btSoftBodyCollisionShape::getAabb(), btSoftClusterCollisionShape::getAabb(), btTriangleShapeEx::getAabb(), getAabb(), getAabbNonVirtual(), getAabbSlow(), getAabbSlow(), getAFrame(), getBaseWorldTransform(), getBFrame(), getBoundingSphere(), getCalculatedTransformA(), getCalculatedTransformB(), btRigidBody::getCenterOfMassTransform(), btRaycastVehicle::getChassisWorldTransform(), btGImpactCompoundShape::getChildAabb(), btGImpactMeshShape::getChildAabb(), btGImpactShapeInterface::getChildAabb(), btGImpactCompoundShape::getChildTransform(), btGImpactMeshShape::getChildTransform(), btGImpactMeshShapePart::getChildTransform(), btGImpactShapeInterface::getChildTransform(), getChildTransform(), btBoxBoxDetector::getClosestPoints(), SphereTriangleDetector::getClosestPoints(), btGjkPairDetector::getClosestPointsNonVirtual(), btRaycastVehicle::getForwardVector(), getFrameOffsetA(), getFrameOffsetA(), getFrameOffsetB(), getFrameOffsetB(), getHingeAngle(), getIdentity(), getInfo2(), getInfo2Internal(), getInfo2InternalUsingFrameOffset(), getInfo2NonVirtual(), getInfo2NonVirtual(), getInfo2NonVirtual(), getInfo2NonVirtual(), getInfo2NonVirtual(), getInterpolationWorldTransform(), btConvexInternalAabbCachingShape::getNonvirtualAabb(), btPolyhedralConvexAabbCachingShape::getNonvirtualAabb(), btSoftBody::getRigidTransform(), btSphereBoxCollisionAlgorithm::getSphereDistance(), getTransformA(), GetTransformB(), btRaycastVehicle::getWheelTransformWS(), btCollisionObjectWrapper::getWorldTransform(), btMotionState::getWorldTransform(), getWorldTransform(), getWorldTransform(), getWorldTransform(), gim_inertia_add_transformed(), btGImpactCollisionAlgorithm::gimpact_vs_compoundshape(), btGImpactCollisionAlgorithm::gimpact_vs_concave(), btGImpactCollisionAlgorithm::gimpact_vs_gimpact(), btGImpactCollisionAlgorithm::gimpact_vs_gimpact_find_pairs(), btGImpactCollisionAlgorithm::gimpact_vs_shape(), btGImpactCollisionAlgorithm::gimpact_vs_shape_find_pairs(), btGImpactCollisionAlgorithm::gimpacttrimeshpart_vs_plane_collision(), gjkepa2_impl::Initialize(), btConvexSeparatingDistanceUtil::initSeparatingDistance(), btTransformUtil::integrateTransform(), btDeformableMultiBodyDynamicsWorld::integrateTransforms(), btSimpleDynamicsWorld::integrateTransforms(), integrateTransformsInternal(), MyInternalTriangleIndexCallback::internalProcessTriangleIndex(), inverse(), inverseTimes(), make_constraint_transforms(), mult(), MycollideTT(), MyIntersect(), btCollisionWorld::objectQuerySingle(), btCollisionWorld::objectQuerySingleInternal(), operator*(), operator*=(), operator=(), operator==(), GIM_AABB::overlapping_trans_conservative(), overlapping_trans_conservative(), btGjkEpaSolver2::Penetration(), btDeformableMultiBodyDynamicsWorld::positionCorrection(), btRigidBody::predictIntegratedTransform(), btRigidBody::proceedToTransform(), btCompoundCompoundLeafCallback::Process(), btCompoundLeafCallback::Process(), btCompoundLeafCallback::ProcessChildShape(), btCompoundCollisionAlgorithm::processCollision(), btCompoundCompoundCollisionAlgorithm::processCollision(), btConvexConvexAlgorithm::processCollision(), btConvexPlaneCollisionAlgorithm::processCollision(), btSoftBodyTriangleCallback::processTriangle(), project(), btSoftBody::PSolve_Anchors(), btCollisionWorld::rayTestSingle(), btDeformableMultiBodyDynamicsWorld::rayTestSingle(), btSoftMultiBodyDynamicsWorld::rayTestSingle(), btSoftRigidDynamicsWorld::rayTestSingle(), btCollisionWorld::rayTestSingleInternal(), RB_body_get_transform_matrix(), RB_body_new(), RB_body_set_loc_rot(), RB_body_set_mass(), RB_compound_add_child_shape(), RB_constraint_new_6dof(), RB_constraint_new_6dof_spring(), RB_constraint_new_6dof_spring2(), RB_constraint_new_fixed(), RB_constraint_new_hinge(), RB_constraint_new_motor(), RB_constraint_new_piston(), RB_constraint_new_slider(), RB_world_convex_sweep_test(), recalcLocalAabb(), recoverFromPenetration(), btCollisionWorld::refreshBroadphaseProxy(), refreshContactPoints(), btSoftBody::rotate(), setAngularLimits(), setAxis(), setBaseWorldTransform(), btRigidBody::setCenterOfMassTransform(), btGImpactCompoundShape::setChildTransform(), btGImpactMeshShape::setChildTransform(), btGImpactMeshShapePart::setChildTransform(), btGImpactShapeInterface::setChildTransform(), setFrames(), setInterpolationWorldTransform(), setLinearLimits(), setParam(), btSoftBodyTriangleCallback::setTimeStepAndCounters(), setTransformA(), setTransformB(), setUpVector(), btMotionState::setWorldTransform(), setWorldTransform(), setWorldTransform(), setWorldTransform(), btGjkEpaSolver2::SignedDistance(), btGjkEpaSolver2::SignedDistance(), solveConstraintObsolete(), stepDown(), stepForwardAndStrafe(), stepUp(), SupportVertexCallback::SupportVertexCallback(), synchronizeSingleMotionState(), testAngularLimitMotor(), testLimit(), TestSepAxis(), btSoftBody::transform(), btSoftBody::transformTo(), btSoftBody::translate(), btCollisionWorld::updateAabbs(), btSimpleDynamicsWorld::updateAabbs(), updateChildTransform(), updateCollisionObjectInterpolationWorldTransforms(), updateCollisionObjectWorldTransforms(), btRaycastVehicle::updateFriction(), updateRHS(), btConvexSeparatingDistanceUtil::updateSeparatingDistance(), btRaycastVehicle::updateVehicle(), btRaycastVehicle::updateWheelTransformsWS(), writebackVelocityAndTransform(), and btSoftBody::Body::xform().

◆ m_origin