X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fmoof%2Fcml%2Fvector%2Fvector_functions.h;fp=src%2Fmoof%2Fcml%2Fvector%2Fvector_functions.h;h=0000000000000000000000000000000000000000;hb=6b0a0d0efafe34d48ab344fca3b479553bd4e62c;hp=ce92371b94e8dbbd3498cfee7c78826400d342b7;hpb=85783316365181491a3e3c0c63659972477cebba;p=chaz%2Fyoink diff --git a/src/moof/cml/vector/vector_functions.h b/src/moof/cml/vector/vector_functions.h deleted file mode 100644 index ce92371..0000000 --- a/src/moof/cml/vector/vector_functions.h +++ /dev/null @@ -1,73 +0,0 @@ -/* -*- C++ -*- ------------------------------------------------------------ - -Copyright (c) 2007 Jesse Anders and Demian Nave http://cmldev.net/ - -The Configurable Math Library (CML) is distributed under the terms of the -Boost Software License, v1.0 (see cml/LICENSE for details). - - *-----------------------------------------------------------------------*/ -/** @file - * @brief - */ - -#ifndef vector_functions_h -#define vector_functions_h - -namespace cml { - -/** Squared length of a vector. */ -template -inline typename vector::value_type -length_squared(const vector& arg) -{ - return arg.length_squared(); -} - -/** Squared length of a vector expr. */ -template -inline typename XprT::value_type -length_squared(VECXPR_ARG_TYPE arg) -{ - return arg.length_squared(); -} - -/** Length of a vector. */ -template -inline typename vector::value_type -length(const vector& arg) -{ - return arg.length(); -} - -/** Length of a vector expr. */ -template -inline typename XprT::value_type -length(VECXPR_ARG_TYPE arg) -{ - return arg.length(); -} - -/** Normalize a vector. */ -template -inline vector -normalize(const vector& arg) -{ - vector result(arg); - result.normalize(); - return result; -} - -/** Normalize a vector expr. */ -template -inline typename XprT::result_type -normalize(VECXPR_ARG_TYPE arg) -{ - return arg.normalize(); -} - -} // namespace cml - -#endif - -// ------------------------------------------------------------------------- -// vim:ft=cpp