39 #ifndef DART_SIMULATION_RECORDING_HPP_
40 #define DART_SIMULATION_RECORDING_HPP_
44 #include <Eigen/Dense>
54 namespace simulation {
61 explicit Recording(
const std::vector<dynamics::SkeletonPtr>& _skeletons);
64 explicit Recording(
const std::vector<int>& _skelDofs);
84 Eigen::VectorXd
getConfig(
int _frameIdx,
int _skelIdx)
const;
88 double getGenCoord(
int _frameIdx,
int _skelIdx,
int _dofIdx)
const;
102 void addState(
const Eigen::VectorXd& _state);
class Recording
Definition: Recording.hpp:58
Eigen::Vector3d getContactForce(int _frameIdx, int _contactIdx) const
Get contact force whose index is _contactIdx at frame number _frameIdx.
Definition: Recording.cpp:122
void addState(const Eigen::VectorXd &_state)
Add state.
Definition: Recording.cpp:137
std::vector< int > mNumGenCoordsForSkeletons
Number of generalized coordinates for skeletons.
Definition: Recording.hpp:112
double getGenCoord(int _frameIdx, int _skelIdx, int _dofIdx) const
Get _dofIdx-th single configruation of a skeleton whose index is _skelIdx at frame number _frameIdx.
Definition: Recording.cpp:104
int getNumContacts(int _frameIdx) const
Get number of contacts at frame number _frameIdx.
Definition: Recording.cpp:86
Recording(const std::vector< dynamics::SkeletonPtr > &_skeletons)
Create Recording with a list of skeletons.
Definition: Recording.cpp:49
int getNumDofs(int _skelIdx) const
Get number of generalized coordinates of skeleton whoes index is _skelIdx.
Definition: Recording.cpp:80
int getNumSkeletons() const
Get number of skeletons.
Definition: Recording.cpp:74
std::vector< Eigen::VectorXd > mBakedStates
Baked states.
Definition: Recording.hpp:109
int getNumFrames() const
Get number of frames.
Definition: Recording.cpp:68
void clear()
Clear the saved histories.
Definition: Recording.cpp:131
virtual ~Recording()
Destructor.
Definition: Recording.cpp:63
Eigen::VectorXd getConfig(int _frameIdx, int _skelIdx) const
Get skeleton configurations whose index is _skelIdx at frame number _frameIdx.
Definition: Recording.cpp:95
void updateNumGenCoords(const std::vector< dynamics::SkeletonPtr > &_skeletons)
Update list for number of generalized coordinates.
Definition: Recording.cpp:143
Eigen::Vector3d getContactPoint(int _frameIdx, int _contactIdx) const
Get contact point whose index is _contactIdx at frame number _frameIdx.
Definition: Recording.cpp:113
Definition: BulletCollisionDetector.cpp:65