Fawkes API Fawkes Development Version

hom_pose_2d.h

00001 
00002 /***************************************************************************
00003  *  hom_pose_2d.h - 2-dimensional Homogenous Pose
00004  *
00005  *  Created: Fri Oct 10 11:06:45 2008
00006  *  Copyright  2008  Daniel Beck
00007  *
00008  ****************************************************************************/
00009 
00010 /*  This program is free software; you can redistribute it and/or modify
00011  *  it under the terms of the GNU General Public License as published by
00012  *  the Free Software Foundation; either version 2 of the License, or
00013  *  (at your option) any later version. A runtime exception applies to
00014  *  this software (see LICENSE.GPL_WRE file mentioned below for details).
00015  *
00016  *  This program is distributed in the hope that it will be useful,
00017  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019  *  GNU Library General Public License for more details.
00020  *
00021  *  Read the full text in the LICENSE.GPL_WRE file in the doc directory.
00022  */
00023 
00024 #ifndef __GEOMETRY_HOM_POSE_2D_H_
00025 #define __GEOMETRY_HOM_POSE_2D_H_
00026 
00027 #include <geometry/transformable.h>
00028 
00029 namespace fawkes {
00030 class HomPoint;
00031 class HomVector;
00032 
00033 class HomPose2d : public Transformable
00034 {
00035  public:
00036   HomPose2d(const HomPoint& pos, const HomVector& orientation);
00037   HomPose2d(float x = 0.0, float y = 0.0, float yaw = 0.0);
00038   HomPose2d(const HomPose2d& p);
00039   ~HomPose2d();
00040 
00041   const HomPose2d& operator=(const HomPose2d& p);
00042 
00043   float x() const;
00044   void  x(float x);
00045 
00046   float y() const;
00047   void  y(float y);
00048 
00049   float yaw() const;
00050   void  yaw(float yaw);
00051 
00052   const HomPoint&  position() const;
00053   const HomVector& orientation() const;
00054 
00055   void set_position(const HomPoint& p);
00056 
00057  protected:
00058   void register_primitives();
00059   void post_transform();
00060 
00061  private:
00062   HomPoint*  m_position;
00063   HomVector* m_orientation;
00064 
00065   float m_yaw;
00066 };
00067 
00068 } // end namespace fawkes
00069 
00070 #endif /*  __GEOMETRY_HOM_POSE_2D_H_ */
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends