PSMoveService
type_mat3x4.hpp
Go to the documentation of this file.
1 
29 #ifndef glm_core_type_mat3x4
30 #define glm_core_type_mat3x4
31 
32 #include "type_mat.hpp"
33 
34 namespace glm{
35 namespace detail
36 {
37  template <typename T> struct tvec1;
38  template <typename T> struct tvec2;
39  template <typename T> struct tvec3;
40  template <typename T> struct tvec4;
41  template <typename T> struct tmat2x2;
42  template <typename T> struct tmat2x3;
43  template <typename T> struct tmat2x4;
44  template <typename T> struct tmat3x2;
45  template <typename T> struct tmat3x3;
46  template <typename T> struct tmat3x4;
47  template <typename T> struct tmat4x2;
48  template <typename T> struct tmat4x3;
49  template <typename T> struct tmat4x4;
50 
51  // \brief Template for 3 columns and 4 rows matrix of floating-point numbers.
52  // \ingroup core_template
53  template <typename T>
54  struct tmat3x4
55  {
56  enum ctor{null};
57  typedef T value_type;
58  typedef std::size_t size_type;
59  typedef tvec4<T> col_type;
60  typedef tvec3<T> row_type;
61  GLM_FUNC_DECL size_type length() const;
62  static GLM_FUNC_DECL size_type col_size();
63  static GLM_FUNC_DECL size_type row_size();
64 
65  typedef tmat3x4<T> type;
66  typedef tmat4x3<T> transpose_type;
67 
68  private:
69  // Data
70  col_type value[3];
71 
72  public:
73  // Constructors
74  GLM_FUNC_DECL tmat3x4();
75  GLM_FUNC_DECL tmat3x4(tmat3x4 const & m);
76 
77  GLM_FUNC_DECL explicit tmat3x4(
78  ctor Null);
79  GLM_FUNC_DECL explicit tmat3x4(
80  value_type const & s);
81  GLM_FUNC_DECL explicit tmat3x4(
82  value_type const & x0, value_type const & y0, value_type const & z0, value_type const & w0,
83  value_type const & x1, value_type const & y1, value_type const & z1, value_type const & w1,
84  value_type const & x2, value_type const & y2, value_type const & z2, value_type const & w2);
85  GLM_FUNC_DECL explicit tmat3x4(
86  col_type const & v0,
87  col_type const & v1,
88  col_type const & v2);
89 
91  // Conversions
92  template <typename U>
93  GLM_FUNC_DECL explicit tmat3x4(
94  U const & x);
95 
96  template
97  <
98  typename X1, typename Y1, typename Z1, typename W1,
99  typename X2, typename Y2, typename Z2, typename W2,
100  typename X3, typename Y3, typename Z3, typename W3
101  >
102  GLM_FUNC_DECL explicit tmat3x4(
103  X1 const & x1, Y1 const & y1, Z1 const & z1, W1 const & w1,
104  X2 const & x2, Y2 const & y2, Z2 const & z2, W2 const & w2,
105  X3 const & x3, Y3 const & y3, Z3 const & z3, W3 const & w3);
106 
107  template <typename V1, typename V2, typename V3>
108  GLM_FUNC_DECL explicit tmat3x4(
109  tvec4<V1> const & v1,
110  tvec4<V2> const & v2,
111  tvec4<V3> const & v3);
112 
113  // Matrix conversion
114  template <typename U>
115  GLM_FUNC_DECL explicit tmat3x4(tmat3x4<U> const & m);
116 
117  GLM_FUNC_DECL explicit tmat3x4(tmat2x2<T> const & x);
118  GLM_FUNC_DECL explicit tmat3x4(tmat3x3<T> const & x);
119  GLM_FUNC_DECL explicit tmat3x4(tmat4x4<T> const & x);
120  GLM_FUNC_DECL explicit tmat3x4(tmat2x3<T> const & x);
121  GLM_FUNC_DECL explicit tmat3x4(tmat3x2<T> const & x);
122  GLM_FUNC_DECL explicit tmat3x4(tmat2x4<T> const & x);
123  GLM_FUNC_DECL explicit tmat3x4(tmat4x2<T> const & x);
124  GLM_FUNC_DECL explicit tmat3x4(tmat4x3<T> const & x);
125 
126  // Accesses
127  col_type & operator[](size_type i);
128  col_type const & operator[](size_type i) const;
129 
130  // Unary updatable operators
131  GLM_FUNC_DECL tmat3x4<T> & operator= (tmat3x4<T> const & m);
132  template <typename U>
133  GLM_FUNC_DECL tmat3x4<T> & operator= (tmat3x4<U> const & m);
134  template <typename U>
135  GLM_FUNC_DECL tmat3x4<T> & operator+= (U const & s);
136  template <typename U>
137  GLM_FUNC_DECL tmat3x4<T> & operator+= (tmat3x4<U> const & m);
138  template <typename U>
139  GLM_FUNC_DECL tmat3x4<T> & operator-= (U const & s);
140  template <typename U>
141  GLM_FUNC_DECL tmat3x4<T> & operator-= (tmat3x4<U> const & m);
142  template <typename U>
143  GLM_FUNC_DECL tmat3x4<T> & operator*= (U const & s);
144  template <typename U>
145  GLM_FUNC_DECL tmat3x4<T> & operator*= (tmat3x4<U> const & m);
146  template <typename U>
147  GLM_FUNC_DECL tmat3x4<T> & operator/= (U const & s);
148 
149  GLM_FUNC_DECL tmat3x4<T> & operator++ ();
150  GLM_FUNC_DECL tmat3x4<T> & operator-- ();
151  };
152 
153  // Binary operators
154  template <typename T>
155  tmat3x4<T> operator+ (
156  tmat3x4<T> const & m,
157  typename tmat3x4<T>::value_type const & s);
158 
159  template <typename T>
160  tmat3x4<T> operator+ (
161  tmat3x4<T> const & m1,
162  tmat3x4<T> const & m2);
163 
164  template <typename T>
165  tmat3x4<T> operator- (
166  tmat3x4<T> const & m,
167  typename tmat3x4<T>::value_type const & s);
168 
169  template <typename T>
170  tmat3x4<T> operator- (
171  tmat3x4<T> const & m1,
172  tmat3x4<T> const & m2);
173 
174  template <typename T>
175  tmat3x4<T> operator* (
176  tmat3x4<T> const & m,
177  typename tmat3x4<T>::value_type const & s);
178 
179  template <typename T>
180  tmat3x4<T> operator* (
181  typename tmat3x4<T>::value_type const & s,
182  tmat3x4<T> const & m);
183 
184  template <typename T>
185  typename tmat3x4<T>::col_type operator* (
186  tmat3x4<T> const & m,
187  typename tmat3x4<T>::row_type const & v);
188 
189  template <typename T>
190  typename tmat3x4<T>::row_type operator* (
191  typename tmat3x4<T>::col_type const & v,
192  tmat3x4<T> const & m);
193 
194  template <typename T>
195  tmat4x4<T> operator* (
196  tmat3x4<T> const & m1,
197  tmat4x3<T> const & m2);
198 
199  template <typename T>
200  tmat2x4<T> operator* (
201  tmat3x4<T> const & m1,
202  tmat2x3<T> const & m2);
203 
204  template <typename T>
205  tmat3x4<T> operator* (
206  tmat3x4<T> const & m1,
207  tmat3x3<T> const & m2);
208 
209  template <typename T>
210  tmat3x4<T> operator/ (
211  tmat3x4<T> const & m,
212  typename tmat3x4<T>::value_type const & s);
213 
214  template <typename T>
215  tmat3x4<T> operator/ (
216  typename tmat3x4<T>::value_type const & s,
217  tmat3x4<T> const & m);
218 
219  // Unary constant operators
220  template <typename T>
221  tmat3x4<T> const operator- (
222  tmat3x4<T> const & m);
223 
224  template <typename T>
225  tmat3x4<T> const operator-- (
226  tmat3x4<T> const & m,
227  int);
228 
229  template <typename T>
230  tmat3x4<T> const operator++ (
231  tmat3x4<T> const & m,
232  int);
233 
234 }//namespace detail
235 
238 
245 
252 
259 
261 }//namespace glm
262 
263 #ifndef GLM_EXTERNAL_TEMPLATE
264 #include "type_mat3x4.inl"
265 #endif
266 
267 #endif //glm_core_type_mat3x4
Definition: _detail.hpp:38
detail::tmat3x4< mediump_float > mediump_mat3x4
3 columns of 4 components matrix of medium precision floating-point numbers.
Definition: type_mat3x4.hpp:251
detail::tmat3x4< lowp_float > lowp_mat3x4
3 columns of 4 components matrix of low precision floating-point numbers.
Definition: type_mat3x4.hpp:244
OpenGL Mathematics (glm.g-truc.net)
detail::tmat3x4< highp_float > highp_mat3x4
3 columns of 4 components matrix of high precision floating-point numbers.
Definition: type_mat3x4.hpp:258
OpenGL Mathematics (glm.g-truc.net)
Definition: type_mat2x2.hpp:46