User Documentation
RAVL, Recognition And Vision Library
DEVELOP HOME PAGE CLASS LIST CONTENTS
Ravl - Images - ImageRectangleC
 

  PUBLIC
ImageRectangleC::ImageRectangleC(void)
ImageRectangleC::ImageRectangleC(const IndexRange2dC &)
ImageRectangleC::ImageRectangleC(IntT,IntT)
ImageRectangleC::ImageRectangleC(const Index2dC &,const Index2dC &)
ImageRectangleC::ImageRectangleC(const Index2dC &,SizeT)
ImageRectangleC::ImageRectangleC(const Index2dC &,SizeT,SizeT)
ImageRectangleC::ImageRectangleC(IndexC,IndexC,IndexC,IndexC)
ImageRectangleC::ReflectUp(void)
ImageRectangleC::ReflectDown(void)
ImageRectangleC::ReflectLeft(void)
ImageRectangleC::ReflectRight(void)
IndexRange2dC::SetOrigin(const Index2dC &)
IndexRange2dC::Origin(void) const
IndexRange2dC::End(void) const
IndexRange2dC::TopRight(void) const
IndexRange2dC::TopLeft(void) const
IndexRange2dC::BottomLeft(void) const
IndexRange2dC::BottomRight(void) const
IndexRange2dC::Center(void) const
IndexRange2dC::TRow(void) const
IndexRange2dC::LCol(void) const
IndexRange2dC::BRow(void) const
IndexRange2dC::RCol(void) const
IndexRange2dC::TRow(void)
IndexRange2dC::LCol(void)
IndexRange2dC::BRow(void)
IndexRange2dC::RCol(void)
IndexRange2dC::Rows(void) const
IndexRange2dC::Cols(void) const
IndexRange2dC::Size(void) const
IndexRange2dC::Area(void) const
IndexRange2dC::Dilate(void) const
IndexRange2dC::Erode(void) const
IndexRange2dC::Expand(IndexC) const
IndexRange2dC::Shrink(IndexC) const
IndexRange2dC::ClipBy(const IndexRange2dC &)
IndexRange2dC::Contains(const IndexRange2dC &) const
IndexRange2dC::Contains(const Index2dC &) const
IndexRange2dC::operator +=(const Index2dC &)
IndexRange2dC::operator -=(const Index2dC &)
IndexRange2dC::operator +(const Index2dC &) const
IndexRange2dC::operator -(const Index2dC &) const
IndexRange2dC::RowRange(void) const
IndexRange2dC::ColRange(void) const
IndexRange2dC::RowRange(void)
IndexRange2dC::ColRange(void)
IndexRange2dC::Range1(void) const
IndexRange2dC::Range2(void) const
IndexRange2dC::Range1(void)
IndexRange2dC::Range2(void)
IndexRange2dC::Involve(const Index2dC &)
IndexRange2dC::Involve(const IndexRange2dC &)
IndexRange2dC::IsValid(void) const
IndexRange2dC::operator ==(const IndexRange2dC &) const
IndexRange2dC::operator !=(const IndexRange2dC &) const
IndexRange2dC::Rotate180(Index2dC)
IndexRange2dC::IsOverlapping(const IndexRange2dC &) const
IndexRange2dC::operator -=(const IndexRange2dC &)
IndexRange2dC::operator -(const IndexRange2dC &) const

   ImageRectangleC   
 
Image Rectangle.
 
include "Ravl/Image/ImageRectangle.hh"
Created:24/01/2001 
User Level:Normal
Library:RavlImage
In Scope:RavlImageN

Parent Classes: Methods:
ImageRectangleC()
Default constructor.
creates an undefined rectangle.

ImageRectangleC(const IndexRange2dC & oth)
Base constructor.

ImageRectangleC(IntT rows,IntT cols)
Construct a rectangle of the given size with an origin of 0,0

ImageRectangleC(const Index2dC & org,const Index2dC & end)
Construct from corner points.

ImageRectangleC(const Index2dC & center,SizeT size)
Construct a square from center and size.

ImageRectangleC(const Index2dC & center,SizeT rows,SizeT cols)
Create an 2d range from a center point and a size for rows and cols.
Size is the distance from the center to the edge, so a size of 0 gives a single pixel, and a size of 1 generates a 3 long rectangle in that dimention.

ImageRectangleC(IndexC minRow,IndexC maxRow,IndexC minCol,IndexC maxCol)
Create rectangle from indvidual values.

ImageRectangleC & ReflectUp()
Mirrors the image rectangle along its top edge.
Returns a reference to this rectangle.

ImageRectangleC & ReflectDown()
Mirrors the image rectangle along its bottom edge.
Returns a reference to this rectangle.

ImageRectangleC & ReflectLeft()
Mirrors the image rectangle along its left edge.
Returns a reference to this rectangle.

ImageRectangleC & ReflectRight()
Mirrors the image rectangle along its right edge.
Returns a reference to this rectangle.

#include "Ravl/IndexRange2d.hh"
const IndexRange2dC & SetOrigin(const Index2dC & newOrigin)
Set the origin of the range to 'newOrigin'
Returns a reference to this rectangle.

Index2dC Origin() const
Returns the top-left index of the rectangle.

Index2dC End() const
Returns the bottom-right index of the rectangle.

Index2dC TopRight() const
Returns the top-right index of the rectangle.

Index2dC TopLeft() const
Returns the top-left index of the rectangle.

Index2dC BottomLeft() const
Returns the bottom-left index of the rectangle.

Index2dC BottomRight() const
Returns the bottom-right index of the rectangle.

Index2dC Center() const
Returns the index which is in the middle of the rectangle

IndexC TRow() const
Returns the top row index.

IndexC LCol() const
Returns the left side column index.

IndexC BRow() const
Returns the bottom row index.

IndexC RCol() const
Returns the right side column index.

IndexC & TRow()
Returns the top row index.

IndexC & LCol()
Returns the left side column index.

IndexC & BRow()
Returns the bottom row index.

IndexC & RCol()
Returns the right side column index.

SizeT Rows() const
The number of rows in the rectangle.

SizeT Cols() const
The number of rows in the rectangle.

Index2dC Size() const
Get size of range as an Index2dC.

SizeT Area() const
Returns the area of the image rectangle expressed in number of indexs.

IndexRange2dC Dilate() const
Returns a new rectangle one index larger on each side.

IndexRange2dC Erode() const
Returns an rectangle with each side 1 index closer to the center.

IndexRange2dC Expand(IndexC n) const
Returns an rectangle expanded by 'n' indexs on each side.

IndexRange2dC Shrink(IndexC n) const
Returns a new rectangle which has layer of the width of 'n' indexs removed.

IndexRange2dC & ClipBy(const IndexRange2dC & r)
This index range is clipped to contain at most the index range 'r'.

bool Contains(const IndexRange2dC & oth) const
Returns true if this range contains the subrange 'oth'.

bool Contains(const Index2dC & oth) const
Returns true if this range contains the subrange 'oth'.

const IndexRange2dC & operator +=(const Index2dC & offset)
Shifts the rectangle to the new position.

const IndexRange2dC & operator -=(const Index2dC & offset)
Shifts the rectangle to the new position.

IndexRange2dC operator +(const Index2dC & offset) const
Shifts the rectangle to the new position.

IndexRange2dC operator -(const Index2dC & offset) const
Shifts the rectangle to the new position.

const IndexRangeC & RowRange() const
Access row range.

const IndexRangeC & ColRange() const
Access col range.

IndexRangeC & RowRange()
Access row range.

IndexRangeC & ColRange()
Access col range.

const IndexRangeC & Range1() const
Access row range.

const IndexRangeC & Range2() const
Access col range.

IndexRangeC & Range1()
Access row range.

IndexRangeC & Range2()
Access col range.

void Involve(const Index2dC & index)
Ensures this rectangle contains given index.
This method checks and changes, if necessary, the 2 dimensional range to contain the 'index'.

void Involve(const IndexRange2dC & subrectangle)
Ensures this rectangle contains given sub rectangle.
This method checks and changes, if necessary, the 2 dimensional range to contain the 'subrectangle'.

bool IsValid() const
Returns true if this rectangle contains at least one index.

bool operator ==(const IndexRange2dC & oth) const
Are two ranges equal ?

bool operator !=(const IndexRange2dC & oth) const
Are two ranges unequal ?

IndexRange2dC Rotate180(Index2dC centre = Index2dC (0))
Rotate rectangle 180 degree's around the given center.

bool IsOverlapping(const IndexRange2dC & r) const
Returns true if this range contains at least one common index with the range 'r'.

const IndexRange2dC & operator -=(const IndexRange2dC & sr)
Subtract the 'sr' from this rectangle.
This does TRow() -= sr.TRow(), BRow() -= sr.BRow().....

IndexRange2dC operator -(const IndexRange2dC & sr) const
Subtract the 'sr' from this rectangle.
As operator-=(const IndexRange2dC &sr), but returns the modified rectangle.


Maintainer:Charles Galambos, Created: 24/01/2001, Documentation by CxxDoc: Tue Aug 13 09:59:02 2002