|
latest version v1.9 - last update 24 Nov 2005 |
|
#include <ltiBoundingBox.h>
Inheritance diagram for lti::boundingBox< T >:


Public Member Functions | |
| boundingBox () | |
| boundingBox (const boundingBox &other) | |
| virtual | ~boundingBox () |
| virtual const char * | getTypeName () const |
| bool | apply (matrix< T > &srcdest, const areaPoints &obj) const |
| bool | apply (const matrix< T > &src, const areaPoints &obj, matrix< T > &dest) const |
| bool | apply (const matrix< T > &src, const areaPoints &obj, matrix< T > &dest, rectLocation &loc) const |
| bool | apply (const areaPoints &obj, rectLocation &loc) const |
| bool | apply (const ioPoints &obj, rectLocation &loc) const |
| bool | apply (const pointList &obj, rectLocation &loc) const |
| boundingBox & | copy (const boundingBox &other) |
| virtual functor * | clone () const |
| const parameters & | getParameters () const |
Protected Member Functions | |
| void | calculatePositions (const areaPoints &obj, point &destSize, point &delta) const |
| void | computeLocation (const pointList &pts, rectLocation &loc) const |
| bool | computeLocationFromCH (const pointList &convexHull, rectLocation &loc) const |
Classes | |
| class | parameters |
| the parameters for the class boundingBox More... | |
After segmenting the biggest object on an image or channel, it is usually desirable to get a new image with the extracted object only. This class will allow to generate such an image. The position of the desired object will be indicated by the area points of a contour object.
Type T of the template specify the type of the matrix to be used (for images this will be rgbPixel and for channels float).
Example:
lti::loadBMP loader; lti::image img,biggestObject; lti::channel8 mask; loader.load("img/leo040801_00_019.bmp",img); // load an image lti::regionGrowing segmenter; // functor for segmentation segmenter.apply(img,mask); // get a mask to differentiate background // and object. // get the biggest object on the mask lti::objectsFromMask ofm; std::list<areaPoints> objs; ofm.apply(mask,objs); // the first object on "objs" is the biggest one // on the mask! // get a new image with the biggest object only lti::boundingBox<image::value_type> bbox; lti::boundingBox<image::value_type>::parameters bboxParam; bboxParam.borderSize = 5; // the border will have 5 pixels (each side!) bboxParam.centerOfGravity = false; bbox.apply(img,objs.front(),biggestObject);
|
|||||||||
|
default constructor
|
|
||||||||||
|
copy constructor
|
|
|||||||||
|
destructor
|
|
||||||||||||||||
|
computes the oriented rectangular bounding box for the given point list, and leaves the result as a rectLocation.
|
|
||||||||||||||||
|
computes the oriented rectangular bounding box for the given io points, and leaves the result as a rectLocation.
|
|
||||||||||||||||
|
computes the oriented rectangular bounding box for the given area points, and leaves the result as a rectLocation.
|
|
||||||||||||||||||||||||
|
Take the object specified by the area points on the given contour, and create a new image with only the object and a border of the specified size on the srcdest.
|
|
||||||||||||||||||||
|
Take the object specified by the area points on the given contour, and create a new image with only the object and a border of the specified size on the srcdest.
|
|
||||||||||||||||
|
Take the object specified by the area points, and create a new image with only the object and a border of the specified size on the srcdest.
|
|
||||||||||||||||||||
|
calculate the source box of the source image, the size of the destination image, and the position of the box on the destination image.
|
|
|||||||||
|
returns a pointer to a clone of this functor.
Reimplemented from lti::segmentation. |
|
||||||||||||||||
|
compute the location given the angle in the location.
|
|
||||||||||||||||
|
location from the convex hull
|
|
||||||||||
|
copy data of "other" functor.
|
|
|||||||||
|
returns used parameters
Reimplemented from lti::functor. |
|
|||||||||
|
returns the name of this type ("boundingBox")
Reimplemented from lti::segmentation. |