Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-09-18 09:03:36

0001 #ifndef BOOST_QVM_GEN_MAT_ASSIGN4_HPP_INCLUDED
0002 #define BOOST_QVM_GEN_MAT_ASSIGN4_HPP_INCLUDED
0003 
0004 // Copyright 2008-2024 Emil Dotchevski and Reverge Studios, Inc.
0005 // This file was generated by a program. Do not edit manually.
0006 // Distributed under the Boost Software License, Version 1.0. (See accompanying
0007 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0008 
0009 #include <boost/qvm/config.hpp>
0010 #include <boost/qvm/enable_if.hpp>
0011 #include <boost/qvm/mat_traits.hpp>
0012 
0013 namespace boost { namespace qvm {
0014 
0015 template <class A,class B>
0016 BOOST_QVM_CONSTEXPR BOOST_QVM_INLINE_OPERATIONS
0017 typename enable_if_c<
0018     mat_traits<A>::rows==4 && mat_traits<B>::rows==4 &&
0019     mat_traits<A>::cols==4 && mat_traits<B>::cols==4,
0020     A &>::type
0021 assign( A & a, B const & b )
0022     {
0023     write_mat_element<0,0>(a,mat_traits<B>::template read_element<0,0>(b));
0024     write_mat_element<0,1>(a,mat_traits<B>::template read_element<0,1>(b));
0025     write_mat_element<0,2>(a,mat_traits<B>::template read_element<0,2>(b));
0026     write_mat_element<0,3>(a,mat_traits<B>::template read_element<0,3>(b));
0027     write_mat_element<1,0>(a,mat_traits<B>::template read_element<1,0>(b));
0028     write_mat_element<1,1>(a,mat_traits<B>::template read_element<1,1>(b));
0029     write_mat_element<1,2>(a,mat_traits<B>::template read_element<1,2>(b));
0030     write_mat_element<1,3>(a,mat_traits<B>::template read_element<1,3>(b));
0031     write_mat_element<2,0>(a,mat_traits<B>::template read_element<2,0>(b));
0032     write_mat_element<2,1>(a,mat_traits<B>::template read_element<2,1>(b));
0033     write_mat_element<2,2>(a,mat_traits<B>::template read_element<2,2>(b));
0034     write_mat_element<2,3>(a,mat_traits<B>::template read_element<2,3>(b));
0035     write_mat_element<3,0>(a,mat_traits<B>::template read_element<3,0>(b));
0036     write_mat_element<3,1>(a,mat_traits<B>::template read_element<3,1>(b));
0037     write_mat_element<3,2>(a,mat_traits<B>::template read_element<3,2>(b));
0038     write_mat_element<3,3>(a,mat_traits<B>::template read_element<3,3>(b));
0039     return a;
0040     }
0041 
0042 namespace
0043 sfinae
0044     {
0045     using ::boost::qvm::assign;
0046     }
0047 
0048 namespace
0049 qvm_detail
0050     {
0051     template <int R,int C>
0052     struct assign_mm_defined;
0053 
0054     template <>
0055     struct
0056     assign_mm_defined<4,4>
0057         {
0058         static bool const value=true;
0059         };
0060     }
0061 
0062 template <class A,class B>
0063 BOOST_QVM_CONSTEXPR BOOST_QVM_INLINE_OPERATIONS
0064 typename enable_if_c<
0065     mat_traits<A>::rows==4 && mat_traits<B>::rows==4 &&
0066     mat_traits<A>::cols==1 && mat_traits<B>::cols==1,
0067     A &>::type
0068 assign( A & a, B const & b )
0069     {
0070     write_mat_element<0,0>(a,mat_traits<B>::template read_element<0,0>(b));
0071     write_mat_element<1,0>(a,mat_traits<B>::template read_element<1,0>(b));
0072     write_mat_element<2,0>(a,mat_traits<B>::template read_element<2,0>(b));
0073     write_mat_element<3,0>(a,mat_traits<B>::template read_element<3,0>(b));
0074     return a;
0075     }
0076 
0077 namespace
0078 sfinae
0079     {
0080     using ::boost::qvm::assign;
0081     }
0082 
0083 namespace
0084 qvm_detail
0085     {
0086     template <int R,int C>
0087     struct assign_mm_defined;
0088 
0089     template <>
0090     struct
0091     assign_mm_defined<4,1>
0092         {
0093         static bool const value=true;
0094         };
0095     }
0096 
0097 template <class A,class B>
0098 BOOST_QVM_CONSTEXPR BOOST_QVM_INLINE_OPERATIONS
0099 typename enable_if_c<
0100     mat_traits<A>::rows==1 && mat_traits<B>::rows==1 &&
0101     mat_traits<A>::cols==4 && mat_traits<B>::cols==4,
0102     A &>::type
0103 assign( A & a, B const & b )
0104     {
0105     write_mat_element<0,0>(a,mat_traits<B>::template read_element<0,0>(b));
0106     write_mat_element<0,1>(a,mat_traits<B>::template read_element<0,1>(b));
0107     write_mat_element<0,2>(a,mat_traits<B>::template read_element<0,2>(b));
0108     write_mat_element<0,3>(a,mat_traits<B>::template read_element<0,3>(b));
0109     return a;
0110     }
0111 
0112 namespace
0113 sfinae
0114     {
0115     using ::boost::qvm::assign;
0116     }
0117 
0118 namespace
0119 qvm_detail
0120     {
0121     template <int R,int C>
0122     struct assign_mm_defined;
0123 
0124     template <>
0125     struct
0126     assign_mm_defined<1,4>
0127         {
0128         static bool const value=true;
0129         };
0130     }
0131 
0132 } }
0133 
0134 #endif