cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | List of all members
vctDynamicConstMatrixBase< _matrixOwnerType, _elementType >::ConstSubmatrix Class Reference

#include <vctDynamicConstMatrixBase.h>

Public Types

typedef
vctDynamicConstMatrixRef
< value_type > 
Type
 

Detailed Description

template<class _matrixOwnerType, typename _elementType>
class vctDynamicConstMatrixBase< _matrixOwnerType, _elementType >::ConstSubmatrix

Define a ConstSubmatrix class for compatibility with the fixed size matrices. A const submatrix has the same stride as the parent container.

Example:

typedef vctDynamicMatrix<double> MatrixType; MatrixType M(6,6); MatrixType::ConstSubmatrix::Type topLeft(M, 0, 0); MatrixType::ConstSubmatrix::Type bottomRight(M, 3, 3);

Note
There is no straightforward way to define a fixed-size submatrix of a dynamic matrix, because the stride of the dynamic matrix is not known in compilation time. A way to do it is:

vctFixedSizeConstMatrixRef<double, 3, 3, 1, 6> topRight(M, 0, 3); vctFixedSizeConstMatrixRef<double, 3, 3, 1, 6> bottomLeft(M, 3, 0);

Member Typedef Documentation

template<class _matrixOwnerType, typename _elementType>
typedef vctDynamicConstMatrixRef<value_type> vctDynamicConstMatrixBase< _matrixOwnerType, _elementType >::ConstSubmatrix::Type

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