]>
Commit | Line | Data |
---|---|---|
3a9019d9 FG |
1 | //Copyright (c) 2008-2016 Emil Dotchevski and Reverge Studios, Inc.\r |
2 | \r | |
3 | //Distributed under the Boost Software License, Version 1.0. (See accompanying\r | |
4 | //file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)\r | |
5 | \r | |
6 | #include <boost/qvm/mat_operations.hpp>\r | |
7 | #include "test_qvm_matrix.hpp"\r | |
8 | #include "gold.hpp"\r | |
9 | \r | |
10 | namespace\r | |
11 | {\r | |
12 | template <int Rows,int Cols>\r | |
13 | void\r | |
14 | test()\r | |
15 | {\r | |
16 | using namespace boost::qvm::sfinae;\r | |
17 | test_qvm::matrix<M1,Rows,Cols> x(42,1);\r | |
18 | test_qvm::scalar_multiply_m(x.b,x.a,0.5f);\r | |
19 | x/=2;\r | |
20 | BOOST_QVM_TEST_EQ(x.a,x.b);\r | |
21 | }\r | |
22 | }\r | |
23 | \r | |
24 | int\r | |
25 | main()\r | |
26 | {\r | |
27 | test<1,2>();\r | |
28 | test<2,1>();\r | |
29 | test<2,2>();\r | |
30 | test<1,3>();\r | |
31 | test<3,1>();\r | |
32 | test<3,3>();\r | |
33 | test<1,4>();\r | |
34 | test<4,1>();\r | |
35 | test<4,4>();\r | |
36 | test<1,5>();\r | |
37 | test<5,1>();\r | |
38 | test<5,5>();\r | |
39 | return boost::report_errors();\r | |
40 | }\r |