This class stores data of a connected component. More...
#include <ConnectedComponent.h>
Public Member Functions | |
ConnectedComponent () | |
ConnectedComponent (int pi_labelId, int pi_MinX, int pi_MinY, int pi_MaxX, int pi_MaxY, double pi_CogX, double pi_CogY, int pi_SegmentSize=0) | |
double | getCogX () const |
double | getCogY () const |
unsigned | getLabelId () const |
int | getMaxX () const |
int | getMaxY () const |
int | getMinX () const |
int | getMinY () const |
int | getSegmentSize () const |
void | setCOG (double pi_CogX, double pi_CogY) |
void | setMaxCoordinates (int pi_MaxX, int pi_MaxY) |
void | setMinCoordinates (int pi_MinX, int pi_MinY) |
void | setSegmentSize (int pi_SegmentSize) |
~ConnectedComponent () | |
Private Attributes | |
double | m_CogX |
double | m_CogY |
unsigned | m_LabelId |
int | m_MaxX |
int | m_MaxY |
int | m_MinX |
int | m_MinY |
int | m_SegmentSize |
This class stores data of a connected component.
Definition at line 26 of file ConnectedComponent.h.
ConnectedComponent::ConnectedComponent | ( | ) | [inline] |
Default constructor. Sets all members to 0.
Definition at line 33 of file ConnectedComponent.h.
ConnectedComponent::ConnectedComponent | ( | int | pi_labelId, |
int | pi_MinX, | ||
int | pi_MinY, | ||
int | pi_MaxX, | ||
int | pi_MaxY, | ||
double | pi_CogX, | ||
double | pi_CogY, | ||
int | pi_SegmentSize = 0 |
||
) | [inline] |
Constructor
pi_labelId | Id of the label this component represents (0 = invalid) |
pi_MinX | The minimal x-coordinate of bounding-box |
pi_MinY | The minimal y-coordinate of bounding-box |
pi_MaxX | The maximal x-coordinate of bounding-box |
pi_MaxY | The maximal y-coordinate of bounding-box |
pi_CogX | The x-coordinate of the center of gravity |
pi_CogY | The y-coordinate of the center of gravity |
pi_SegmentSize | The size of the found segment in pixels |
Definition at line 57 of file ConnectedComponent.h.
ConnectedComponent::~ConnectedComponent | ( | ) | [inline] |
Destruktor
Definition at line 75 of file ConnectedComponent.h.
double ConnectedComponent::getCogX | ( | ) | const [inline] |
Definition at line 124 of file ConnectedComponent.h.
double ConnectedComponent::getCogY | ( | ) | const [inline] |
Definition at line 125 of file ConnectedComponent.h.
unsigned ConnectedComponent::getLabelId | ( | ) | const [inline] |
Definition at line 127 of file ConnectedComponent.h.
int ConnectedComponent::getMaxX | ( | ) | const [inline] |
Definition at line 122 of file ConnectedComponent.h.
int ConnectedComponent::getMaxY | ( | ) | const [inline] |
Definition at line 123 of file ConnectedComponent.h.
int ConnectedComponent::getMinX | ( | ) | const [inline] |
get Methods
Definition at line 120 of file ConnectedComponent.h.
int ConnectedComponent::getMinY | ( | ) | const [inline] |
Definition at line 121 of file ConnectedComponent.h.
int ConnectedComponent::getSegmentSize | ( | ) | const [inline] |
Definition at line 126 of file ConnectedComponent.h.
void ConnectedComponent::setCOG | ( | double | pi_CogX, |
double | pi_CogY | ||
) | [inline] |
Sets coordinates of the center of gravity
Definition at line 103 of file ConnectedComponent.h.
void ConnectedComponent::setMaxCoordinates | ( | int | pi_MaxX, |
int | pi_MaxY | ||
) | [inline] |
Sets coordinates of lower right corner
pi_MaxX | The maximal x-coordinate of bounding-box |
pi_MaxY | The maximal y-coordinate of bounding-box |
Definition at line 94 of file ConnectedComponent.h.
void ConnectedComponent::setMinCoordinates | ( | int | pi_MinX, |
int | pi_MinY | ||
) | [inline] |
Sets coordinates of upper left corner
pi_MinX | The minimal x-coordinate of bounding-box |
pi_MinY | The minimal y-coordinate of bounding-box |
Definition at line 83 of file ConnectedComponent.h.
void ConnectedComponent::setSegmentSize | ( | int | pi_SegmentSize | ) | [inline] |
pi_SegmentSize | Size of the segment in pixels |
Definition at line 112 of file ConnectedComponent.h.
double ConnectedComponent::m_CogX [private] |
Center of gravity, x coordinate (sub pixel accuracy)
Definition at line 149 of file ConnectedComponent.h.
double ConnectedComponent::m_CogY [private] |
Center of gravity, y coordinate (sub pixel accuracy)
Definition at line 153 of file ConnectedComponent.h.
unsigned ConnectedComponent::m_LabelId [private] |
Definition at line 159 of file ConnectedComponent.h.
int ConnectedComponent::m_MaxX [private] |
Bounding box, lower right x coordinate
Definition at line 141 of file ConnectedComponent.h.
int ConnectedComponent::m_MaxY [private] |
Bounding box, lower right y coordinate
Definition at line 145 of file ConnectedComponent.h.
int ConnectedComponent::m_MinX [private] |
Bounding box, upper left x coordinate
Definition at line 133 of file ConnectedComponent.h.
int ConnectedComponent::m_MinY [private] |
Bounding box, upper left y coordinate
Definition at line 137 of file ConnectedComponent.h.
int ConnectedComponent::m_SegmentSize [private] |
Size of the segment in pixels
Definition at line 157 of file ConnectedComponent.h.