Read@CVL
rdf::BlobManager Class Reference

Allows to manipulate the Blobs class (filter, etc.) More...

#include <Blobs.h>

Public Member Functions

QVector< BlobfilterArea (int area, const Blobs &blobs) const
 Filters blobs according to a minimal area. Removes all blobs with an area smaller than area. More...
 
QVector< BlobfilterMar (float maxAspectRatio, int minWidth, const Blobs &blobs) const
 Filters blobs according to the size and the aspect ratio. More...
 
QVector< BlobfilterAngle (double angle, double maxAngleDiff, const Blobs &blobs) const
 Filters blobs according to their orientation. More...
 
cv::Mat drawBlobs (const Blobs &blobs, cv::Scalar color=cv::Scalar(255, 255, 255)) const
 Draws the blobs and returns a CV_8UC1 image. More...
 
QVector< Linelines (const Blobs &blobs) const
 Assumes all blobs as lines and fit a Line based on the minimum area rectangle. More...
 
Blob getBiggestBlob (const Blobs &blobs) const
 Gets the biggest BLOB. More...
 

Static Public Member Functions

static BlobManagerinstance ()
 Creates an instance or return the instance. More...
 

Detailed Description

Allows to manipulate the Blobs class (filter, etc.)

Member Function Documentation

cv::Mat rdf::BlobManager::drawBlobs ( const Blobs blobs,
cv::Scalar  color = cv::Scalar(255, 255, 255) 
) const

Draws the blobs and returns a CV_8UC1 image.

Parameters
blobsThe blobs.
colorThe color of the blobs.
Returns
A CV_8UC1 image containing all blobs.
QVector< Blob > rdf::BlobManager::filterAngle ( double  angle,
double  maxAngleDiff,
const Blobs blobs 
) const

Filters blobs according to their orientation.

Parameters
angleThe specified orientation angle in rad.
maxAngleDiffThe maximum angle difference in degree.
blobsThe blobs.
Returns
The filtered blob vector
QVector< Blob > rdf::BlobManager::filterArea ( int  threshArea,
const Blobs blobs 
) const

Filters blobs according to a minimal area. Removes all blobs with an area smaller than area.

Parameters
areaThe area threshold.
blobsThe blobs.
Returns
The filtered blob vector
QVector< Blob > rdf::BlobManager::filterMar ( float  maxAspectRatio,
int  minWidth,
const Blobs blobs 
) const

Filters blobs according to the size and the aspect ratio.

Parameters
maxAspectRatioThe maximum aspect ratio.
minWidthThe minimum width.
blobsThe blobs.
Returns
The filtered blob vector.
Blob rdf::BlobManager::getBiggestBlob ( const Blobs blobs) const

Gets the biggest BLOB.

Parameters
blobsThe blobs.
Returns
The biggest blob.
BlobManager & rdf::BlobManager::instance ( )
static

Creates an instance or return the instance.

Returns
The instance of BlobManager.
QVector< Line > rdf::BlobManager::lines ( const Blobs blobs) const

Assumes all blobs as lines and fit a Line based on the minimum area rectangle.

Parameters
blobsThe blobs.
Returns
The line vector.

The documentation for this class was generated from the following files: