cisst-saw
Loading...
Searching...
No Matches
vctMatrixRotation2.h
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/* ex: set filetype=cpp softtabstop=4 shiftwidth=4 tabstop=4 cindent expandtab: */
3
4/*
5 Author(s): Anton Deguet
6 Created on: 2005-02-23
7
8 (C) Copyright 2005-2018 Johns Hopkins University (JHU), All Rights Reserved.
9
10--- begin cisst license - do not edit ---
11
12This software is provided "as is" under an open source license, with
13no warranty. The complete license can be found in license.txt and
14http://www.cisst.org/cisst/license.txt.
15
16--- end cisst license ---
17*/
18
19#pragma once
20#ifndef _vctMatrixRotation2_h
21#define _vctMatrixRotation2_h
22
27
30
32
47template <class _elementType>
48class vctMatrixRotation2: public vctMatrixRotation2Base<vctFixedSizeMatrix<_elementType, 2, 2> >
49{
50public:
51 /* no need to document, inherit doxygen documentation from base class */
53 enum {ROWS = 2, COLS = 2};
54 enum {DIMENSION = 2};
58
61
64 BaseType()
65 {}
66
67 inline vctMatrixRotation2(const ThisType & other):
68 BaseType(other)
69 {}
70
71 inline vctMatrixRotation2(const BaseType & other):
72 BaseType(other)
73 {}
74
81 inline ThisType & operator = (const ContainerType & other) {
82 return reinterpret_cast<ThisType &>(this->Assign(other));
83 }
84
85 inline ThisType & operator = (const ThisType & other) {
86 return reinterpret_cast<ThisType &>(this->Assign(other));
87 }
88
89 inline ThisType & operator = (const BaseType & other) {
90 return reinterpret_cast<ThisType &>(this->Assign(other));
91 }
92
93 /* documented in base class */
94 inline vctMatrixRotation2(const value_type & element00, const value_type & element01,
95 const value_type & element10, const value_type & element11)
96 CISST_THROW(std::runtime_error):
97 BaseType(element00, element01,
98 element10, element11)
99 {}
100
101 template <stride_type __stride1, class __dataPtrType1,
102 stride_type __stride2, class __dataPtrType2>
105 bool vectorsAreColumns = true)
106 CISST_THROW(std::runtime_error):
107 BaseType(v1, v2, vectorsAreColumns)
108 {}
109
110 template <class __vectorOwnerType1,
111 class __vectorOwnerType2>
114 bool vectorsAreColumns = true)
115 CISST_THROW(std::runtime_error):
116 BaseType(v1, v2, vectorsAreColumns)
117 {}
118
119 inline vctMatrixRotation2(const vctAngleRotation2 & angleRotation)
120 CISST_THROW(std::runtime_error):
121 BaseType(angleRotation)
122 {}
123
124 inline vctMatrixRotation2(const value_type & element00, const value_type & element01,
125 const value_type & element10, const value_type & element11,
126 bool normalizeInput):
127 BaseType(element00, element01,
128 element10, element11,
129 normalizeInput)
130 {}
131
132 template <stride_type __stride1, class __dataPtrType1,
133 stride_type __stride2, class __dataPtrType2>
136 bool vectorsAreColumns, bool normalizeInput):
137
138 BaseType(v1, v2, vectorsAreColumns, normalizeInput)
139 {}
140
141 template <class __vectorOwnerType1,
142 class __vectorOwnerType2>
145 bool vectorsAreColumns, bool normalizeInput):
146 BaseType(v1, v2, vectorsAreColumns, normalizeInput)
147 {}
148
149 inline vctMatrixRotation2(const vctAngleRotation2 & angleRotation,
150 bool normalizeInput):
151 BaseType(angleRotation, normalizeInput)
152 {}
153
164 template <stride_type __rowStride, stride_type __colStride, class __dataPtrType>
165 explicit inline
169
170};
171
172
173#endif // _vctMatrixRotation2_h
A collection of useful information about the C++ basic types, represented in a generic programming wa...
Definition cmnTypeTraits.h:155
Define a rotation based on an angle for a space of dimension 2.
Definition vctAngleRotation2.h:45
Definition vctForwardDeclarations.h:119
A template for a fixed length vector with fixed spacing in memory.
Definition vctFixedSizeConstVectorBase.h:108
A template for a fixed size matrix with fixed spacings in memory.
Definition vctFixedSizeMatrixBase.h:60
ThisType & Assign(const vctFixedSizeConstMatrixBase< _rows, _cols, __rowStride, __colStride, __elementType, __dataPtrType > &other)
Definition vctFixedSizeMatrixBase.h:475
vctFixedSizeMatrix()
Definition vctFixedSizeMatrix.h:78
vctMatrixRotation2Base()
Definition vctMatrixRotation2Base.h:102
@ COLS
Definition vctMatrixRotation2.h:53
@ ROWS
Definition vctMatrixRotation2.h:53
vctMatrixRotation2(const vctDynamicConstVectorBase< __vectorOwnerType1, value_type > &v1, const vctDynamicConstVectorBase< __vectorOwnerType2, value_type > &v2, bool vectorsAreColumns=true) CISST_THROW(std
Definition vctMatrixRotation2.h:112
VCT_CONTAINER_TRAITS_TYPEDEFS(_elementType)
vctMatrixRotation2(const vctFixedSizeConstVectorBase< DIMENSION, __stride1, value_type, __dataPtrType1 > &v1, const vctFixedSizeConstVectorBase< DIMENSION, __stride2, value_type, __dataPtrType2 > &v2, bool vectorsAreColumns=true) CISST_THROW(std
Definition vctMatrixRotation2.h:103
vctMatrixRotation2(const vctFixedSizeConstVectorBase< DIMENSION, __stride1, value_type, __dataPtrType1 > &v1, const vctFixedSizeConstVectorBase< DIMENSION, __stride2, value_type, __dataPtrType2 > &v2, bool vectorsAreColumns, bool normalizeInput)
Definition vctMatrixRotation2.h:134
vctMatrixRotation2(const vctDynamicConstVectorBase< __vectorOwnerType1, value_type > &v1, const vctDynamicConstVectorBase< __vectorOwnerType2, value_type > &v2, bool vectorsAreColumns, bool normalizeInput)
Definition vctMatrixRotation2.h:143
vctMatrixRotation2< value_type > ThisType
Definition vctMatrixRotation2.h:57
ThisType & operator=(const ContainerType &other)
Definition vctMatrixRotation2.h:81
vctMatrixRotation2(const BaseType &other)
Definition vctMatrixRotation2.h:71
vctMatrixRotation2Base< ContainerType > BaseType
Definition vctMatrixRotation2.h:56
vctMatrixRotation2(const vctFixedSizeMatrixBase< ROWS, COLS, __rowStride, __colStride, value_type, __dataPtrType > &matrix)
Definition vctMatrixRotation2.h:166
vctMatrixRotation2()
Definition vctMatrixRotation2.h:63
vctMatrixRotation2(const ThisType &other)
Definition vctMatrixRotation2.h:67
vctMatrixRotation2(const value_type &element00, const value_type &element01, const value_type &element10, const value_type &element11) CISST_THROW(std
Definition vctMatrixRotation2.h:94
@ DIMENSION
Definition vctMatrixRotation2.h:54
vctMatrixRotation2(const vctAngleRotation2 &angleRotation, bool normalizeInput)
Definition vctMatrixRotation2.h:149
cmnTypeTraits< value_type > TypeTraits
Definition vctMatrixRotation2.h:60
vctFixedSizeMatrix< value_type, ROWS, COLS > ContainerType
Definition vctMatrixRotation2.h:55
vctMatrixRotation2(const vctAngleRotation2 &angleRotation) CISST_THROW(std
Definition vctMatrixRotation2.h:119
vctMatrixRotation2(const value_type &element00, const value_type &element01, const value_type &element10, const value_type &element11, bool normalizeInput)
Definition vctMatrixRotation2.h:124
#define CISST_THROW(exceptionParameter)
Somewhat portable compilation warning message. This works with very recent versions of gcc (4....
Definition cmnPortability.h:559
STL namespace.
Macros to export the symbols of cisstVector (in a Dll).
Declaration of vctFixedSizeMatrix.
Declaration of vctMatrixRotation2Base.