|
Fawkes API
Fawkes Development Version
|
A 2-dimensional pose, i.e. More...
#include <>>

Public Member Functions | |
| HomPose2d (const HomPoint &pos, const HomVector &orientation) | |
| Constructor. | |
| HomPose2d (float x=0.0, float y=0.0, float yaw=0.0) | |
| Constructor. | |
| HomPose2d (const HomPose2d &p) | |
| Copy constructor. | |
| ~HomPose2d () | |
| Destructor. | |
| const HomPose2d & | operator= (const HomPose2d &p) |
| Assignment operator. | |
| float | x () const |
| Get the x-coordinate of the position. | |
| void | x (float x) |
| Set the x-coordinate of the position. | |
| float | y () const |
| Get the y-coordinate of the position. | |
| void | y (float y) |
| Set the y-coordinate of the position. | |
| float | yaw () const |
| Get the angle of the current orientation [0...2pi]. | |
| void | yaw (float yaw) |
| Set the angle of the orientation. | |
| const HomPoint & | position () const |
| Get the position. | |
| const HomVector & | orientation () const |
| Get the orientation vector. | |
| void | set_position (const HomPoint &p) |
| Set the positional part of the pose. | |
Public Member Functions inherited from fawkes::Transformable | |
| Transformable () | |
| Constructor. | |
| virtual | ~Transformable () |
| Destructor. | |
Protected Member Functions | |
| void | register_primitives () |
| Here, a derived class should register its primitives (HomPoints and HomVectors) by calling add_primitive for each of those. | |
| void | post_transform () |
| This method is called after the primitives are transformed. | |
Protected Member Functions inherited from fawkes::Transformable | |
| void | transform (const HomTransform &t) |
| Apply the transform to all registered primitives and call the post_transform() method. | |
| void | add_primitive (HomCoord *c) |
| Add a primitive to the list of primitives that is transformed. | |
| void | clear_primitives () |
| Clear the list of primitives. | |
A 2-dimensional pose, i.e.
a combination of position and orientation.
Definition at line 33 of file hom_pose_2d.h.
Constructor.
| position | the posititon |
| orientation | the orientation |
Definition at line 41 of file hom_pose_2d.cpp.
References register_primitives(), fawkes::HomVector::unit(), fawkes::HomCoord::x(), and fawkes::HomCoord::y().
| fawkes::HomPose2d::HomPose2d | ( | float | x = 0.0, |
| float | y = 0.0, |
||
| float | yaw = 0.0 |
||
| ) |
Constructor.
| x | the x-coordinate of the position |
| y | the y-coordinate of the position |
| yaw | the angle of the orientation wrt. the current frame |
Definition at line 57 of file hom_pose_2d.cpp.
References register_primitives(), fawkes::HomCoord::rotate_z(), and yaw().
| fawkes::HomPose2d::HomPose2d | ( | const HomPose2d & | p | ) |
Copy constructor.
| p | the other pose |
Definition at line 71 of file hom_pose_2d.cpp.
References register_primitives().
| fawkes::HomPose2d::~HomPose2d | ( | ) |
Destructor.
Definition at line 82 of file hom_pose_2d.cpp.
Assignment operator.
| p | the rhs pose |
Definition at line 93 of file hom_pose_2d.cpp.
| const HomVector & fawkes::HomPose2d::orientation | ( | ) | const |
Get the orientation vector.
Definition at line 189 of file hom_pose_2d.cpp.
| const HomPoint & fawkes::HomPose2d::position | ( | ) | const |
|
protectedvirtual |
This method is called after the primitives are transformed.
Any additional updates that need to be done should be done here.
Implements fawkes::Transformable.
Definition at line 202 of file hom_pose_2d.cpp.
References fawkes::HomCoord::x(), and fawkes::HomCoord::y().
|
protectedvirtual |
Here, a derived class should register its primitives (HomPoints and HomVectors) by calling add_primitive for each of those.
Implements fawkes::Transformable.
Definition at line 195 of file hom_pose_2d.cpp.
References fawkes::Transformable::add_primitive().
Referenced by HomPose2d().
| void fawkes::HomPose2d::set_position | ( | const HomPoint & | p | ) |
Set the positional part of the pose.
| p | the new position |
Definition at line 180 of file hom_pose_2d.cpp.
| float fawkes::HomPose2d::x | ( | ) | const |
Get the x-coordinate of the position.
Definition at line 107 of file hom_pose_2d.cpp.
References fawkes::HomCoord::x().
Referenced by fawkes::WorldInfoDataContainer::get_ball_pos_global(), and FieldView::on_draw().
| void fawkes::HomPose2d::x | ( | float | x | ) |
Set the x-coordinate of the position.
| x | the new x-coordinate of the position. |
Definition at line 116 of file hom_pose_2d.cpp.
References fawkes::HomCoord::x().
| float fawkes::HomPose2d::y | ( | ) | const |
Get the y-coordinate of the position.
Definition at line 125 of file hom_pose_2d.cpp.
References fawkes::HomCoord::y().
Referenced by fawkes::WorldInfoDataContainer::get_ball_pos_global(), and FieldView::on_draw().
| void fawkes::HomPose2d::y | ( | float | y | ) |
Set the y-coordinate of the position.
| y | the new x-coordinate of the position. |
Definition at line 134 of file hom_pose_2d.cpp.
References fawkes::HomCoord::y().
| float fawkes::HomPose2d::yaw | ( | ) | const |
Get the angle of the current orientation [0...2pi].
Definition at line 143 of file hom_pose_2d.cpp.
Referenced by fawkes::WorldInfoDataContainer::get_ball_pos_global(), HomPose2d(), FieldView::on_draw(), and yaw().
| void fawkes::HomPose2d::yaw | ( | float | yaw | ) |
Set the angle of the orientation.
| yaw | the new angle of the orientation |
Definition at line 152 of file hom_pose_2d.cpp.
References fawkes::HomCoord::rotate_z(), and yaw().