Blob class.
More...
#include <Blob.h>
List of all members.
Public Member Functions |
void | AddInternalContour (const CBlobContour &newContour) |
| Adds a new internal contour to the blob.
|
double | Area () |
| Compute blob's area.
|
| CBlob () |
| CBlob (t_labelType id, CvPoint startPoint, CvSize originalImageSize) |
| CBlob (const CBlob &src) |
| Copy constructor.
|
| CBlob (const CBlob *src) |
int | Exterior (IplImage *mask, bool xBorder=true, bool yBorder=true) |
| > 0 for extern blobs, 0 if not
|
double | ExternPerimeter (IplImage *mask, bool xBorder=true, bool yBorder=true) |
| Compute extern perimeter.
|
void | FillBlob (IplImage *imatge, CvScalar color, int offsetX=0, int offsetY=0) |
CvRect | GetBoundingBox () |
| Get bounding box.
|
t_PointList | GetConvexHull () |
CvBox2D | GetEllipse () |
| Get bounding ellipse.
|
CBlobContour * | GetExternalContour () |
| Retrieves contour in Freeman's chain code.
|
t_labelType | GetID () |
| Get label ID.
|
CvMemStorage * | GetStorage () |
| Retrieves blob storage.
|
bool | IsEmpty () |
void | JoinBlob (CBlob *blob) |
| Join a blob to current one (add's contour.
|
double | MaxX () |
| Maximun X.
|
double | MaxY () |
| Maximun Y.
|
double | Mean (IplImage *image) |
| Get mean grey color.
|
double | MinX () |
| Minimun X.
|
double | MinY () |
| Minimun Y.
|
double | Moment (int p, int q) |
| Compute blob's moment (p,q up to MAX_CALCULATED_MOMENTS)
|
CBlob & | operator= (const CBlob &src) |
double | Perimeter () |
| Compute blob's perimeter.
|
double | StdDev (IplImage *image) |
| Get standard deviation grey color.
|
| ~CBlob () |
Private Types |
typedef std::list< CBlobContour > | t_contourList |
Private Member Functions |
void | ClearContours () |
| Deallocates all contours.
|
Private Attributes |
double | m_area |
| Area.
|
CvRect | m_boundingBox |
| Bounding box.
|
CvBox2D | m_ellipse |
| Bounding ellipse.
|
CBlobContour | m_externalContour |
| External contour of the blob (crack codes)
|
double | m_externPerimeter |
| Extern perimeter from blob.
|
t_labelType | m_id |
| Label number.
|
t_contourList | m_internalContours |
| Internal contours (crack codes)
|
double | m_meanGray |
| Mean gray color.
|
CvSize | m_originalImageSize |
| Sizes from image where blob is extracted.
|
double | m_perimeter |
| Perimeter.
|
double | m_stdDevGray |
| Standard deviation from gray color blob distribution.
|
CvMemStorage * | m_storage |
| Contour storage memory.
|
Detailed Description
Blob class.
Definition at line 37 of file Blob.h.
Member Typedef Documentation
Constructor & Destructor Documentation
Copy constructor.
Definition at line 41 of file Blob.cpp.
Member Function Documentation
Adds a new internal contour to the blob.
Definition at line 132 of file Blob.cpp.
Compute blob's area.
- FUNCIÓ: Area
- FUNCIONALITAT: Get blob area, ie. external contour area minus internal contours area
- PARÀMETRES:
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/04/30
- MODIFICACIÓ: Data. Autor. Descripció.
Definition at line 157 of file Blob.cpp.
Deallocates all contours.
Definition at line 116 of file Blob.cpp.
> 0 for extern blobs, 0 if not
- FUNCIÓ: Exterior
- FUNCIONALITAT: Return true for extern blobs
- PARÀMETRES:
- xBorder: true to consider blobs touching horizontal borders as extern
- yBorder: true to consider blobs touching vertical borders as extern
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/05/06
- MODIFICACIÓ: Data. Autor. Descripció.
Definition at line 219 of file Blob.cpp.
Compute extern perimeter.
- FUNCIÓ: ExternPerimeter
- FUNCIONALITAT: Get extern perimeter (perimeter touching image borders)
- PARÀMETRES:
- maskImage: if != NULL, counts maskImage black pixels as external pixels and contour points touching them are counted as external contour points.
- xBorder: true to consider blobs touching horizontal borders as extern
- yBorder: true to consider blobs touching vertical borders as extern
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/05/05
- MODIFICACIÓ: Data. Autor. Descripció.
- NOTA: If CBlobContour::GetContourPoints aproximates contours with a method different that NONE, this function will not give correct results
Definition at line 246 of file Blob.cpp.
void CBlob::FillBlob |
( |
IplImage * |
imatge, |
|
|
CvScalar |
color, |
|
|
int |
offsetX = 0 , |
|
|
int |
offsetY = 0 |
|
) |
| |
Pinta l'interior d'un blob d'un color determinat Paints the blob in an image
- FUNCTION: FillBlob
- FUNCTIONALITY:
- Fills the blob with a specified colour
- PARAMETERS:
- imatge: where to paint
- color: colour to paint the blob
- RESULT:
- modifies input image and returns the seed point used to fill the blob
- RESTRICTIONS:
- AUTHOR: Ricard Borràs
- CREATION DATE: 25-05-2005.
- MODIFICATION: Date. Author. Description.
Definition at line 649 of file Blob.cpp.
Get bounding box.
- FUNCIÓ: GetBoundingBox
- FUNCIONALITAT: Get bounding box (without rotation) of a blob
- PARÀMETRES:
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/05/06
- MODIFICACIÓ: Data. Autor. Descripció.
Definition at line 488 of file Blob.cpp.
Retorna el poligon convex del blob Calculates the convex hull of the blob
- FUNCTION: GetConvexHull
- FUNCTIONALITY: Calculates the convex hull polygon of the blob
- PARAMETERS:
- dst: where to store the result
- RESULT:
- RESTRICTIONS:
- AUTHOR: Ricard Borràs
- CREATION DATE: 25-05-2005.
- MODIFICATION: Date. Author. Description.
Definition at line 667 of file Blob.cpp.
Get bounding ellipse.
- FUNCIÓ: GetEllipse
- FUNCIONALITAT: Calculates bounding ellipse of external contour points
- PARÀMETRES:
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/05/06
- MODIFICACIÓ: Data. Autor. Descripció.
- NOTA: Calculation is made using second order moment aproximation
Definition at line 555 of file Blob.cpp.
Retrieves contour in Freeman's chain code.
Definition at line 58 of file Blob.h.
Get label ID.
Definition at line 70 of file Blob.h.
Retrieves blob storage.
Definition at line 64 of file Blob.h.
Indica si el blob està buit ( no té cap info associada ) Shows if the blob has associated information
Definition at line 139 of file Blob.cpp.
Join a blob to current one (add's contour.
- FUNCTION: JoinBlob
- FUNCTIONALITY: Add's external contour to current external contour
- PARAMETERS:
- blob: blob from which extract the added external contour
- RESULT:
- RESTRICTIONS: Only external contours are added
- AUTHOR: Ricard Borràs
- CREATION DATE: 25-05-2005.
- MODIFICATION: Date. Author. Description.
Definition at line 690 of file Blob.cpp.
Maximun X.
Definition at line 123 of file Blob.h.
Maximun Y.
Definition at line 128 of file Blob.h.
Get mean grey color.
- FUNCIÓ: Mean
- FUNCIONALITAT: Get blob mean color in input image
- PARÀMETRES:
- image: image from gray color are extracted
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/05/06
- MODIFICACIÓ: Data. Autor. Descripció.
Definition at line 409 of file Blob.cpp.
Minimun X.
Definition at line 113 of file Blob.h.
Minimun Y.
Definition at line 118 of file Blob.h.
Compute blob's moment (p,q up to MAX_CALCULATED_MOMENTS)
Definition at line 379 of file Blob.cpp.
Operador d'assignació Assigment operator
Definition at line 56 of file Blob.cpp.
Compute blob's perimeter.
- FUNCIÓ: Perimeter
- FUNCIONALITAT: Get blob perimeter, ie. sum of the lenght of all the contours
- PARÀMETRES:
- RESULTAT:
- RESTRICCIONS:
- AUTOR: rborras
- DATA DE CREACIÓ: 2008/04/30
- MODIFICACIÓ: Data. Autor. Descripció.
Definition at line 187 of file Blob.cpp.
Get standard deviation grey color.
Definition at line 462 of file Blob.cpp.
Member Data Documentation
Bounding box.
Definition at line 165 of file Blob.h.
Bounding ellipse.
Definition at line 167 of file Blob.h.
External contour of the blob (crack codes)
Definition at line 144 of file Blob.h.
Extern perimeter from blob.
Definition at line 159 of file Blob.h.
Label number.
Definition at line 153 of file Blob.h.
Internal contours (crack codes)
Definition at line 146 of file Blob.h.
Mean gray color.
Definition at line 161 of file Blob.h.
Sizes from image where blob is extracted.
Definition at line 169 of file Blob.h.
Perimeter.
Definition at line 157 of file Blob.h.
Standard deviation from gray color blob distribution.
Definition at line 163 of file Blob.h.
Contour storage memory.
Definition at line 142 of file Blob.h.
The documentation for this class was generated from the following files: