qua: isnan, isinf, isfinite

This commit is contained in:
BlackMATov
2021-01-26 01:54:20 +07:00
parent 1acbb0dffb
commit 341e3dd0a3
2 changed files with 28 additions and 0 deletions

View File

@@ -145,5 +145,27 @@ namespace vmath_hpp
}
}
//
// Common Functions
//
namespace vmath_hpp
{
template < typename T >
[[nodiscard]] vec<bool, 4> isnan(const qua<T>& xs) {
return isnan(vec{xs});
}
template < typename T >
[[nodiscard]] vec<bool, 4> isinf(const qua<T>& xs) {
return isinf(vec{xs});
}
template < typename T >
[[nodiscard]] vec<bool, 4> isfinite(const qua<T>& xs) {
return isfinite(vec{xs});
}
}
}
}