24 constexpr
Pose(
const float x = 0,
const float y = 0,
const float th = 0)
29 const float cos_angle = std::cos(angle);
30 const float sin_angle = std::sin(angle);
31 return {
x * cos_angle -
y * sin_angle,
x * sin_angle +
y * cos_angle,
th};
34 return offset + this->
rotate(offset.
th);
37 return x += o.
x,
y += o.
y,
th += o.
th, *
this;
40 return x -= o.
x,
y -= o.
y,
th -= o.
th, *
this;
45 return os <<
"(" << o.
x <<
", " << o.
y <<
", " << o.
th <<
")";
制御関係の名前空間
Definition: accel_curve.h:54
位置姿勢の座標
Definition: pose.h:18
Pose homogeneous(const Pose &offset) const
Definition: pose.h:33
void clear()
Definition: pose.h:26
float y
y 成分 [m]
Definition: pose.h:20
Pose mirror_x() const
Definition: pose.h:27
Pose rotate(const float angle) const
Definition: pose.h:28
constexpr Pose(const float x=0, const float y=0, const float th=0)
Definition: pose.h:24
Pose & operator+=(const Pose &o)
Definition: pose.h:36
friend std::ostream & operator<<(std::ostream &os, const Pose &o)
Definition: pose.h:44
float x
x 成分 [m]
Definition: pose.h:19
Pose operator-(const Pose &o) const
Definition: pose.h:43
Pose & operator-=(const Pose &o)
Definition: pose.h:39
Pose operator+(const Pose &o) const
Definition: pose.h:42
float th
theta 成分 [rad]
Definition: pose.h:21