| Hosted by: |
OpenMBV C++ Interface |
BerliOS Project Page |
Abstract base class for all rigid bodies. More...
#include <rigidbody.h>
Public Member Functions | |
| RigidBody () | |
| Default constructor. | |
| void | setLocalFrame (bool f) |
| Draw local frame of this object in the viewer if true (the default) | |
| bool | getLocalFrame () |
| void | setReferenceFrame (bool f) |
| Draw reference frame of this object in the viewer if true (the default) | |
| bool | getReferenceFrame () |
| void | setPath (bool p) |
| Draw path of this object in the viewer if true (the default) | |
| bool | getPath () |
| void | setDragger (bool p) |
| Draw dragger of this object in the viewer if true (default: false) | |
| bool | getDragger () |
| void | setInitialTranslation (const VectorParameter &initTrans) |
| Set initial translaton between the local frame of the body and the reference frame. | |
| void | setInitialTranslation (const std::vector< double > &initTrans) |
| Set initial translaton between the local frame of the body and the reference frame. | |
| std::vector< double > | getInitialTranslation () |
| void | setInitialTranslation (double x, double y, double z) |
| Set initial translaton between the local frame of the body and the reference frame. | |
| void | setInitialRotation (const VectorParameter &initRot) |
| Set initial rotation between the local frame of the body and the reference frame. | |
| void | setInitialRotation (const std::vector< double > &initRot) |
| Set initial rotation between the local frame of the body and the reference frame. | |
| std::vector< double > | getInitialRotation () |
| void | setInitialRotation (double a, double b, double g) |
| Set initial rotation between the local frame of the body and the reference frame. | |
| void | setScaleFactor (const ScalarParameter scale) |
| Set the scale factor of the body. | |
| double | getScaleFactor () |
| void | append (const std::vector< double > &row) |
| Append a data vector the the h5 datsset. | |
| int | getRows () |
| Get the number of rows of the default data. | |
| std::vector< double > | getRow (int i) |
| Get row number i of the default data. | |
| virtual void | initializeUsingXML (MBXMLUtils::TiXmlElement *element) |
| Initializes the time invariant part of the object using a XML node. | |
| MBXMLUtils::TiXmlElement * | writeXMLFile (MBXMLUtils::TiXmlNode *parent) |
| virtual std::string | getFullName (bool includingFileName=false, bool stopAtSeparateFile=false) |
| Returns the full name (path) of the object. | |
| Group * | getSeparateGroup () |
| return the first Group in the tree which is an separateFile | |
| Group * | getTopLevelGroup () |
| return the top level Group | |
| virtual void | destroy () const |
| It must be possible to delete the top level Group: use this function for therefore. | |
Protected Member Functions | |
| void | createHDF5File () |
| void | openHDF5File () |
Protected Attributes | |
| std::string | localFrameStr |
| std::string | referenceFrameStr |
| std::string | pathStr |
| std::string | draggerStr |
| VectorParameter | initialTranslation |
| VectorParameter | initialRotation |
| ScalarParameter | scaleFactor |
| H5::VectorSerie< double > * | data |
| CompoundRigidBody * | compound |
Friends | |
| class | CompoundRigidBody |
Abstract base class for all rigid bodies.
Each rigid body has a body fixed local coordinate system L and a reference coordinate system R which has a fixed relative position and rotation with respect to L (see figure). And there is a inertial fixed world coordinate system W.
The fixed translation from system R to system L is given by the vector initialTranslation
which coordinates are given in system R.
The fixed rotation between the systems R and L is given by the vector initialRotation
which are the kardan angles of the transformation matrix
from system L to system R.
The time dependend translation between the systems W and R is given in the HDF5 dataset by the vector
which coordinates are given in system W.
The time dependend rotation between the systems W and R is given in the HDF5 dataset by the vector
which are the kardan angles of the transformation matrix
from system R to system W.
HDF5-Dataset: The HDF5 dataset of this object is a 2D array of double precision values. Each row represents one dataset in time. A row consists of the following columns in order: time,
,
,
,
,
,
, color
| virtual void OpenMBV::RigidBody::destroy | ( | ) | const [virtual] |
It must be possible to delete the top level Group: use this function for therefore.
If this object is was added into a parent object this object is first removed from this parent and then deleted.
Reimplemented from OpenMBV::Object.
| std::vector<double> OpenMBV::RigidBody::getRow | ( | int | i | ) | [inline, virtual] |
| int OpenMBV::RigidBody::getRows | ( | ) | [inline, virtual] |
Get the number of rows of the default data.
Returns -1, if no default data is avaliable. NOTE: see also append()
Implements OpenMBV::Body.
| void OpenMBV::RigidBody::setInitialRotation | ( | const VectorParameter & | initRot | ) | [inline] |
Set initial rotation between the local frame of the body and the reference frame.
Use cardan angles to represent the transformation matrix
| void OpenMBV::RigidBody::setInitialRotation | ( | const std::vector< double > & | initRot | ) | [inline] |
Set initial rotation between the local frame of the body and the reference frame.
Use cardan angles to represent the transformation matrix
| void OpenMBV::RigidBody::setInitialRotation | ( | double | a, |
| double | b, | ||
| double | g | ||
| ) | [inline] |
Set initial rotation between the local frame of the body and the reference frame.
Use cardan angles to represent the transformation matrix
1.8.0