Fawkes API
Fawkes Development Version
|
Mirror model interface. More...
#include <>>
Public Member Functions | |
virtual | ~MirrorModel () |
Virtual empty destructor. | |
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. | |
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. | |
virtual const char * | getName ()=0 |
Get name of model. | |
virtual fawkes::polar_coord_2d_t | getWorldPointRelative (unsigned int image_x, unsigned int image_y) const =0 |
Get relative coordinate based on image coordinates. | |
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. | |
virtual void | reset ()=0 |
Reset model. | |
virtual fawkes::point_t | getCenter () const =0 |
Get the image pixel that is the center of the omni-camera. | |
virtual void | setCenter (unsigned int image_x, unsigned int image_y)=0 |
Set center of omni-camera to given image pixel. | |
virtual void | setOrientation (float angle)=0 |
Set orientation of the omni-camera device. | |
virtual float | getOrientation () const =0 |
Get orientation of the omni-camera. | |
virtual bool | isValidPoint (unsigned int image_x, unsigned int image_y) const =0 |
Check if the given point is valid. |
Mirror model interface.
This interface defines the API for a mirror model.
firevision::MirrorModel::~MirrorModel | ( | ) | [virtual] |
Virtual empty destructor.
Definition at line 104 of file mirrormodel.cpp.
cart_coord_t firevision::MirrorModel::getCenter | ( | ) | const [pure virtual] |
Get the image pixel that is the center of the omni-camera.
Implemented in firevision::Bulb.
const char * firevision::MirrorModel::getName | ( | ) | [pure virtual] |
float firevision::MirrorModel::getOrientation | ( | ) | const [pure virtual] |
Get orientation of the omni-camera.
Implemented in firevision::Bulb.
f_point_t firevision::MirrorModel::getWorldPointGlobal | ( | unsigned int | image_x, |
unsigned int | image_y, | ||
float | pose_x, | ||
float | pose_y, | ||
float | pose_ori | ||
) | const [pure virtual] |
Get global coordinate based on image coordinates.
image_x | x coordinate in image in pixels |
image_y | y coordinate in image in pixels |
pose_x | robot pose global x coordinate |
pose_y | robot pose global y coordinate |
pose_ori | robot pose global orientation |
Implemented in firevision::Bulb.
Referenced by firevision::OmniGlobal::calc().
polar_coord_t firevision::MirrorModel::getWorldPointRelative | ( | unsigned int | image_x, |
unsigned int | image_y | ||
) | const [pure virtual] |
Get relative coordinate based on image coordinates.
image_x | x coordinate in image in pixels |
image_y | y coordinate in image in pixels |
Implemented in firevision::Bulb.
Referenced by firevision::OmniRelative::calc().
bool firevision::MirrorModel::isValidPoint | ( | unsigned int | image_x, |
unsigned int | image_y | ||
) | const [pure virtual] |
Check if the given point is valid.
image_x | x coordinate of queried pixel in image |
image_y | y coordinate of queried pixel in image |
Implemented in firevision::Bulb.
void firevision::MirrorModel::reset | ( | ) | [pure virtual] |
void firevision::MirrorModel::setCenter | ( | unsigned int | image_x, |
unsigned int | image_y | ||
) | [pure virtual] |
Set center of omni-camera to given image pixel.
image_x | x coordinate in image in pixels |
image_y | y coordinate in image in pixels |
Implemented in firevision::Bulb.
void firevision::MirrorModel::setOrientation | ( | float | angle | ) | [pure virtual] |
Set orientation of the omni-camera device.
angle | angle to the forward direction. |
Implemented in firevision::Bulb.
void firevision::MirrorModel::unwarp2warp | ( | unsigned int | unwarp_x, |
unsigned int | unwarp_y, | ||
unsigned int * | warp_x, | ||
unsigned int * | warp_y | ||
) | [pure virtual] |
Transform unwarped to warped point.
Given a point in the unwarped image it returns the coordinates of the corresponding pixel in the warped image Useful for: You want to generate the unwarped image and ask the model for every point of the unwarped image which warped pixel to copy
unwarp_x | unwarped x coordinate |
unwarp_y | unwarped y coordinate |
warp_x | contains the warped x coordinate upon return |
warp_y | contains the warped y coordinate upon return |
Implemented in firevision::Bulb.
Referenced by firevision::FilterUnwarp::apply().
void firevision::MirrorModel::warp2unwarp | ( | unsigned int | warp_x, |
unsigned int | warp_y, | ||
unsigned int * | unwarp_x, | ||
unsigned int * | unwarp_y | ||
) | [pure virtual] |
Transform warped to unwarped point.
Given a point in the warped image it returns the coordinates of the corresponding pixel in the unwarped image Useful for: You found the ball center in the image and want to get the position this pixel would have in an unwarped image
warp_x | warped x coordinate |
warp_y | warped y coordinate |
unwarp_x | contains unwarped x coordinate upon return |
unwarp_y | contains unwarped y coordinate upon return |
Implemented in firevision::Bulb.