Back to index

supertuxkart  0.5+dfsg1
Public Member Functions | Public Attributes
btDefaultMotionState Struct Reference

btDefaultMotionState provides a common implementation to synchronize world transforms with offsets More...

#include <btDefaultMotionState.h>

Inheritance diagram for btDefaultMotionState:
Inheritance graph
[legend]
Collaboration diagram for btDefaultMotionState:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 btDefaultMotionState (const btTransform &startTrans=btTransform::getIdentity(), const btTransform &centerOfMassOffset=btTransform::getIdentity())
virtual void getWorldTransform (btTransform &centerOfMassWorldTrans) const
 synchronizes world transform from user to physics
virtual void setWorldTransform (const btTransform &centerOfMassWorldTrans)
 synchronizes world transform from physics to user Bullet only calls the update of worldtransform for active objects

Public Attributes

btTransform m_graphicsWorldTrans
btTransform m_centerOfMassOffset
btTransform m_startWorldTrans
void * m_userPointer

Detailed Description

btDefaultMotionState provides a common implementation to synchronize world transforms with offsets

Definition at line 5 of file btDefaultMotionState.h.


Constructor & Destructor Documentation

btDefaultMotionState::btDefaultMotionState ( const btTransform startTrans = btTransform::getIdentity(),
const btTransform centerOfMassOffset = btTransform::getIdentity() 
) [inline]

Definition at line 12 of file btDefaultMotionState.h.

              : m_graphicsWorldTrans(startTrans),
              m_centerOfMassOffset(centerOfMassOffset),
              m_startWorldTrans(startTrans),
              m_userPointer(0)

       {
       }

Member Function Documentation

virtual void btDefaultMotionState::getWorldTransform ( btTransform centerOfMassWorldTrans) const [inline, virtual]

synchronizes world transform from user to physics

Implements btMotionState.

Definition at line 22 of file btDefaultMotionState.h.

       {
                     centerOfMassWorldTrans =    m_centerOfMassOffset.inverse() * m_graphicsWorldTrans ;
       }

Here is the call graph for this function:

Here is the caller graph for this function:

virtual void btDefaultMotionState::setWorldTransform ( const btTransform centerOfMassWorldTrans) [inline, virtual]

synchronizes world transform from physics to user Bullet only calls the update of worldtransform for active objects

Implements btMotionState.

Definition at line 29 of file btDefaultMotionState.h.

       {
                     m_graphicsWorldTrans = centerOfMassWorldTrans * m_centerOfMassOffset ;
       }

Here is the caller graph for this function:


Member Data Documentation

Definition at line 8 of file btDefaultMotionState.h.

Definition at line 7 of file btDefaultMotionState.h.

Definition at line 9 of file btDefaultMotionState.h.

Definition at line 10 of file btDefaultMotionState.h.


The documentation for this struct was generated from the following file: