Image Component Library (ICL)
|
Utility class that wraps around a CvMat of type CV_32FC1. More...
#include <OpenCV.h>
Public Member Functions | |
CvMatWrapper (int nrows=0, int ncols=0) | |
Constructor, creates a CvMat with given dimensions. | |
CvMatWrapper (const utils::Size &size) | |
CvMatWrapper (CvMat *other, bool takeOwnerShip=false) | |
Constructor with given source matrix (wrappes around that) | |
CvMat * | get () |
returns the current wrapped CvMat pointer | |
const CvMat * | get () const |
returns the current wrapped CvMat pointer (const) | |
void | setSize (const utils::Size &size) |
adapts the size (if necessary) | |
bool | isNull () const |
returns whether a non-null pointer is wrapped | |
const utils::Size & | getSize () const |
returns the current size | |
T & | operator() (int y, int x) |
index operator | |
const T & | operator() (int y, int x) const |
index operator (const) | |
Private Attributes | |
utils::Size | size |
current size | |
utils::SmartPtrBase< CvMat, CvMatDelOp > | m |
Utility class that wraps around a CvMat of type CV_32FC1.
The wrapper simply handles construction, x/y- indexing and deletion of the internally used CvMat pointer in its destructor.
icl::core::CvMatWrapper< T >::CvMatWrapper | ( | int | nrows = 0 , |
int | ncols = 0 |
||
) | [inline] |
Constructor, creates a CvMat with given dimensions.
icl::core::CvMatWrapper< T >::CvMatWrapper | ( | const utils::Size & | size | ) | [inline] |
icl::core::CvMatWrapper< T >::CvMatWrapper | ( | CvMat * | other, |
bool | takeOwnerShip = false |
||
) | [inline] |
Constructor with given source matrix (wrappes around that)
Optionally, ownership is taken!
CvMat* icl::core::CvMatWrapper< T >::get | ( | void | ) | [inline] |
returns the current wrapped CvMat pointer
const CvMat* icl::core::CvMatWrapper< T >::get | ( | void | ) | const [inline] |
returns the current wrapped CvMat pointer (const)
const utils::Size& icl::core::CvMatWrapper< T >::getSize | ( | ) | const [inline] |
returns the current size
bool icl::core::CvMatWrapper< T >::isNull | ( | ) | const [inline] |
returns whether a non-null pointer is wrapped
T& icl::core::CvMatWrapper< T >::operator() | ( | int | y, |
int | x | ||
) | [inline] |
index operator
const T& icl::core::CvMatWrapper< T >::operator() | ( | int | y, |
int | x | ||
) | const [inline] |
index operator (const)
void icl::core::CvMatWrapper< T >::setSize | ( | const utils::Size & | size | ) | [inline] |
adapts the size (if necessary)
If the size is adapted, the newly created instace's ownership is taken over
utils::SmartPtrBase<CvMat,CvMatDelOp> icl::core::CvMatWrapper< T >::m [private] |
utils::Size icl::core::CvMatWrapper< T >::size [private] |
current size