ifw-odp  2.0.0-alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | List of all members
odp::MatrixWrapper Class Reference

This class extends the odp::Matrix class adding the constructor to create the CPL matrix from a buffer data of type double. More...

#include <matrixWrapper.hpp>

Inheritance diagram for odp::MatrixWrapper:
odp::Matrix odp::Error

Public Member Functions

 MatrixWrapper ()
 Class constructor. More...
 
 MatrixWrapper (cpl_size rows, cpl_size cols)
 Class constructor. More...
 
 MatrixWrapper (cpl_size nrows, cpl_size ncols, double *buf)
 Class constructor. More...
 
 MatrixWrapper (const MatrixWrapper &matrix)
 Copy constructor. More...
 
virtual ~MatrixWrapper ()
 Class destructor. More...
 
- Public Member Functions inherited from odp::Matrix
 Matrix ()
 Class constructor. More...
 
 Matrix (const Matrix &matrix)
 Copy constructor. More...
 
 Matrix (cpl_size rows, cpl_size cols)
 Class constructor. More...
 
virtual ~Matrix ()
 Class destructor. More...
 
bool IsMatrix () const
 Check is CPL matrix is not null. More...
 
void GetMatrixPtr (void **data_ptr) const
 Get pointer to CPL matrix data. More...
 
void * GetMatrixPtr () const
 Get pointer to matrix data. More...
 
cpl_matrix * GetCplMatrix () const
 Get CPL matrix pointer. More...
 
void SetCplMatrix (cpl_matrix *matrix)
 Set CPL image. More...
 
cpl_size GetNumCols () const
 Get number of matrix columns. More...
 
cpl_size GetNumRows () const
 Get number of rows. More...
 
void Get (cpl_size row, cpl_size col, double *value) const
 Get value of an element in the matrix. More...
 
double Get (cpl_size row, cpl_size col)
 Get value of an element in the matrix. More...
 
void Set (cpl_size row, cpl_size col, double value)
 Set an element value in the matrix. More...
 
std::string GetSize () const
 Get the size of the matrix in the format [row]x[col]. More...
 
MatrixSqrt (const Matrix &matrix)
 It computes the sqrt of each element in the matrix. More...
 
void Product (const Matrix &, Matrix *product)
 Rows-by-columns product of two matrices. More...
 
void Transpose (Matrix *transpose)
 Create transposed matrix. More...
 
void Solve (const Matrix &, Matrix *solved)
 Solution of linear system . More...
 
void SolveNormal (const Matrix &, Matrix *solved)
 Solution of overdetermined linear equations in a least squares sense. More...
 
void Invert (Matrix *inverse)
 Find a matrix inverse. More...
 
void Append (const Matrix &matrix, int mode)
 Append a matrix to another. More...
 
bool IsDiagonal (const double tolerance)
 Check if the matrix is diagonal. More...
 
bool IsIdentity (const double tolerance)
 Check for identity matrix. More...
 
bool IsZero (const double tolerance)
 Check for zero matrix. More...
 
Matrixoperator+ (const double)
 Overload operator+. More...
 
Matrixoperator+ (const Matrix &)
 Overload operator+. More...
 
Matrixoperator- (const double)
 Overload operator-. More...
 
Matrixoperator- (const Matrix &)
 Overload operator-. More...
 
Matrixoperator/ (const double)
 Overload operator/. More...
 
Matrixoperator/ (const Matrix &)
 Overload operator/. More...
 
Matrixoperator* (const double)
 Overload operator*. More...
 
Matrixoperator* (const Matrix &)
 Overload operator*. More...
 
Matrixoperator+= (const double)
 Overload operator+=. More...
 
Matrixoperator+= (const Matrix &)
 Overload operator+=. More...
 
Matrixoperator-= (const double)
 Overload operator-=. More...
 
Matrixoperator-= (const Matrix &)
 Overload operator-=. More...
 
Matrixoperator/= (const double)
 Overload operator/=. More...
 
Matrixoperator/= (const Matrix &)
 Overload operator/=. More...
 
Matrixoperator*= (const double)
 Overload operator*=. More...
 
Matrixoperator*= (const Matrix &)
 Overload operator*=. More...
 
Matrixoperator= (const Matrix &)
 Overload operator=. More...
 
bool operator== (const Matrix &) const
 Overload operator==. More...
 
bool operator!= (const Matrix &) const
 Overload operator !=. More...
 
- Public Member Functions inherited from odp::Error
 Error ()
 Class constructor. More...
 
virtual ~Error ()
 Class destructor. More...
 
void ResetCplError ()
 Reset CPL error and internal error flag. More...
 
bool CheckCplError () const
 Check if there is an error in CPL. More...
 

Additional Inherited Members

- Protected Member Functions inherited from odp::Error
void AddCplError () const
 Add CPL error to the error stack. More...
 
std::string GetErrorMsg () const
 Get CPL error message. More...
 
- Static Protected Member Functions inherited from odp::Error
static void DumpError (unsigned self, unsigned first, unsigned last)
 Dump current CPL error. More...
 
- Protected Attributes inherited from odp::Matrix
cpl_matrix * m_cpl_matrix
 

Detailed Description

This class extends the odp::Matrix class adding the constructor to create the CPL matrix from a buffer data of type double.

MatrixWrapper - CPL matrix wrapper class holding a buffer data.

Constructor & Destructor Documentation

odp::MatrixWrapper::MatrixWrapper ( )

Class constructor.

Returns
none
odp::MatrixWrapper::MatrixWrapper ( cpl_size  rows,
cpl_size  cols 
)

Class constructor.

Parameters
[in]rowsNumber of rows.
[in]colsNumber of columns.
Returns
none
odp::MatrixWrapper::MatrixWrapper ( cpl_size  nrows,
cpl_size  ncols,
double *  buf 
)

Class constructor.

Parameters
[in]nrowsNumber of rows.
[in]ncolsNumber of columns.
[in]bufPointer to data buffer.
Returns
none

Wrap data buffer around a CPL matrix.

See Also
CPL function: cpl_matrix_wrap
odp::MatrixWrapper::MatrixWrapper ( const MatrixWrapper matrix)

Copy constructor.

Parameters
[in]matrixMatrix to be copied.
Returns
none
odp::MatrixWrapper::~MatrixWrapper ( )
virtual

Class destructor.

Returns
none
See Also
CPL function: cpl_matrix_unwrap

The documentation for this class was generated from the following files: