/usr/include/choreonoid-1.1/cnoid/src/Body/BodyMotionPoseProvider.h is in libcnoid-dev 1.1.0+dfsg-6.1+b4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | /**
@file
@author Shin'ichiro Nakaoka
*/
#ifndef CNOID_BODY_BODY_MOTION_POSE_PROVIDER_H_INCLUDED
#define CNOID_BODY_BODY_MOTION_POSE_PROVIDER_H_INCLUDED
#include "Body.h"
#include "Link.h"
#include "PoseProvider.h"
#include "BodyMotion.h"
#include "exportdecl.h"
namespace cnoid {
class CNOID_EXPORT BodyMotionPoseProvider : public PoseProvider
{
public:
BodyMotionPoseProvider();
BodyMotionPoseProvider(BodyPtr body, BodyMotionPtr motion);
void initialize(BodyPtr body, BodyMotionPtr motion);
bool updateMotion();
virtual Body* body() const;
virtual double beginningTime() const;
virtual double endingTime() const;
virtual bool seek(double time);
virtual bool seek(double time, int waistLinkIndex, const Vector3& waistTranslation);
virtual int baseLinkIndex() const;
virtual bool getBaseLinkPosition(Vector3& out_p, Matrix3& out_R) const;
virtual void getJointPositions(std::vector< boost::optional<double> >& out_q) const;
virtual boost::optional<Vector3> zmp() const;
private:
BodyPtr body_;
BodyMotionPtr motion;
int minNumJoints;
std::vector<Link*> footLinks;
std::vector<JointPathPtr> ikPaths;
MultiAffine3SeqPtr footLinkPositions;
std::vector<double> qTranslated;
Vector3 p_waist;
Matrix3 R_waist;
Vector3 zmp_;
bool seek(double time, int waistLinkIndex, const Vector3& waistTranslation, bool applyWaistTranslation);
};
}
#endif
|