#ifndef BOOST_QVM_DEDUCE_QUAT_HPP_INCLUDED #define BOOST_QVM_DEDUCE_QUAT_HPP_INCLUDED // Copyright 2008-2022 Emil Dotchevski and Reverge Studios, Inc. // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #include #include #include namespace boost { namespace qvm { template struct quat; namespace qvm_detail { template ::scalar_type> struct deduce_q_default { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef quat::scalar_type> type; }; template struct deduce_q_default { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef Q type; }; } template ::scalar_type> struct deduce_quat { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef typename qvm_detail::deduce_q_default::type type; }; namespace qvm_detail { template ::value, bool IsScalarB=is_scalar::value> struct deduce_q2_default { typedef quat type; }; template struct deduce_q2_default { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef Q type; }; template struct deduce_q2_default { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef typename deduce_quat::type type; }; template struct deduce_q2_default { BOOST_QVM_STATIC_ASSERT(is_quat::value); typedef typename deduce_quat::type type; }; } template ::type,typename scalar::type>::type> struct deduce_quat2 { BOOST_QVM_STATIC_ASSERT(is_quat::value || is_quat::value); typedef typename qvm_detail::deduce_q2_default::type type; }; } } #endif