libwallaby  v24
The wallaby standard library
types.hpp
Go to the documentation of this file.
1 /*
2  * types.hpp
3  *
4  * Created on: Nov 13, 2015
5  * Author: Joshua Southerland
6  */
7 
8 #ifndef INCLUDE_WALLABY_TYPES_HPP_
9 #define INCLUDE_WALLABY_TYPES_HPP_
10 
11 
12 template<typename T>
13 struct Vec3
14 {
15  Vec3();
16  Vec3(const T &x, const T &y, const T &z);
17 
18  T x;
19  T y;
20  T z;
21 };
22 
23 template<typename T>
25  : x(0.0f),
26  y(0.0f),
27  z(0.0f)
28 {
29 }
30 
31 
32 template<typename T>
33 Vec3<T>::Vec3(const T &x, const T &y, const T &z)
34  : x(x),
35  y(y),
36  z(z)
37 {
38 }
39 
42 typedef Vec3<int> Vec3d;
44 
45 
46 
47 #endif /* INCLUDE_WALLABY_TYPES_HPP_ */
T z
Definition: types.hpp:20
T x
Definition: types.hpp:18
Vec3()
Definition: types.hpp:24
Definition: types.hpp:13
Vec3< double > Vec3lf
Definition: types.hpp:41
T y
Definition: types.hpp:19
Vec3< float > Vec3f
Definition: types.hpp:40
Vec3< unsigned > Vec3u
Definition: types.hpp:43
Vec3< int > Vec3d
Definition: types.hpp:42