handed_coordinate_space.hpp 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /// @ref gtx_handed_coordinate_space
  2. /// @file glm/gtx/handed_coordinate_space.hpp
  3. ///
  4. /// @see core (dependence)
  5. ///
  6. /// @defgroup gtx_handed_coordinate_space GLM_GTX_handed_coordinate_space
  7. /// @ingroup gtx
  8. ///
  9. /// Include <glm/gtx/handed_coordinate_system.hpp> to use the features of this extension.
  10. ///
  11. /// To know if a set of three basis vectors defines a right or left-handed coordinate system.
  12. #pragma once
  13. // Dependency:
  14. #include "../glm.hpp"
  15. #ifndef GLM_ENABLE_EXPERIMENTAL
  16. # error "GLM: GLM_GTX_handed_coordinate_space is an experimental extension and may change in the future. Use #define GLM_ENABLE_EXPERIMENTAL before including it, if you really want to use it."
  17. #endif
  18. #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
  19. # pragma message("GLM: GLM_GTX_handed_coordinate_space extension included")
  20. #endif
  21. namespace glm
  22. {
  23. /// @addtogroup gtx_handed_coordinate_space
  24. /// @{
  25. //! Return if a trihedron right handed or not.
  26. //! From GLM_GTX_handed_coordinate_space extension.
  27. template<typename T, qualifier Q>
  28. GLM_FUNC_DECL bool rightHanded(
  29. vec<3, T, Q> const& tangent,
  30. vec<3, T, Q> const& binormal,
  31. vec<3, T, Q> const& normal);
  32. //! Return if a trihedron left handed or not.
  33. //! From GLM_GTX_handed_coordinate_space extension.
  34. template<typename T, qualifier Q>
  35. GLM_FUNC_DECL bool leftHanded(
  36. vec<3, T, Q> const& tangent,
  37. vec<3, T, Q> const& binormal,
  38. vec<3, T, Q> const& normal);
  39. /// @}
  40. }// namespace glm
  41. #include "handed_coordinate_space.inl"