A class that defines a single blob within an image.
More...
#include <Blobs.h>
|
| Blob () |
| Initializes a new instance of the Blob class. More...
|
|
| Blob (const QVector< cv::Point > &outerC, const QVector< QVector< cv::Point > > &innerC) |
| Initializes a new instance of the Blob class. More...
|
|
bool | isEmpty () const |
| Determines whether this instance is empty. More...
|
|
void | setBlob (const QVector< cv::Point > &outerC, const QVector< QVector< cv::Point > > &innerC) |
| Sets the blob. More...
|
|
QVector< cv::Point > | outerContour () const |
| Returns the outer contour. More...
|
|
QVector< QVector< cv::Point > > | innerContours () const |
| Returns the inner contours. More...
|
|
QVector< cv::Vec4i > | hierarchy () const |
| Calculates the hierarchy for the blob such that it can be used with openCV functions. More...
|
|
float | blobOrientation () const |
| The blobs orientation based on moments. More...
|
|
bool | drawBlob (cv::Mat &imgSrc, cv::Scalar color=cv::Scalar(255, 255, 255), int maxLevel=1) const |
| Draws the Blob. More...
|
|
A class that defines a single blob within an image.
Initializes a new instance of the Blob class.
rdf::Blob::Blob |
( |
const QVector< cv::Point > & |
outerC, |
|
|
const QVector< QVector< cv::Point > > & |
innerC |
|
) |
| |
Initializes a new instance of the Blob class.
- Parameters
-
outerC | The outer contour of the blob. |
innerC | The inner contours of the blob (can be more than one). |
float rdf::Blob::blobOrientation |
( |
| ) |
const |
The blobs orientation based on moments.
- Returns
- The orientation of the blob in rad.
bool rdf::Blob::drawBlob |
( |
cv::Mat & |
imgSrc, |
|
|
cv::Scalar |
color = cv::Scalar(255, 255, 255) , |
|
|
int |
maxLevel = 1 |
|
) |
| const |
Draws the Blob.
- Parameters
-
imgSrc | The img source where the blob is drawn. |
color | The color of the blob. |
- Returns
- True if the blob is drawn.
QVector< cv::Vec4i > rdf::Blob::hierarchy |
( |
| ) |
const |
Calculates the hierarchy for the blob such that it can be used with openCV functions.
- Returns
- The OpenCV hierarchy.
QVector< QVector< cv::Point > > rdf::Blob::innerContours |
( |
| ) |
const |
Returns the inner contours.
- Returns
- The inner contours.
bool rdf::Blob::isEmpty |
( |
| ) |
const |
Determines whether this instance is empty.
- Returns
- True if emtpy.
QVector< cv::Point > rdf::Blob::outerContour |
( |
| ) |
const |
Returns the outer contour.
- Returns
- The outer contour.
void rdf::Blob::setBlob |
( |
const QVector< cv::Point > & |
outerC, |
|
|
const QVector< QVector< cv::Point > > & |
innerC |
|
) |
| |
Sets the blob.
- Parameters
-
outerC | The outer contour. |
innerC | The inner contours. |
QVector<QVector<cv::Point> > rdf::Blob::mInnerContours |
|
protected |
QVector<cv::Point> rdf::Blob::mOuterContour |
|
protected |
The documentation for this class was generated from the following files: