Line shape. More...
#include <models/shape/line.h>

Public Member Functions | |
| LineShape (unsigned int roi_width, unsigned int roi_height) | |
| Constructor. | |
| ~LineShape () | |
| Destructor. | |
| void | printToStream (std::ostream &stream) |
| Print line. | |
| void | setMargin (unsigned int margin) |
| Set margin around shape. | |
| bool | isClose (unsigned int in_roi_x, unsigned int in_roi_y) |
| Check if the given point is close to the shape. | |
| void | calcPoints () |
| Calc points for line. | |
| void | getPoints (int *x1, int *y1, int *x2, int *y2) |
| Get two points that define the line. | |
Friends | |
| class | HtLinesModel |
| class | RhtLinesModel |
Line shape.
Definition at line 40 of file line.h.
| firevision::LineShape::LineShape | ( | unsigned int | roi_width, | |
| unsigned int | roi_height | |||
| ) |
| void firevision::LineShape::calcPoints | ( | ) |
Calc points for line.
Definition at line 107 of file line.cpp.
References fawkes::deg2rad().
Referenced by getPoints(), firevision::RhtLinesModel::getShapes(), and firevision::HtLinesModel::getShapes().
| void firevision::LineShape::getPoints | ( | int * | x1, | |
| int * | y1, | |||
| int * | x2, | |||
| int * | y2 | |||
| ) |
Get two points that define the line.
| x1 | contains x coordinate of first point upon return | |
| y1 | contains y coordinate of first point upon return | |
| x2 | contains x coordinate of second point upon return | |
| y2 | contains y coordinate of second point upon return |
Definition at line 205 of file line.cpp.
References calcPoints().
| bool firevision::LineShape::isClose | ( | unsigned int | in_roi_x, | |
| unsigned int | in_roi_y | |||
| ) | [virtual] |
Check if the given point is close to the shape.
| in_roi_x | x coordinate of point in the same ROI as the shape | |
| in_roi_y | y coordinate of point in the same ROI as the shape |
Implements firevision::Shape.
| void firevision::LineShape::printToStream | ( | std::ostream & | stream | ) |
| void firevision::LineShape::setMargin | ( | unsigned int | margin | ) | [virtual] |
1.6.1