Wavelet and Image class library  1.3.2
Public Member Functions | Protected Attributes
ImageVector Class Reference

#include <ImageVector.hh>

Inheritance diagram for ImageVector:
Inheritance graph
[legend]
Collaboration diagram for ImageVector:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ImageVector (ImageArray< coeff > *ar)
virtual ~ImageVector (void)
virtual bool sanity (void)
virtual void update (void)
virtual void go (int root)
virtual coeff at (int pos)=0
virtual void to (int pos, coeff val)=0
virtual int size (void)=0
coeff weight (void)

Protected Attributes

ImageArray< coeff > * m_array
int m_xsize
int m_ysize

Detailed Description

Pseudo-vector (abstract) for use with two-dimensional objects, like images. Provide a two-dimensional array's rows and columns as vectors with array addressing.

Definition at line 26 of file ImageVector.hh.


Constructor & Destructor Documentation

Constructor. Sets the array reference.

virtual ImageVector::~ImageVector ( void  ) [inline, virtual]

Destructor. Does nothing.

Definition at line 34 of file ImageVector.hh.


Member Function Documentation

virtual coeff ImageVector::at ( int  pos) [pure virtual]

Return a value (abstract). The value is taken from the vector's position {pos}.

Parameters:
posthe position
Returns:
the value at that position

Implements ReferenceVector.

Implemented in FullVector, ColumnVector, and RowVector.

virtual void ImageVector::go ( int  root) [virtual]

Set new root. Depending of what concrete instance is the current row or col will be set.

Exceptions:
invalid_argumenta negative value was given for the new root
Parameters:
rootthe new root

Implements ReferenceVector.

Reimplemented in FullVector, ColumnVector, and RowVector.

virtual bool ImageVector::sanity ( void  ) [virtual]

Checks integrity. If the array's dimensions have been changed (resize operation) {false} will be returned.

Implements ReferenceVector.

virtual int ImageVector::size ( void  ) [pure virtual]

Return the vector's size (abstract). Depending on the concrete instance we will get the associated array's number of rows or cols.

Returns:
the vector's size

Implements ReferenceVector.

Implemented in FullVector, ColumnVector, and RowVector.

virtual void ImageVector::to ( int  pos,
coeff  val 
) [pure virtual]

Assign a value (abstract). A new value {val} is assigned to the vector's position {pos}.

Parameters:
posthe position
valthe new value

Implements ReferenceVector.

Implemented in FullVector, ColumnVector, and RowVector.

virtual void ImageVector::update ( void  ) [virtual]

Updates the vector's settings. This is necessary each time after the array has been resized.

Implements ReferenceVector.

Reimplemented in ColumnVector, FullVector, and RowVector.

Return the sum of the vector's absolute values

Returns:
the sum of the vector's absolute values

Member Data Documentation

A reference to encapsuled array. Rows and cols will be taken from this array.

Definition at line 80 of file ImageVector.hh.

int ImageVector::m_xsize [protected]

The encapsulated array's cols.

Definition at line 82 of file ImageVector.hh.

Referenced by FullVector::FullVector().

int ImageVector::m_ysize [protected]

The encapsulated array's rows .

Definition at line 84 of file ImageVector.hh.

Referenced by FullVector::FullVector().


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines