|
| StateMsg () |
| Default constructor giving an empty state. Beware that the state is not initialized and that passing this state to a procedure will typically cause a program crash.
|
|
void | copy (const State &src) |
| copies data from a state into this state. The version of the state is allowed to be different from this state. Only state data that is valid for both states will be copied. More...
|
|
void | clone (const State &src) |
| performs a deep copy of src into this state. More...
|
|
void | upgrade () |
| this function upgrades the current version of this State to the newest state. It will not override data values that is set in the current state.
|
|
void | upgradeTo (const State &state) |
| this function upgrades the current version of this State with the given state. It will not override data values that is set in the current state.
|
|
size_t | size () const |
| The dimension of the state vector. More...
|
|
double & | operator() (size_t index) |
| Provides direct access to the configurations stored in the state. More...
|
|
const double & | operator() (size_t index) const |
| Provides direct read access to the configurations stored in the state. More...
|
|
double & | operator[] (size_t index) |
| Same as operator().
|
|
const double & | operator[] (size_t index) const |
| Same as operator().
|
|
Frame * | getFrame (int id) |
| gets the frame with id id. If a frame with id id does not exist NULL is returned
|
|
int | getUniqueId () const |
| get the state id. Represents the static structure of the StateStructure that this state relates to.
|
|
rw::core::Ptr< StateStructure > | getStateStructure () const |
| Returns pointer to the state structure (the structure of Frame's and StateData) More...
|
|
| State () |
| Default constructor giving an empty state. Beware that the state is not initialized and that passing this state to a procedure will typically cause a program crash.
|
|
virtual | ~State () |
| destructor
|
|
void | setQStateInState (State &to) const |
| Assign to a state the configuration state of this state. More...
|
|
void | setTreeStateInState (State &to) const |
| Assign to a state the tree state of this state. More...
|
|
State | operator- () const |
| Unary minus operator. More...
|
|
void | copy (const State &src) |
| copies data from a state into this state. The version of the state is allowed to be different from this state. Only state data that is valid for both states will be copied. More...
|
|
State | clone () |
| performs a deep copy of this state and returns the clone. Both QState and TreeState are (deep) copied as normal however the cachestates will be copied using their clone method. More...
|
|
void | clone (const State &src) |
| performs a deep copy of src into this state. More...
|
|
void | upgrade () |
| this function upgrades the current version of this State to the newest state. It will not override data values that is set in the current state.
|
|
void | upgradeTo (const State &state) |
| this function upgrades the current version of this State with the given state. It will not override data values that is set in the current state.
|
|
size_t | size () const |
| The dimension of the configuration state vector. More...
|
|
double & | operator() (size_t index) |
| Provides direct access to the configurations stored in the state. More...
|
|
const double & | operator() (size_t index) const |
| Provides direct read access to the configurations stored in the state. More...
|
|
double & | operator[] (size_t index) |
| Same as operator().
|
|
const double & | operator[] (size_t index) const |
| Same as operator().
|
|
Frame * | getFrame (int id) |
| gets the frame with id id. If a frame with id id does not exist NULL is returned
|
|
int | getUniqueId () const |
| get the state id. Represents the static structure of the StateStructure that this state relates to.
|
|
rw::core::Ptr< StateStructure > | getStateStructure () const |
| Returns pointer to the state structure (the structure of Frame's and StateData) More...
|
|
void | read (class rw::common::InputArchive &iarchive, const std::string &id) |
|
void | write (class rw::common::OutputArchive &oarchive, const std::string &id) const |
|
virtual | ~Serializable () |
| destructor
|
|
The state of a work cell (or kinematics tree).
You need a work cell state in order to calculate forward kinematics for trees of frames.
Work cell states can be copied and assigned freely.
The work cell state consists of a part for the tree structure and a part for the configuration values. You are encouraged to use the getParent(), getChildren(), getQ() and setQ() utility functions rather than explicitly type, say, state.getQState().getQ(). That way you will have a much easier time of updating the code if we decide to change the way the kinematics data structures are stored (!). Also getQ(state, frame) is shorter to type also.
The operation of a work cell state is undefined valid if the tree used for its initialization is modified. (The implementation takes some care to check for this and crashes the program in a controlled way if it takes place.)
The type of node of forward kinematic trees.
Types of joints are implemented as subclasses of Frame. The responsibility of a joint is to implement the getTransform() method that returns the transform of the frame relative to whatever parent it is attached to.
The getTransform() method takes as parameter the set of joint values State for the tree. Joint values for a particular frame can be accessed via State::getQ(). A frame may contain pointers to other frames so that the transform of a frame may depend on the joint values for other frames also.