From e62817b8252974b8a98393275874ee303840bf13 Mon Sep 17 00:00:00 2001 From: LaG1924 <12997935+LaG1924@users.noreply.github.com> Date: Fri, 12 May 2017 18:49:50 +0500 Subject: 2017-05-12 --- .../include/glm/detail/func_vector_relational.hpp | 111 +++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 depedencies/include/glm/detail/func_vector_relational.hpp (limited to 'depedencies/include/glm/detail/func_vector_relational.hpp') diff --git a/depedencies/include/glm/detail/func_vector_relational.hpp b/depedencies/include/glm/detail/func_vector_relational.hpp new file mode 100644 index 0000000..ec0f68a --- /dev/null +++ b/depedencies/include/glm/detail/func_vector_relational.hpp @@ -0,0 +1,111 @@ +/// @ref core +/// @file glm/detail/func_vector_relational.hpp +/// +/// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions +/// +/// @defgroup core_func_vector_relational Vector Relational Functions +/// @ingroup core +/// +/// Relational and equality operators (<, <=, >, >=, ==, !=) are defined to +/// operate on scalars and produce scalar Boolean results. For vector results, +/// use the following built-in functions. +/// +/// In all cases, the sizes of all the input and return vectors for any particular +/// call must match. + +#pragma once + +#include "precision.hpp" +#include "setup.hpp" + +namespace glm +{ + /// @addtogroup core_func_vector_relational + /// @{ + + /// Returns the component-wise comparison result of x < y. + /// + /// @tparam vecType Floating-point or integer vector types. + /// + /// @see GLSL lessThan man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType lessThan(vecType const & x, vecType const & y); + + /// Returns the component-wise comparison of result x <= y. + /// + /// @tparam vecType Floating-point or integer vector types. + /// + /// @see GLSL lessThanEqual man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType lessThanEqual(vecType const & x, vecType const & y); + + /// Returns the component-wise comparison of result x > y. + /// + /// @tparam vecType Floating-point or integer vector types. + /// + /// @see GLSL greaterThan man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType greaterThan(vecType const & x, vecType const & y); + + /// Returns the component-wise comparison of result x >= y. + /// + /// @tparam vecType Floating-point or integer vector types. + /// + /// @see GLSL greaterThanEqual man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType greaterThanEqual(vecType const & x, vecType const & y); + + /// Returns the component-wise comparison of result x == y. + /// + /// @tparam vecType Floating-point, integer or boolean vector types. + /// + /// @see GLSL equal man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType equal(vecType const & x, vecType const & y); + + /// Returns the component-wise comparison of result x != y. + /// + /// @tparam vecType Floating-point, integer or boolean vector types. + /// + /// @see GLSL notEqual man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType notEqual(vecType const & x, vecType const & y); + + /// Returns true if any component of x is true. + /// + /// @tparam vecType Boolean vector types. + /// + /// @see GLSL any man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL bool any(vecType const & v); + + /// Returns true if all components of x are true. + /// + /// @tparam vecType Boolean vector types. + /// + /// @see GLSL all man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL bool all(vecType const & v); + + /// Returns the component-wise logical complement of x. + /// /!\ Because of language incompatibilities between C++ and GLSL, GLM defines the function not but not_ instead. + /// + /// @tparam vecType Boolean vector types. + /// + /// @see GLSL not man page + /// @see GLSL 4.20.8 specification, section 8.7 Vector Relational Functions + template class vecType> + GLM_FUNC_DECL vecType not_(vecType const & v); + + /// @} +}//namespace glm + +#include "func_vector_relational.inl" -- cgit v1.2.3