a template class to store a 2D array of m_data More...
#include <MWAWPictBitmap.hxx>
Public Member Functions | |
MWAWPictBitmapContainer (MWAWVec2i const &sz) | |
constructor given size | |
virtual | ~MWAWPictBitmapContainer () |
destructor | |
bool | ok () const |
returns ok, if the m_data is allocated | |
int | cmp (MWAWPictBitmapContainer< T > const &orig) const |
a comparison operator | |
MWAWVec2i const & | size () const |
return the array size | |
int | numRows () const |
gets the number of row | |
int | numColumns () const |
gets the number of column | |
T const & | get (int i, int j) const |
accessor of a cell m_data | |
T const * | getRow (int j) const |
accessor of a row m_data | |
void | set (int i, int j, T const &v) |
sets a cell m_data | |
template<class U > | |
void | setRow (int j, U const *val) |
sets a line of m_data | |
template<class U > | |
void | setColumn (int i, U const *val) |
sets a column of m_data | |
Protected Attributes | |
MWAWVec2i | m_size |
the size | |
T * | m_data |
the m_data placed by row ie. d_00, d_10, ... , d_{X-1}0, .. | |
Private Member Functions | |
MWAWPictBitmapContainer (MWAWPictBitmapContainer const &orig)=delete | |
MWAWPictBitmapContainer & | operator= (MWAWPictBitmapContainer const &orig)=delete |
a template class to store a 2D array of m_data
|
inlineexplicit |
constructor given size
|
inlinevirtual |
destructor
|
privatedelete |
|
inline |
a comparison operator
|
inline |
accessor of a cell m_data
Referenced by MWAWPictBitmapBW::get(), and MWAWPictBitmapIndexed::get().
|
inline |
accessor of a row m_data
Referenced by MWAWPictBitmapInternal::getBMPData(), MWAWPictBitmapInternal::getPBMData(), MWAWPictBitmapInternal::getPPMData(), MWAWPictBitmapBW::getRow(), and MWAWPictBitmapIndexed::getRow().
|
inline |
gets the number of column
Referenced by MWAWPictBitmapBW::numColumns(), and MWAWPictBitmapIndexed::numColumns().
|
inline |
gets the number of row
Referenced by MWAWPictBitmapBW::numRows(), and MWAWPictBitmapIndexed::numRows().
|
inline |
returns ok, if the m_data is allocated
Referenced by MWAWPictBitmapBW::valid(), and MWAWPictBitmapIndexed::valid().
|
privatedelete |
|
inline |
sets a cell m_data
Referenced by MWAWPictBitmapBW::set(), and MWAWPictBitmapIndexed::set().
|
inline |
sets a column of m_data
Referenced by MWAWPictBitmapBW::setColumn(), and MWAWPictBitmapIndexed::setColumn().
|
inline |
sets a line of m_data
Referenced by MWAWPictBitmapBW::setRow(), and MWAWPictBitmapIndexed::setRow().
|
inline |
return the array size
Referenced by MWAWPictBitmapBW::getAverageColor(), MWAWPictBitmapIndexed::getAverageColor(), MWAWPictBitmapColor::getAverageColor(), MWAWPictBitmapInternal::getBMPData(), MWAWPictBitmapInternal::getPBMData(), MWAWPictBitmapInternal::getPPMData(), MWAWPictBitmapBW::size(), and MWAWPictBitmapIndexed::size().
|
protected |
the m_data placed by row ie. d_00, d_10, ... , d_{X-1}0, ..
Referenced by MWAWPictBitmapContainer< T >::cmp(), MWAWPictBitmapContainer< T >::get(), MWAWPictBitmapContainer< T >::getRow(), MWAWPictBitmapContainer< T >::MWAWPictBitmapContainer(), MWAWPictBitmapContainer< T >::ok(), MWAWPictBitmapContainer< T >::set(), MWAWPictBitmapContainer< T >::setColumn(), MWAWPictBitmapContainer< T >::setRow(), and MWAWPictBitmapContainer< T >::~MWAWPictBitmapContainer().
|
protected |
the size
Referenced by MWAWPictBitmapContainer< T >::cmp(), MWAWPictBitmapContainer< T >::get(), MWAWPictBitmapContainer< T >::getRow(), MWAWPictBitmapContainer< T >::MWAWPictBitmapContainer(), MWAWPictBitmapContainer< T >::numColumns(), MWAWPictBitmapContainer< T >::numRows(), MWAWPictBitmapContainer< T >::set(), MWAWPictBitmapContainer< T >::setColumn(), MWAWPictBitmapContainer< T >::setRow(), and MWAWPictBitmapContainer< T >::size().