|
Developer Documentation |
|
Centre for Vision, Speech & Signal Processing |
|
PUBLIC |
ImageRectangleC::ImageRectangleC(void)
ImageRectangleC::ImageRectangleC(IndexT,IndexT,IndexT,IndexT)
ImageRectangleC::ImageRectangleC(SizeT,SizeT)
ImageRectangleC::ImageRectangleC(const PixelC &,const PixelC &)
ImageRectangleC::ImageRectangleC(const IndexRangeC &,const IndexRangeC &)
ImageRectangleC::ImageRectangleC(const IndexRectangleC &)
ImageRectangleC::ImageRectangleC(const PixelC &,const SizeT)
ImageRectangleC::ImageRectangleC(const PixelC &,SizeT,SizeT)
ImageRectangleC::ImageRectangleC(istream &)
ImageRectangleC::operator=(const ImageRectangleC &)
ImageRectangleC::operator==(const ImageRectangleC &) const
ImageRectangleC::operator!=(const ImageRectangleC &) const
ImageRectangleC::IsInside(const ImageRectangleC &) const
ImageRectangleC::IsValid(void) const
ImageRectangleC::Contains(const Index2dC &) const
ImageRectangleC::Contains(const ImageRectangleC &) const
ImageRectangleC::Rectangle(void)
ImageRectangleC::Rectangle(void) const
ImageRectangleC::operator+=(const PixelC &)
ImageRectangleC::operator-=(const PixelC &)
ImageRectangleC::SetOrigin(const PixelC &)
ImageRectangleC::Dilate(void)
ImageRectangleC::Expand(const IndexT)
ImageRectangleC::Expand(const IndexT,const IndexT,const IndexT,const IndexT)
ImageRectangleC::Involve(const PixelC &)
ImageRectangleC::Involve(const ImageRectangleC &)
ImageRectangleC::BoundingBox(const ImageRectangleC &) const
ImageRectangleC::Quartile1(void)
ImageRectangleC::Quartile2(void)
ImageRectangleC::Quartile3(void)
ImageRectangleC::Quartile4(void)
ImageRectangleC::Double(void)
ImageRectangleC::Half(void)
ImageRectangleC::BiggerHalf(void)
ImageRectangleC::SmallerHalf(void)
ImageRectangleC::Rotate90(void)
ImageRectangleC::Rotate180(void)
ImageRectangleC::Rotate270(void)
ImageRectangleC::Clip(const ImageRectangleC &)
ImageRectangleC::ClipRows(const ImageRectangleC &)
ImageRectangleC::ClipCols(const ImageRectangleC &)
ImageRectangleC::ClipPixel(const PixelC &) const
ImageRectangleC::Intersection(const ImageRectangleC &) const
ImageRectangleC::TopDiff(const ImageRectangleC &) const
ImageRectangleC::BottomDiff(const ImageRectangleC &) const
ImageRectangleC::LeftDiff(const ImageRectangleC &) const
ImageRectangleC::RightDiff(const ImageRectangleC &) const
ImageRectangleC::ReflectUp(void)
ImageRectangleC::ReflectDown(void)
ImageRectangleC::ReflectLeft(void)
ImageRectangleC::ReflectRight(void)
ImageRectangleC::operator<<(ostream &,const ImageRectangleC &)
ImageRectangleC::operator>>(istream &,ImageRectangleC &)
IndexRectangleC::operator=(const IndexRectangleC &)
IndexRectangleC::operator==(const IndexRectangleC &) const
IndexRectangleC::operator!=(const IndexRectangleC &) const
IndexRectangleC::IsInside(const IndexRectangleC &) const
IndexRectangleC::Contains(const Index2dC &) const
IndexRectangleC::IsValid(void) const
IndexRectangleC::Rectangle(void)
IndexRectangleC::Rectangle(void) const
IndexRectangleC::RowRange(void) const
IndexRectangleC::ColumnRange(void) const
IndexRectangleC::Origin(void)
IndexRectangleC::Origin(void) const
IndexRectangleC::End(void)
IndexRectangleC::End(void) const
IndexRectangleC::Center(void) const
IndexRectangleC::Rnum(void) const
IndexRectangleC::Cnum(void) const
IndexRectangleC::TRow(void) const
IndexRectangleC::LCol(void) const
IndexRectangleC::BRow(void) const
IndexRectangleC::RCol(void) const
IndexRectangleC::TRow(void)
IndexRectangleC::LCol(void)
IndexRectangleC::BRow(void)
IndexRectangleC::RCol(void)
IndexRectangleC::Area(void) const
IndexRectangleC::operator+=(const Index2dC &)
IndexRectangleC::operator-=(const Index2dC &)
IndexRectangleC::SetOrigin(const Index2dC &)
IndexRectangleC::Dilate(void)
IndexRectangleC::Erode(void)
IndexRectangleC::Expand(const IndexT)
IndexRectangleC::Shrink(const IndexT) const
IndexRectangleC::Involve(const Index2dC &)
IndexRectangleC::Involve(const IndexRectangleC &)
IndexRectangleC::BoundingBox(const IndexRectangleC &) const
IndexRectangleC::Overlaps(const IndexRectangleC &) const
IndexRectangleC::Quartile1(void)
IndexRectangleC::Quartile2(void)
IndexRectangleC::Quartile3(void)
IndexRectangleC::Quartile4(void)
IndexRectangleC::Double(void)
IndexRectangleC::Half(void)
IndexRectangleC::BiggerHalf(void)
IndexRectangleC::SmallerHalf(void)
IndexRectangleC::Rotate90(void)
IndexRectangleC::Rotate180(void)
IndexRectangleC::Rotate270(void)
IndexRectangleC::Clip(const IndexRectangleC &)
IndexRectangleC::ClipRows(const IndexRectangleC &)
IndexRectangleC::ClipCols(const IndexRectangleC &)
IndexRectangleC::TopDiff(const IndexRectangleC &) const
IndexRectangleC::BottomDiff(const IndexRectangleC &) const
IndexRectangleC::LeftDiff(const IndexRectangleC &) const
IndexRectangleC::RightDiff(const IndexRectangleC &) const
IndexRectangleC::ReflectUp(void)
IndexRectangleC::ReflectDown(void)
IndexRectangleC::ReflectLeft(void)
IndexRectangleC::ReflectRight(void)
IndexRectangleC::ErrIfNotInside(const IndexRectangleC &,char *) const
IndexRectangleC::ErrIfNotSame(const IndexRectangleC &,char *) const
|
Comments:
The class ImageRectangleC is a specification of rectangular area
used by processing functions.
Parent Classes:
Derived Classes:
Methods:
- ImageRectangleC()
-
empty object
- ImageRectangleC(IndexT minRow,IndexT maxRow,IndexT minCol,IndexT maxCol)
-
constructor from limits
- ImageRectangleC(SizeT rows,SizeT columns)
-
constructor from limits
- ImageRectangleC(const PixelC & origin,const PixelC & endP)
-
constructor from 2 pixels
- ImageRectangleC(const IndexRangeC & rows,const IndexRangeC & cols)
-
constructor from row and column index range
- ImageRectangleC(const IndexRectangleC & rectangle)
-
the copy constructor
- ImageRectangleC(const PixelC & center,const SizeT maskSize)
-
constructor from the mask in the specific position 'center'
- ImageRectangleC(const PixelC & center,SizeT maskR,SizeT maskC)
-
constructor from the mask in the specific position 'center' with diffrent rows and cols.
- ImageRectangleC(istream & is)
-
constructor from the input stream 'is'
- const ImageRectangleC & operator=(const ImageRectangleC & rect)
-
assigment
Logical conditions
- BooleanT operator==(const ImageRectangleC & rect) const
-
Return TRUE if the rectangles are identical
- BooleanT operator!=(const ImageRectangleC & rect) const
-
Return TRUE if the rectangles are not identical
- BooleanT IsInside(const ImageRectangleC & rect) const
-
Returns TRUE if 'this' rectangle is inside the rectangle 'rect'.
NB. It will also return true if the rectangles are the same size.
- BooleanT IsValid() const
-
Returns TRUE if this rectangle contains at least one pixel.
- BooleanT Contains(const Index2dC & i) const
-
Returns TRUE if the index 'i' is inside this rectangle.
- BooleanT Contains(const ImageRectangleC & rect) const
-
Returns TRUE if this rectangle contains 'rect'
NB. It will also return true if the rectangles are the same size.
Access to the object representation
- ImageRectangleC & Rectangle()
-
Returns this image rectangle.
- const ImageRectangleC & Rectangle() const
-
Returns this image rectangle.
Modifications of the object
- const ImageRectangleC & operator+=(const PixelC & offset)
-
Shifts the rectangle to the new position.
- const ImageRectangleC & operator-=(const PixelC & offset)
-
Shifts the rectangle to the new position.
- const ImageRectangleC & SetOrigin(const PixelC & o)
-
Shifts the rectangle
New position with the origin pixel equal to 'o'.
- ImageRectangleC & Dilate()
-
Adds one pixel layer on each side.
- ImageRectangleC & Expand(const IndexT n)
-
Expands this rectangle by adding "n" pixels on each side.
- ImageRectangleC & Expand(const IndexT t,const IndexT b,const IndexT l,const IndexT r)
-
Expands this rectangle by adding "t" pixels to the top, "b" pixels to the bottom, "l" to the left and "r" to the right.
- ImageRectangleC & Involve(const PixelC & pxl)
-
Expands this rectangle to involve pxl
Modifies the image rectangle in such way that the result rectangle
is the minimum rectangle enclosing the original rectangle and
the pixel "pxl".
- ImageRectangleC & Involve(const ImageRectangleC & rect)
-
Expands this rectangle to involve rect
Sets rectangle in such way that contains both the original rectangle
and another rectangle 'rect'
- ImageRectangleC BoundingBox(const ImageRectangleC & rect) const
-
Gets a new rectangle that contains both this rectangle
and another rectangle 'rect'
-----------------
| 1 | 2 |
-----------------
| 3 | 4 |
-----------------
- ImageRectangleC & Quartile1()
-
- ImageRectangleC & Quartile2()
-
- ImageRectangleC & Quartile3()
-
- ImageRectangleC & Quartile4()
-
- ImageRectangleC & Double()
-
set rectangle to be 2 times bigger by shifting of endPixel
- ImageRectangleC & Half()
-
set rectangle to be 2 times smaller by shifting of endPixel
if the result can not be the exact half of the original rectangle
the rectangle is set to be bigger part
- ImageRectangleC & BiggerHalf()
-
set rectangle to be 2 times smaller by shifting of endPixel
if the result can not be the exact half of the original rectangle
the rectangle is set to be bigger part
- ImageRectangleC & SmallerHalf()
-
set rectangle to be 2 times smaller by shifting of endPixel
if the result can not be the exact half of the original rectangle
the rectangle is set to be smaller part
- ImageRectangleC & Rotate90()
-
Rotates the rectangle about PI/2 rad.
- ImageRectangleC & Rotate180()
-
Rotates the rectangle about PI rad.
- ImageRectangleC & Rotate270()
-
Rotates the rectangle about 3/2PI rad.
- ImageRectangleC & Clip(const ImageRectangleC & rec)
-
The rectangle is clipped to be within the rectangle 'rec'.
That means the result rectangle is certainly inside the 'rec'.
- ImageRectangleC & ClipRows(const ImageRectangleC & rect)
-
The rectangle rows are clipped to be within the rectangle 'rect'.
That means the result rows are certainly inside the 'rect'.
- ImageRectangleC & ClipCols(const ImageRectangleC & rect)
-
The rectangle columns are clipped to be within the rectangle 'rect'.
That means the result colums are certainly inside the 'rect'.
- PixelC ClipPixel(const PixelC & pxl) const
-
Clips pixel to be inside rectangle
Creation of new rectangles from object
- ImageRectangleC Intersection(const ImageRectangleC & rect) const
-
Rectangle which is intersection of rectangle 'rect' and inside this rectangle.
(Similar to "Clip" functions above)
- ImageRectangleC TopDiff(const ImageRectangleC & rect) const
-
Rectangle which is above the rectangle 'rect' and inside this rectangle.
- ImageRectangleC BottomDiff(const ImageRectangleC & rect) const
-
Rectangle which is below the rectangle 'rect' and inside this rectangle.
- ImageRectangleC LeftDiff(const ImageRectangleC & rect) const
-
Rectangle which is left from the rectangle 'rect' and inside this rectangle.
- ImageRectangleC RightDiff(const ImageRectangleC & rect) const
-
Rectangle which is right from the rectangle 'rect' and inside this rectangle.
- ImageRectangleC & ReflectUp()
-
Mirrors the image rectangle along its top edge.
- ImageRectangleC & ReflectDown()
-
Mirrors the image rectangle along its bottom edge.
- ImageRectangleC & ReflectLeft()
-
Mirrors the image rectangle along its left edge.
- ImageRectangleC & ReflectRight()
-
Mirrors the image rectangle along its right edge.
- ostream & operator<<(ostream & outS,const ImageRectangleC & rect)
-
write value of the rectangle to the output stream 'outS'
- istream & operator>>(istream & is,ImageRectangleC & rect)
-
read value of the rectangle from the input stream 'is'
- const IndexRectangleC & operator=(const IndexRectangleC & rect)
-
Assigment.
Logical conditions.
-------------------
- BooleanT operator==(const IndexRectangleC & rect) const
-
Return TRUE if the rectangles are identical
- BooleanT operator!=(const IndexRectangleC & rect) const
-
Return TRUE if the rectangles are not identical
- BooleanT IsInside(const IndexRectangleC & rect) const
-
Returns TRUE if 'this' rectangle is inside the rectangle 'rect'.
- BooleanT Contains(const Index2dC & i) const
-
Returns TRUE if the index 'i' is inside this rectangle.
- BooleanT IsValid() const
-
Returns TRUE if this rectangle contains at least one index.
Access to the object representation.
------------------------------------
- IndexRectangleC & Rectangle()
-
Returns this image rectangle.
- const IndexRectangleC & Rectangle() const
-
Returns this image rectangle.
- IndexRangeC RowRange() const
-
Returns the index range of rows.
- IndexRangeC ColumnRange() const
-
Returns the index range of columns.
- Index2dC & Origin()
-
Returns the top-left index of the image rectangle.
- const Index2dC & Origin() const
-
Returns the top-left index of the image rectangle.
- Index2dC & End()
-
Returns the bottom-right index of the image rectangle.
- const Index2dC & End() const
-
Returns the bottom-right index of the image rectangle.
- Index2dC Center() const
-
Returns the index which is in the middle of the image rectangle.
- SizeT Rnum() const
-
Returns number of rows.
- SizeT Cnum() const
-
Returns number of columns.
- IndexT TRow() const
-
Returns the top row index.
- IndexT LCol() const
-
Returns the left side column index.
- IndexT BRow() const
-
Returns the bottom row index.
- IndexT RCol() const
-
Returns the right side column index.
- IndexT & TRow()
-
Returns the top row index.
- IndexT & LCol()
-
Returns the left side column index.
- IndexT & BRow()
-
Returns the bottom row index.
- IndexT & RCol()
-
Returns the right side column index.
- LongIntT Area() const
-
Returns the area of the image rectangle expressed in number of indexs.
Modifications of the object.
----------------------------
- const IndexRectangleC & operator+=(const Index2dC & offset)
-
Shifts the rectangle to the new position.
- const IndexRectangleC & operator-=(const Index2dC & offset)
-
Shifts the rectangle to the new position.
- const IndexRectangleC & SetOrigin(const Index2dC & o)
-
Shifts the rectangle to the new position with the origin index
equal to 'o'.
- IndexRectangleC & Dilate()
-
Adds one index layer on each side.
- IndexRectangleC & Erode()
-
Removes one index layer on each side.
- IndexRectangleC & Expand(const IndexT n)
-
Expands the rectangle by adding 'n' indexs on each side.
- IndexRectangleC Shrink(const IndexT n) const
-
Returns a new rectangle which has layer of the width of 'n' indexs
removed.
- IndexRectangleC & Involve(const Index2dC & pxl)
-
Modifies the image rectangle in such way that the result rectangle
is the minimum rectangle enclosing the original rectangle and
the index 'pxl'.
- IndexRectangleC & Involve(const IndexRectangleC & rect)
-
Sets rectangle in such way that contains both the original rectangle
and another rectangle 'rect'
- IndexRectangleC BoundingBox(const IndexRectangleC & rect) const
-
Gets a new rectangle that contains both this rectangle
and another rectangle 'rect'
- BooleanT Overlaps(const IndexRectangleC & rect) const
-
Test if 'this' and 'rect' rectangle overlap.
-----------------
| 1 | 2 |
-----------------
| 3 | 4 |
-----------------
- IndexRectangleC & Quartile1()
-
- IndexRectangleC & Quartile2()
-
- IndexRectangleC & Quartile3()
-
- IndexRectangleC & Quartile4()
-
- IndexRectangleC & Double()
-
set rectangle to be 2 times bigger by shifting of endIndex
- IndexRectangleC & Half()
-
set rectangle to be 2 times smaller by shifting of endIndex
if the result can not be the exact half of the original rectangle
the rectangle is set to be bigger part
- IndexRectangleC & BiggerHalf()
-
set rectangle to be 2 times smaller by shifting of endIndex
if the result can not be the exact half of the original rectangle
the rectangle is set to be bigger part
- IndexRectangleC & SmallerHalf()
-
set rectangle to be 2 times smaller by shifting of endIndex
if the result can not be the exact half of the original rectangle
the rectangle is set to be smaller part
- IndexRectangleC & Rotate90()
-
Rotates the rectangle about PI/2 rad.
- IndexRectangleC & Rotate180()
-
Rotates the rectangle about PI rad.
- IndexRectangleC & Rotate270()
-
Rotates the rectangle about 3/2PI rad.
- IndexRectangleC & Clip(const IndexRectangleC & rec)
-
The rectangle is clipped by the rectangle 'rec'. That means
the result rectangle is certainly inside the 'rec'.
- IndexRectangleC & ClipRows(const IndexRectangleC & rect)
-
The rectangle rows are clipped by the rectangle 'rect'. That
means the result rows are certainly inside the 'rect'.
- IndexRectangleC & ClipCols(const IndexRectangleC & rect)
-
The rectangle columns are clipped by the rectangle 'rect'. That
means the result colums are certainly inside the 'rect'.
- IndexRectangleC TopDiff(const IndexRectangleC & rect) const
-
Returns the rectangle which is above the rectangle 'rect'
and inside this rectangle.
- IndexRectangleC BottomDiff(const IndexRectangleC & rect) const
-
Returns the rectangle which is below the rectangle 'rect'
and inside this rectangle.
- IndexRectangleC LeftDiff(const IndexRectangleC & rect) const
-
Returns the rectangle which is left from the rectangle 'rect'
and inside this rectangle.
- IndexRectangleC RightDiff(const IndexRectangleC & rect) const
-
Returns the rectangle which is right from the rectangle 'rect'
and inside this rectangle.
- IndexRectangleC & ReflectUp()
-
Mirrors the image rectangle along its top edge.
- IndexRectangleC & ReflectDown()
-
Mirrors the image rectangle along its bottom edge.
- IndexRectangleC & ReflectLeft()
-
Mirrors the image rectangle along its left edge.
- IndexRectangleC & ReflectRight()
-
Mirrors the image rectangle along its right edge.
- void ErrIfNotInside(const IndexRectangleC & rect,char * fnc = "") const
-
If this image rectangle is not inside the image rectangle 'rect',
the function triggers error exit. The function name 'fnc'
is send as the error triggering function.
- void ErrIfNotSame(const IndexRectangleC & rect,char * fnc = "") const
-
If this image rectangle has not the same size as the rectangle
'rect', the function triggers error exit. The function name
'fnc' is printed as the error triggering function.
|
Programmer:Radek Marik, Documentation by CxxDoc: Tue Mar 20 10:49:27 2001
|