texture.hpp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /// @ref gtx_texture
  2. /// @file glm/gtx/texture.hpp
  3. ///
  4. /// @see core (dependence)
  5. ///
  6. /// @defgroup gtx_texture GLM_GTX_texture
  7. /// @ingroup gtx
  8. ///
  9. /// Include <glm/gtx/texture.hpp> to use the features of this extension.
  10. ///
  11. /// Wrapping mode of texture coordinates.
  12. #pragma once
  13. // Dependency:
  14. #include "../glm.hpp"
  15. #include "../gtc/integer.hpp"
  16. #include "../gtx/component_wise.hpp"
  17. #ifndef GLM_ENABLE_EXPERIMENTAL
  18. # error "GLM: GLM_GTX_texture 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."
  19. #elif GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
  20. # pragma message("GLM: GLM_GTX_texture extension included")
  21. #endif
  22. namespace glm
  23. {
  24. /// @addtogroup gtx_texture
  25. /// @{
  26. /// Compute the number of mipmaps levels necessary to create a mipmap complete texture
  27. ///
  28. /// @param Extent Extent of the texture base level mipmap
  29. /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
  30. /// @tparam T Floating-point or signed integer scalar types
  31. /// @tparam Q Value from qualifier enum
  32. template <length_t L, typename T, qualifier Q>
  33. T levels(vec<L, T, Q> const& Extent);
  34. /// @}
  35. }// namespace glm
  36. #include "texture.inl"