Fawkes API Fawkes Development Version
relativepositionmodel.h
1
2/***************************************************************************
3 * relativepositionmodel.h - Abstract class defining a position model for
4 * calculation of relative position
5 *
6 * Created: Tue May 31 13:50:12 2005
7 * Copyright 2005-2006 Tim Niemueller [www.niemueller.de]
8 *
9 ****************************************************************************/
10
11/* This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version. A runtime exception applies to
15 * this software (see LICENSE.GPL_WRE file mentioned below for details).
16 *
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU Library General Public License for more details.
21 *
22 * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
23 */
24
25#ifndef _FIREVISION_RELATIVEPOSITIONMODEL_H_
26#define _FIREVISION_RELATIVEPOSITIONMODEL_H_
27
28#include <fvutils/base/types.h>
29
30namespace firevision {
31
33{
34public:
35 virtual ~RelativePositionModel();
36
37 virtual const char *get_name(void) const = 0;
38 virtual void set_radius(float r) = 0;
39 virtual void set_center(float x, float y) = 0;
40 virtual void set_center(const center_in_roi_t &c) = 0;
41
42 virtual void set_pan_tilt(float pan, float tilt) = 0;
43 virtual void get_pan_tilt(float *pan, float *tilt) const = 0;
44
45 virtual void set_cam_rotation(float pan, float tilt, float roll = 0.f);
46 virtual void get_cam_rotation(float &pan, float &tilt, float &roll) const;
47
48 virtual void set_cam_translation(float height, float rel_x = 0.f, float rel_y = 0.f);
49 virtual void get_cam_translation(float &height, float &rel_x, float &rel_y) const;
50
51 virtual void calc() = 0;
52 virtual void calc_unfiltered() = 0;
53
54 virtual void reset() = 0;
55
56 virtual float get_distance() const = 0;
57 virtual float get_bearing() const = 0;
58 virtual float get_slope() const = 0;
59 virtual float get_x() const = 0;
60 virtual float get_y() const = 0;
61
62 virtual bool is_pos_valid() const = 0;
63};
64
65} // end namespace firevision
66
67#endif
Relative Position Model Interface.
virtual void set_pan_tilt(float pan, float tilt)=0
Set camera pan and tilt.
virtual void set_cam_translation(float height, float rel_x=0.f, float rel_y=0.f)
Sets the current translation of the camera.
virtual void calc()=0
Calculate position data.
virtual void get_cam_rotation(float &pan, float &tilt, float &roll) const
Returns the camera orientation.
virtual void set_cam_rotation(float pan, float tilt, float roll=0.f)
Sets the camera orientation.
virtual float get_bearing() const =0
Get bearing (horizontal angle) to object.
virtual void reset()=0
Reset all data.
virtual float get_slope() const =0
Get slope (vertical angle) to object.
virtual void get_pan_tilt(float *pan, float *tilt) const =0
Get camera pan tilt.
virtual void get_cam_translation(float &height, float &rel_x, float &rel_y) const
Returns the current translation of the camera.
virtual void calc_unfiltered()=0
Calculate data unfiltered.
virtual float get_y() const =0
Get relative Y coordinate of object.
virtual void set_center(float x, float y)=0
Set center of a found circle.
virtual const char * get_name(void) const =0
Get name of relative position model.
virtual void set_center(const center_in_roi_t &c)=0
Set center of a found circle.
virtual float get_x() const =0
Get relative X coordinate of object.
virtual void set_radius(float r)=0
Set radius of a found circle.
virtual float get_distance() const =0
Get distance to object.
virtual bool is_pos_valid() const =0
Check if position is valid.
Center in ROI.
Definition: types.h:38