Fawkes API  Fawkes Development Version
mirrormodel.h
1 
2 /***************************************************************************
3  * mirrormodel.h - Abstract class defining a mirror model
4  *
5  * Created: Tue Jul 19 11:55:29 2005
6  * Copyright 2005-2007 Tim Niemueller [www.niemueller.de]
7  *
8  ****************************************************************************/
9 
10 /* This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version. A runtime exception applies to
14  * this software (see LICENSE.GPL_WRE file mentioned below for details).
15  *
16  * This program is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  * GNU Library General Public License for more details.
20  *
21  * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
22  */
23 
24 #ifndef _FIREVISION_MODELS_MIRRORMODEL_H_
25 #define _FIREVISION_MODELS_MIRRORMODEL_H_
26 
27 #include <utils/math/types.h>
28 
29 namespace firevision {
30 
32 {
33 public:
34  virtual ~MirrorModel();
35 
36  virtual void warp2unwarp(unsigned int warp_x,
37  unsigned int warp_y,
38  unsigned int *unwarp_x,
39  unsigned int *unwarp_y) = 0;
40 
41  virtual void unwarp2warp(unsigned int unwarp_x,
42  unsigned int unwarp_y,
43  unsigned int *warp_x,
44  unsigned int *warp_y) = 0;
45 
46  virtual const char *getName() = 0;
47 
48  virtual fawkes::polar_coord_2d_t getWorldPointRelative(unsigned int image_x,
49  unsigned int image_y) const = 0;
50 
51  virtual fawkes::cart_coord_2d_t getWorldPointGlobal(unsigned int image_x,
52  unsigned int image_y,
53  float pose_x,
54  float pose_y,
55  float pose_ori) const = 0;
56 
57  virtual void reset() = 0;
58 
59  virtual fawkes::upoint_t getCenter() const = 0;
60  virtual void setCenter(unsigned int image_x, unsigned int image_y) = 0;
61  virtual void setOrientation(float angle) = 0;
62  virtual float getOrientation() const = 0;
63 
64  virtual bool isValidPoint(unsigned int image_x, unsigned int image_y) const = 0;
65 };
66 
67 } // end namespace firevision
68 
69 #endif
firevision::MirrorModel::unwarp2warp
virtual void unwarp2warp(unsigned int unwarp_x, unsigned int unwarp_y, unsigned int *warp_x, unsigned int *warp_y)=0
Transform unwarped to warped point.
firevision::MirrorModel::~MirrorModel
virtual ~MirrorModel()
Virtual empty destructor.
Definition: mirrormodel.cpp:101
fawkes::polar_coord_2d_t
Polar coordinates.
Definition: types.h:96
fawkes::upoint_t
Point with cartesian coordinates as unsigned integers.
Definition: types.h:35
firevision::MirrorModel::getOrientation
virtual float getOrientation() const =0
Get orientation of the omni-camera.
firevision::MirrorModel::warp2unwarp
virtual void warp2unwarp(unsigned int warp_x, unsigned int warp_y, unsigned int *unwarp_x, unsigned int *unwarp_y)=0
Transform warped to unwarped point.
firevision::MirrorModel
Mirror model interface.
Definition: mirrormodel.h:32
firevision::MirrorModel::getName
virtual const char * getName()=0
Get name of model.
firevision::MirrorModel::setCenter
virtual void setCenter(unsigned int image_x, unsigned int image_y)=0
Set center of omni-camera to given image pixel.
firevision::MirrorModel::getWorldPointRelative
virtual fawkes::polar_coord_2d_t getWorldPointRelative(unsigned int image_x, unsigned int image_y) const =0
Get relative coordinate based on image coordinates.
firevision::MirrorModel::setOrientation
virtual void setOrientation(float angle)=0
Set orientation of the omni-camera device.
firevision::MirrorModel::reset
virtual void reset()=0
Reset model.
fawkes::cart_coord_2d_struct
Cartesian coordinates (2D).
Definition: types.h:65
firevision::MirrorModel::getCenter
virtual fawkes::upoint_t getCenter() const =0
Get the image pixel that is the center of the omni-camera.
firevision::MirrorModel::isValidPoint
virtual bool isValidPoint(unsigned int image_x, unsigned int image_y) const =0
Check if the given point is valid.
firevision::MirrorModel::getWorldPointGlobal
virtual fawkes::cart_coord_2d_t getWorldPointGlobal(unsigned int image_x, unsigned int image_y, float pose_x, float pose_y, float pose_ori) const =0
Get global coordinate based on image coordinates.