diff --git a/glm/gtc/half_float.hpp b/glm/gtc/half_float.hpp index 9f99c480..bc638574 100644 --- a/glm/gtc/half_float.hpp +++ b/glm/gtc/half_float.hpp @@ -353,67 +353,67 @@ namespace detail /// @{ /// Type for half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::thalf half; /// Vector of 2 half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tvec2 hvec2; /// Vector of 3 half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tvec3 hvec3; /// Vector of 4 half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tvec4 hvec4; /// 2 * 2 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat2x2 hmat2; /// 3 * 3 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat3x3 hmat3; /// 4 * 4 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat4x4 hmat4; /// 2 * 2 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat2x2 hmat2x2; /// 2 * 3 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat2x3 hmat2x3; /// 2 * 4 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat2x4 hmat2x4; /// 3 * 2 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat3x2 hmat3x2; /// 3 * 3 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat3x3 hmat3x3; /// 3 * 4 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat3x4 hmat3x4; /// 4 * 2 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat4x2 hmat4x2; /// 4 * 3 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat4x3 hmat4x3; /// 4 * 4 matrix of half-precision floating-point numbers. - /// @see - gtc_half_float + /// @see gtc_half_float typedef detail::tmat4x4 hmat4x4; /// @} diff --git a/glm/gtc/quaternion.hpp b/glm/gtc/quaternion.hpp index 9ed8b7fe..e1318cf3 100644 --- a/glm/gtc/quaternion.hpp +++ b/glm/gtc/quaternion.hpp @@ -152,21 +152,21 @@ namespace detail /// Returns the length of the quaternion. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template T length( detail::tquat const & q); /// Returns the normalized quaternion. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat normalize( detail::tquat const & q); /// Returns dot product of q1 and q2, i.e., q1[0] * q2[0] + q1[1] * q2[1] + ... /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template T dot( detail::tquat const & q1, @@ -174,7 +174,7 @@ namespace detail /// Returns a SLERP interpolated quaternion of x and y according a. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat mix( detail::tquat const & x, @@ -183,21 +183,21 @@ namespace detail /// Returns the q conjugate. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat conjugate( detail::tquat const & q); /// Returns the q inverse. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat inverse( detail::tquat const & q); /// Rotates a quaternion from an vector of 3 components axis and an angle expressed in degrees. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat rotate( detail::tquat const & q, @@ -206,65 +206,65 @@ namespace detail /// Converts a quaternion to a 3 * 3 matrix. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tmat3x3 mat3_cast( detail::tquat const & x); /// Converts a quaternion to a 4 * 4 matrix. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tmat4x4 mat4_cast( detail::tquat const & x); /// Converts a 3 * 3 matrix to a quaternion. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat quat_cast( detail::tmat3x3 const & x); /// Converts a 4 * 4 matrix to a quaternion. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion template detail::tquat quat_cast( detail::tmat4x4 const & x); /// Quaternion of floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat quat; /// Quaternion of half-precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat hquat; /// Quaternion of single-precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat fquat; /// Quaternion of double-precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat dquat; /// Quaternion of low precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat lowp_quat; /// Quaternion of medium precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat mediump_quat; /// Quaternion of high precision floating-point numbers. /// - /// @see - gtc_quaternion + /// @see gtc_quaternion typedef detail::tquat highp_quat; /// @} diff --git a/glm/gtc/type_precision.hpp b/glm/gtc/type_precision.hpp index 0cbf51d0..b02cd18b 100644 --- a/glm/gtc/type_precision.hpp +++ b/glm/gtc/type_precision.hpp @@ -19,12 +19,12 @@ /// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, /// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN /// THE SOFTWARE. -/// +/// /// @ref gtc_type_precision /// @file glm/gtc/type_precision.hpp -/// @date 2009-06-04 / 2011-06-05 +/// @date 2009-06-04 / 2011-12-07 /// @author Christophe Riccio -/// +/// /// @see core (dependence) /// @see gtc_half_float (dependence) /// @see gtc_quaternion (dependence) @@ -60,186 +60,606 @@ namespace glm /// @addtogroup gtc_type_precision /// @{ - typedef detail::int8 int8; //!< \brief 8bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int16 int16; //!< \brief 16bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int32 int32; //!< \brief 32bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int64 int64; //!< \brief 64bit signed integer. (from GLM_GTC_type_precision extension) + /// 8 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int8 int8; + + /// 16 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int16 int16; - typedef detail::int8 int8_t; //!< \brief 8bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int16 int16_t; //!< \brief 16bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int32 int32_t; //!< \brief 32bit signed integer. (from GLM_GTC_type_precision extension) - typedef detail::int64 int64_t; //!< \brief 64bit signed integer. (from GLM_GTC_type_precision extension) + /// 32 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int32 int32; - typedef int8 i8; //!< \brief 8bit signed integer. (from GLM_GTC_type_precision extension) - typedef int16 i16; //!< \brief 16bit signed integer. (from GLM_GTC_type_precision extension) - typedef int32 i32; //!< \brief 32bit signed integer. (from GLM_GTC_type_precision extension) - typedef int64 i64; //!< \brief 64bit signed integer. (from GLM_GTC_type_precision extension) + /// 64 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int64 int64; - typedef detail::tvec1 i8vec1; //!< \brief 8bit signed integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 i8vec2; //!< \brief 8bit signed integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 i8vec3; //!< \brief 8bit signed integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 i8vec4; //!< \brief 8bit signed integer vector of 4 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec1 i16vec1; //!< \brief 16bit signed integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 i16vec2; //!< \brief 16bit signed integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 i16vec3; //!< \brief 16bit signed integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 i16vec4; //!< \brief 16bit signed integer vector of 4 components. (from GLM_GTC_type_precision extension) + /// 8 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int8 int8_t; + + /// 16 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int16 int16_t; - typedef detail::tvec1 i32vec1; //!< \brief 32bit signed integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 i32vec2; //!< \brief 32bit signed integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 i32vec3; //!< \brief 32bit signed integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 i32vec4; //!< \brief 32bit signed integer vector of 4 components. (from GLM_GTC_type_precision extension) + /// 32 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int32 int32_t; + + /// 64 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int64 int64_t; + + + /// 8 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int8 i8; + + /// 16 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int16 i16; + + /// 32 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int32 i32; + + /// 64 bit signed integer type. + /// @see gtc_type_precision + typedef detail::int64 i64; + + + /// 8 bit signed integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 i8vec1; + + /// 8 bit signed integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 i8vec2; + + /// 8 bit signed integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 i8vec3; + + /// 8 bit signed integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 i8vec4; + + + /// 16 bit signed integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 i16vec1; + + /// 16 bit signed integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 i16vec2; + + /// 16 bit signed integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 i16vec3; + + /// 16 bit signed integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 i16vec4; + + + /// 32 bit signed integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 i32vec1; + + /// 32 bit signed integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 i32vec2; + + /// 32 bit signed integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 i32vec3; + + /// 32 bit signed integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 i32vec4; + + + /// 64 bit signed integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 i64vec1; + + /// 64 bit signed integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 i64vec2; + + /// 64 bit signed integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 i64vec3; + + /// 64 bit signed integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 i64vec4; - typedef detail::tvec1 i64vec1; //!< \brief 32bit signed integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 i64vec2; //!< \brief 64bit signed integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 i64vec3; //!< \brief 64bit signed integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 i64vec4; //!< \brief 64bit signed integer vector of 4 components. (from GLM_GTC_type_precision extension) ///////////////////////////// // Unsigned int vector types - typedef detail::uint8 uint8; //!< \brief 8bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint16 uint16; //!< \brief 16bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint32 uint32; //!< \brief 32bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint64 uint64; //!< \brief 64bit unsigned integer. (from GLM_GTC_type_precision extension) + /// 8 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint8 uint8; + + /// 16 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint16 uint16; - typedef detail::uint8 uint8_t; //!< \brief 8bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint16 uint16_t; //!< \brief 16bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint32 uint32_t; //!< \brief 32bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef detail::uint64 uint64_t; //!< \brief 64bit unsigned integer. (from GLM_GTC_type_precision extension) + /// 32 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint32 uint32; - typedef uint8 u8; //!< \brief 8bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef uint16 u16; //!< \brief 16bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef uint32 u32; //!< \brief 32bit unsigned integer. (from GLM_GTC_type_precision extension) - typedef uint64 u64; //!< \brief 64bit unsigned integer. (from GLM_GTC_type_precision extension) + /// 64 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint64 uint64; - typedef detail::tvec1 u8vec1; //!< \brief 8bit unsigned integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 u8vec2; //!< \brief 8bit unsigned integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 u8vec3; //!< \brief 8bit unsigned integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 u8vec4; //!< \brief 8bit unsigned integer vector of 4 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec1 u16vec1; //!< \brief 16bit unsigned integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 u16vec2; //!< \brief 16bit unsigned integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 u16vec3; //!< \brief 16bit unsigned integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 u16vec4; //!< \brief 16bit unsigned integer vector of 4 components. (from GLM_GTC_type_precision extension) + /// 8 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint8 uint8_t; + + /// 16 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint16 uint16_t; - typedef detail::tvec1 u32vec1; //!< \brief 32bit unsigned integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 u32vec2; //!< \brief 32bit unsigned integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 u32vec3; //!< \brief 32bit unsigned integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 u32vec4; //!< \brief 32bit unsigned integer vector of 4 components. (from GLM_GTC_type_precision extension) + /// 32 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint32 uint32_t; + + /// 64 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint64 uint64_t; + + + /// 8 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint8 u8; + + /// 16 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint16 u16; + + /// 32 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint32 u32; + + /// 64 bit unsigned integer type. + /// @see gtc_type_precision + typedef detail::uint64 u64; + + + /// 8 bit unsigned integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 u8vec1; + + /// 8 bit unsigned integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 u8vec2; + + /// 8 bit unsigned integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 u8vec3; + + /// 8 bit unsigned integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 u8vec4; + + + /// 16 bit unsigned integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 u16vec1; + + /// 16 bit unsigned integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 u16vec2; + + /// 16 bit unsigned integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 u16vec3; + + /// 16 bit unsigned integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 u16vec4; + + + /// 32 bit unsigned integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 u32vec1; + + /// 32 bit unsigned integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 u32vec2; + + /// 32 bit unsigned integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 u32vec3; + + /// 32 bit unsigned integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 u32vec4; + + + /// 64 bit unsigned integer scalar type. + /// @see gtc_type_precision + typedef detail::tvec1 u64vec1; + + /// 64 bit unsigned integer vector of 2 components type. + /// @see gtc_type_precision + typedef detail::tvec2 u64vec2; + + /// 64 bit unsigned integer vector of 3 components type. + /// @see gtc_type_precision + typedef detail::tvec3 u64vec3; + + /// 64 bit unsigned integer vector of 4 components type. + /// @see gtc_type_precision + typedef detail::tvec4 u64vec4; - typedef detail::tvec1 u64vec1; //!< \brief 64bit unsigned integer scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 u64vec2; //!< \brief 64bit unsigned integer vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 u64vec3; //!< \brief 64bit unsigned integer vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 u64vec4; //!< \brief 64bit unsigned integer vector of 4 components. (from GLM_GTC_type_precision extension) ////////////////////// // Float vector types - typedef detail::float16 float16; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::float32 float32; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::float64 float64; //!< \brief Double-precision floating-point scalar. (from GLM_GTC_type_precision extension) + /// 16 bit half-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float16 float16; - typedef detail::float16 float16_t; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::float32 float32_t; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::float64 float64_t; //!< \brief Double-precision floating-point scalar. (from GLM_GTC_type_precision extension) + /// 32 bit single-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float32 float32; - typedef float16 f16; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef float32 f32; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef float64 f64; //!< \brief Double-precision floating-point scalar. (from GLM_GTC_type_precision extension) + /// 64 bit double-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float64 float64; - typedef detail::tvec2 fvec2; //!< Vector of 2 single-precision floating-point numbers. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 fvec3; //!< Vector of 3 single-precision floating-point numbers. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 fvec4; //!< Vector of 4 single-precision floating-point numbers. (from GLM_GTC_type_precision extension) - typedef detail::tvec1 f16vec1; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 f16vec2; //!< \brief Half-precision floating-point vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 f16vec3; //!< \brief Half-precision floating-point vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 f16vec4; //!< \brief Half-precision floating-point vector of 4 components. (from GLM_GTC_type_precision extension) + /// 16 bit half-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float16 float16_t; - typedef detail::tvec1 f32vec1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 f32vec2; //!< \brief Single-precision floating-point vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 f32vec3; //!< \brief Single-precision floating-point vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 f32vec4; //!< \brief Single-precision floating-point vector of 4 components. (from GLM_GTC_type_precision extension) + /// 32 bit single-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float32 float32_t; + + /// 64 bit double-precision floating-point scalar. + /// @see gtc_type_precision + typedef detail::float64 float64_t; + + + /// 16 bit half-precision floating-point scalar. + /// @see gtc_type_precision + typedef float16 f16; + + /// 32 bit single-precision floating-point scalar. + /// @see gtc_type_precision + typedef float32 f32; + + /// 64 bit double-precision floating-point scalar. + /// @see gtc_type_precision + typedef float64 f64; + + + /// Single-precision floating-point vector of 1 component. + /// @see gtc_type_precision + typedef detail::tvec1 fvec1; + + /// Single-precision floating-point vector of 2 components. + /// @see gtc_type_precision + typedef detail::tvec2 fvec2; + + /// Single-precision floating-point vector of 3 components. + /// @see gtc_type_precision + typedef detail::tvec3 fvec3; + + /// Single-precision floating-point vector of 4 components. + /// @see gtc_type_precision + typedef detail::tvec4 fvec4; + + + /// Half-precision floating-point vector of 1 component. + /// @see gtc_type_precision + typedef detail::tvec1 f16vec1; + + /// Half-precision floating-point vector of 2 components. + /// @see gtc_type_precision + typedef detail::tvec2 f16vec2; + + /// Half-precision floating-point vector of 3 components. + /// @see gtc_type_precision + typedef detail::tvec3 f16vec3; + + /// Half-precision floating-point vector of 4 components. + /// @see gtc_type_precision + typedef detail::tvec4 f16vec4; + + + /// Single-precision floating-point vector of 1 component. + /// @see gtc_type_precision + typedef detail::tvec1 f32vec1; + + /// Single-precision floating-point vector of 2 components. + /// @see gtc_type_precision + typedef detail::tvec2 f32vec2; + + /// Single-precision floating-point vector of 3 components. + /// @see gtc_type_precision + typedef detail::tvec3 f32vec3; + + /// Single-precision floating-point vector of 4 components. + /// @see gtc_type_precision + typedef detail::tvec4 f32vec4; + + + /// Double-precision floating-point vector of 1 component. + /// @see gtc_type_precision + typedef detail::tvec1 f64vec1; + + /// Double-precision floating-point vector of 2 components. + /// @see gtc_type_precision + typedef detail::tvec2 f64vec2; + + /// Double-precision floating-point vector of 3 components. + /// @see gtc_type_precision + typedef detail::tvec3 f64vec3; + + /// Double-precision floating-point vector of 4 components. + /// @see gtc_type_precision + typedef detail::tvec4 f64vec4; - typedef detail::tvec1 f64vec1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tvec2 f64vec2; //!< \brief Double-precision floating-point vector of 2 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec3 f64vec3; //!< \brief Double-precision floating-point vector of 3 components. (from GLM_GTC_type_precision extension) - typedef detail::tvec4 f64vec4; //!< \brief Double-precision floating-point vector of 4 components. (from GLM_GTC_type_precision extension) ////////////////////// // Float matrix types - //typedef f32 fmat1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 fmat2; //!< \brief Single-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 fmat3; //!< \brief Single-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 fmat4; //!< \brief Single-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef detail::tmat1x1 fmat1; - //typedef f32 fmat1x1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 fmat2x2; //!< \brief Single-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x3 fmat2x3; //!< \brief Single-precision floating-point 2x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x4 fmat2x4; //!< \brief Single-precision floating-point 2x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x2 fmat3x2; //!< \brief Single-precision floating-point 3x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 fmat3x3; //!< \brief Single-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x4 fmat3x4; //!< \brief Single-precision floating-point 3x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x2 fmat4x2; //!< \brief Single-precision floating-point 4x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x3 fmat4x3; //!< \brief Single-precision floating-point 4x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 fmat4x4; //!< \brief Single-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 fmat2; - //typedef f16 f16mat1; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f16mat2; //!< \brief Half-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f16mat3; //!< \brief Half-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f16mat4; //!< \brief Half-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 fmat3; - //typedef f16 f16mat1x1; //!< \brief Half-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f16mat2x2; //!< \brief Half-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x3 f16mat2x3; //!< \brief Half-precision floating-point 2x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x4 f16mat2x4; //!< \brief Half-precision floating-point 2x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x2 f16mat3x2; //!< \brief Half-precision floating-point 3x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f16mat3x3; //!< \brief Half-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x4 f16mat3x4; //!< \brief Half-precision floating-point 3x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x2 f16mat4x2; //!< \brief Half-precision floating-point 4x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x3 f16mat4x3; //!< \brief Half-precision floating-point 4x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f16mat4x4; //!< \brief Half-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 fmat4; - //typedef f32 f32mat1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f32mat2; //!< \brief Single-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f32mat3; //!< \brief Single-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f32mat4; //!< \brief Single-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) - //typedef f32 f32mat1x1; //!< \brief Single-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f32mat2x2; //!< \brief Single-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x3 f32mat2x3; //!< \brief Single-precision floating-point 2x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x4 f32mat2x4; //!< \brief Single-precision floating-point 2x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x2 f32mat3x2; //!< \brief Single-precision floating-point 3x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f32mat3x3; //!< \brief Single-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x4 f32mat3x4; //!< \brief Single-precision floating-point 3x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x2 f32mat4x2; //!< \brief Single-precision floating-point 4x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x3 f32mat4x3; //!< \brief Single-precision floating-point 4x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f32mat4x4; //!< \brief Single-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef f32 fmat1x1; - //typedef f64 f64mat1; //!< \brief Double-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f64mat2; //!< \brief Double-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f64mat3; //!< \brief Double-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f64mat4; //!< \brief Double-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) + /// Single-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 fmat2x2; + + /// Single-precision floating-point 2x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x3 fmat2x3; + + /// Single-precision floating-point 2x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x4 fmat2x4; + + /// Single-precision floating-point 3x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x2 fmat3x2; + + /// Single-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 fmat3x3; + + /// Single-precision floating-point 3x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x4 fmat3x4; + + /// Single-precision floating-point 4x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x2 fmat4x2; + + /// Single-precision floating-point 4x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x3 fmat4x3; + + /// Single-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 fmat4x4; + + + /// Half-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef detail::tmat1x1 f16mat1; + + /// Half-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f16mat2; + + /// Half-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f16mat3; + + /// Half-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f16mat4; + + + /// Half-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef f16 f16mat1x1; + + /// Half-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f16mat2x2; + + /// Half-precision floating-point 2x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x3 f16mat2x3; + + /// Half-precision floating-point 2x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x4 f16mat2x4; + + /// Half-precision floating-point 3x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x2 f16mat3x2; + + /// Half-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f16mat3x3; + + /// Half-precision floating-point 3x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x4 f16mat3x4; + + /// Half-precision floating-point 4x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x2 f16mat4x2; + + /// Half-precision floating-point 4x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x3 f16mat4x3; + + /// Half-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f16mat4x4; + + + /// Single-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef detail::tmat1x1 f32mat1; + + /// Single-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f32mat2; + + /// Single-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f32mat3; + + /// Single-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f32mat4; + + + /// Single-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef f32 f32mat1x1; + + /// Single-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f32mat2x2; + + /// Single-precision floating-point 2x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x3 f32mat2x3; + + /// Single-precision floating-point 2x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x4 f32mat2x4; + + /// Single-precision floating-point 3x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x2 f32mat3x2; + + /// Single-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f32mat3x3; + + /// Single-precision floating-point 3x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x4 f32mat3x4; + + /// Single-precision floating-point 4x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x2 f32mat4x2; + + /// Single-precision floating-point 4x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x3 f32mat4x3; + + /// Single-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f32mat4x4; + + + /// Double-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef detail::tmat1x1 f64mat1; + + /// Double-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f64mat2; + + /// Double-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f64mat3; + + /// Double-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f64mat4; + + + /// Double-precision floating-point 1x1 matrix. + /// @see gtc_type_precision + //typedef f64 f64mat1x1; + + /// Double-precision floating-point 2x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x2 f64mat2x2; + + /// Double-precision floating-point 2x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x3 f64mat2x3; + + /// Double-precision floating-point 2x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat2x4 f64mat2x4; + + /// Double-precision floating-point 3x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x2 f64mat3x2; + + /// Double-precision floating-point 3x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x3 f64mat3x3; + + /// Double-precision floating-point 3x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat3x4 f64mat3x4; + + /// Double-precision floating-point 4x2 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x2 f64mat4x2; + + /// Double-precision floating-point 4x3 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x3 f64mat4x3; + + /// Double-precision floating-point 4x4 matrix. + /// @see gtc_type_precision + typedef detail::tmat4x4 f64mat4x4; - //typedef f64 f64mat1x1; //!< \brief Double-precision floating-point scalar. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x2 f64mat2x2; //!< \brief Double-precision floating-point 2x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x3 f64mat2x3; //!< \brief Double-precision floating-point 2x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat2x4 f64mat2x4; //!< \brief Double-precision floating-point 2x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x2 f64mat3x2; //!< \brief Double-precision floating-point 3x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x3 f64mat3x3; //!< \brief Double-precision floating-point 3x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat3x4 f64mat3x4; //!< \brief Double-precision floating-point 3x4 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x2 f64mat4x2; //!< \brief Double-precision floating-point 4x2 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x3 f64mat4x3; //!< \brief Double-precision floating-point 4x3 matrix. (from GLM_GTC_type_precision extension) - typedef detail::tmat4x4 f64mat4x4; //!< \brief Double-precision floating-point 4x4 matrix. (from GLM_GTC_type_precision extension) ////////////////////////// - // Float quaternion types + // Quaternion types - typedef detail::tquat f16quat; //!< \brief Half-precision floating-point quaternion. (from GLM_GTC_type_precision extension) - typedef detail::tquat f32quat; //!< \brief Single-precision floating-point quaternion. (from GLM_GTC_type_precision extension) - typedef detail::tquat f64quat; //!< \brief Double-precision floating-point quaternion. (from GLM_GTC_type_precision extension) + /// Half-precision floating-point quaternion. + /// @see gtc_type_precision + typedef detail::tquat f16quat; + + /// Single-precision floating-point quaternion. + /// @see gtc_type_precision + typedef detail::tquat f32quat; + + /// Double-precision floating-point quaternion. + /// @see gtc_type_precision + typedef detail::tquat f64quat; /// @} }//namespace glm diff --git a/glm/gtx/associated_min_max.hpp b/glm/gtx/associated_min_max.hpp index d889abd0..8864034b 100644 --- a/glm/gtx/associated_min_max.hpp +++ b/glm/gtx/associated_min_max.hpp @@ -50,20 +50,23 @@ namespace glm /// @addtogroup gtx_associated_min_max /// @{ - //! \brief Min comparison between 2 variables + /// Min comparison between 2 variables + /// @see gtx_associated_min_max template genTypeU associatedMin( const genTypeT& x, const genTypeU& a, const genTypeT& y, const genTypeU& b); - //! \brief Min comparison between 3 variables + /// Min comparison between 3 variables + /// @see gtx_associated_min_max template genTypeU associatedMin( const genTypeT& x, const genTypeU& a, const genTypeT& y, const genTypeU& b, const genTypeT& z, const genTypeU& c); - //! \brief Min comparison between 4 variables + /// Min comparison between 4 variables + /// @see gtx_associated_min_max template genTypeU associatedMin( const genTypeT& x, const genTypeU& a, @@ -71,20 +74,23 @@ namespace glm const genTypeT& z, const genTypeU& c, const genTypeT& w, const genTypeU& d); - //! \brief Max comparison between 2 variables + /// Max comparison between 2 variables + /// @see gtx_associated_min_max template genTypeU associatedMax( const genTypeT& x, const genTypeU& a, const genTypeT& y, const genTypeU& b); - //! \brief Max comparison between 3 variables + /// Max comparison between 3 variables + /// @see gtx_associated_min_max template genTypeU associatedMax( const genTypeT& x, const genTypeU& a, const genTypeT& y, const genTypeU& b, const genTypeT& z, const genTypeU& c); - //! \brief Max comparison between 4 variables + /// Max comparison between 4 variables + /// @see gtx_associated_min_max template genTypeU associatedMax( const genTypeT& x, const genTypeU& a, diff --git a/glm/gtx/bit.hpp b/glm/gtx/bit.hpp index d99bf1bd..43380df1 100644 --- a/glm/gtx/bit.hpp +++ b/glm/gtx/bit.hpp @@ -53,13 +53,13 @@ namespace glm /// @{ /// Build a mask of 'count' bits - /// From GLM_GTX_bit extension. + /// @see gtx_bit template genIType mask(genIType const & count); /// Component wise extraction of bit fields. /// genType and genIType could be a scalar or a vector. - /// From GLM_GTX_bit extension. + /// @see gtx_bit template genIUType extractField( genIUType const & v, @@ -67,57 +67,57 @@ namespace glm sizeType const & count); //! Find the lowest bit set to 1 in a integer variable. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template int lowestBit(genType const & value); //! Find the highest bit set to 1 in a integer variable. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template int highestBit(genType const & value); //! Find the highest bit set to 1 in a integer variable and return its value. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType highestBitValue(genType const & value); //! Return true if the value is a power of two number. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template bool isPowerOfTwo(genType const & value); //! Return the power of two number which value is just higher the input value. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType powerOfTwoAbove(genType const & value); //! Return the power of two number which value is just lower the input value. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType powerOfTwoBelow(genType const & value); //! Return the power of two number which value is the closet to the input value. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType powerOfTwoNearest(genType const & value); //! Revert all bits of any integer based type. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType bitRevert(genType const & value); //! Rotate all bits to the right. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType bitRotateRight(genType const & In, std::size_t Shift); //! Rotate all bits to the left. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genType bitRotateLeft(genType const & In, std::size_t Shift); //! Set to 1 a range of bits. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genIUType fillBitfieldWithOne( genIUType const & Value, @@ -125,7 +125,7 @@ namespace glm int const & ToBit); //! Set to 0 a range of bits. - //! From GLM_GTX_bit extension. + /// @see gtx_bit template genIUType fillBitfieldWithZero( genIUType const & Value, diff --git a/glm/gtx/closest_point.hpp b/glm/gtx/closest_point.hpp index 920168e7..5410a794 100644 --- a/glm/gtx/closest_point.hpp +++ b/glm/gtx/closest_point.hpp @@ -51,7 +51,7 @@ namespace glm /// @{ /// Find the point on a straight line which is the closet of a point. - /// From GLM_GTX_closest_point extension. + /// @see gtx_closest_point template detail::tvec3 closestPointOnLine( detail::tvec3 const & point, diff --git a/glm/gtx/color_cast.hpp b/glm/gtx/color_cast.hpp index 5920c343..82f1c128 100644 --- a/glm/gtx/color_cast.hpp +++ b/glm/gtx/color_cast.hpp @@ -53,11 +53,11 @@ namespace glm /// @{ //! Conversion of a floating value into a 8bit unsigned int value. - //! From GLM_GTX_color_cast extension. + /// @see gtx_color_cast template uint8 u8channel_cast(valType a); - //! Conversion of a floating value into a 16bit unsigned int value. - //! From GLM_GTX_color_cast extension. + /// Conversion of a floating value into a 16bit unsigned int value. + /// @see gtx_color_cast template uint16 u16channel_cast(valType a); template uint32 u32_rgbx_cast(const detail::tvec3& c); //!< \brief Conversion of a 3 components color into an 32bit unsigned int value. (From GLM_GTX_color_cast extension) diff --git a/glm/gtx/color_space.hpp b/glm/gtx/color_space.hpp index e4234404..188e9ce1 100644 --- a/glm/gtx/color_space.hpp +++ b/glm/gtx/color_space.hpp @@ -50,40 +50,40 @@ namespace glm /// @addtogroup gtx_color_space /// @{ - //! Converts a color from HSV color space to its color in RGB color space. - //! From GLM_GTX_color_space extension. + /// Converts a color from HSV color space to its color in RGB color space. + /// @see gtx_color_space template detail::tvec3 rgbColor( detail::tvec3 const & hsvValue); - //! Converts a color from RGB color space to its color in HSV color space. - //! From GLM_GTX_color_space extension. + /// Converts a color from RGB color space to its color in HSV color space. + /// @see gtx_color_space template detail::tvec3 hsvColor( detail::tvec3 const & rgbValue); - //! Build a saturation matrix. - //! From GLM_GTX_color_space extension + /// Build a saturation matrix. + /// @see gtx_color_space template detail::tmat4x4 saturation( valType const s); - //! Modify the saturation of a color. - //! From GLM_GTX_color_space extension. + /// Modify the saturation of a color. + /// @see gtx_color_space template detail::tvec3 saturation( valType const s, detail::tvec3 const & color); - //! Modify the saturation of a color. - //! From GLM_GTX_color_space extension. + /// Modify the saturation of a color. + /// @see gtx_color_space template detail::tvec4 saturation( valType const s, detail::tvec4 const & color); - //! Compute color luminosity associating ratios (0.33, 0.59, 0.11) to RGB canals. - //! From GLM_GTX_color_space extension. + /// Compute color luminosity associating ratios (0.33, 0.59, 0.11) to RGB canals. + /// @see gtx_color_space template valType luminosity( detail::tvec3 const & color); diff --git a/glm/gtx/color_space_YCoCg.hpp b/glm/gtx/color_space_YCoCg.hpp index e87b1695..83f8e901 100644 --- a/glm/gtx/color_space_YCoCg.hpp +++ b/glm/gtx/color_space_YCoCg.hpp @@ -50,28 +50,28 @@ namespace glm /// @addtogroup gtx_color_space_YCoCg /// @{ - //! Convert a color from RGB color space to YCoCg color space. - //! From GLM_GTX_color_space_YCoCg extension. + /// Convert a color from RGB color space to YCoCg color space. + /// @see gtx_color_space_YCoCg template detail::tvec3 rgb2YCoCg( detail::tvec3 const & rgbColor); - //! Convert a color from YCoCg color space to RGB color space. - //! From GLM_GTX_color_space_YCoCg extension. + /// Convert a color from YCoCg color space to RGB color space. + /// @see gtx_color_space_YCoCg template detail::tvec3 YCoCg2rgb( detail::tvec3 const & YCoCgColor); - //! Convert a color from RGB color space to YCoCgR color space. - //! \see "YCoCg-R: A Color Space with RGB Reversibility and Low Dynamic Range" - //! From GLM_GTX_color_space_YCoCg extension. + /// Convert a color from RGB color space to YCoCgR color space. + /// @see "YCoCg-R: A Color Space with RGB Reversibility and Low Dynamic Range" + /// @see gtx_color_space_YCoCg template detail::tvec3 rgb2YCoCgR( detail::tvec3 const & rgbColor); - //! Convert a color from YCoCgR color space to RGB color space. - //! \see "YCoCg-R: A Color Space with RGB Reversibility and Low Dynamic Range" - //! From GLM_GTX_color_space_YCoCg extension. + /// Convert a color from YCoCgR color space to RGB color space. + /// @see "YCoCg-R: A Color Space with RGB Reversibility and Low Dynamic Range" + /// @see gtx_color_space_YCoCg template detail::tvec3 YCoCgR2rgb( detail::tvec3 const & YCoCgColor); diff --git a/glm/gtx/component_wise.hpp b/glm/gtx/component_wise.hpp index 576e6004..6f3b969b 100644 --- a/glm/gtx/component_wise.hpp +++ b/glm/gtx/component_wise.hpp @@ -50,26 +50,26 @@ namespace glm /// @addtogroup gtx_component_wise /// @{ - //! Add all vector components together. - //! From GLM_GTX_component_wise extension. + /// Add all vector components together. + /// @see gtx_component_wise template typename genType::value_type compAdd( genType const & v); - //! Multiply all vector components together. - //! From GLM_GTX_component_wise extension. + /// Multiply all vector components together. + /// @see gtx_component_wise template typename genType::value_type compMul( genType const & v); - //! Find the minimum value between single vector components. - //! From GLM_GTX_component_wise extension. + /// Find the minimum value between single vector components. + /// @see gtx_component_wise template typename genType::value_type compMin( genType const & v); - //! Find the maximum value between single vector components. - //! From GLM_GTX_component_wise extension. + /// Find the maximum value between single vector components. + /// @see gtx_component_wise template typename genType::value_type compMax( genType const & v); diff --git a/glm/gtx/constants.hpp b/glm/gtx/constants.hpp index 5b028e37..7ab75855 100644 --- a/glm/gtx/constants.hpp +++ b/glm/gtx/constants.hpp @@ -52,126 +52,106 @@ namespace glm /// @addtogroup gtx_constants /// @{ + /// Return the epsilon constant for floating point types. /// @todo Implement epsilon for half-precision floating point type. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T epsilon() - { - return std::numeric_limits::epsilon(); - } + T epsilon(); + /// Return the pi constant. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T pi() - { - return T(3.14159265358979323846264338327950288); - } + T pi(); + /// Return square root of pi. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T root_pi() - { - return T(1.772453850905516027); - } + T root_pi(); + /// Return pi / 2. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T half_pi() - { - return T(1.57079632679489661923132169163975144); - } + T half_pi(); + /// Return pi / 4. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T quarter_pi() - { - return T(0.785398163397448309615660845819875721); - } + T quarter_pi(); + /// Return 1 / pi. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T one_over_pi() - { - return T(0.318309886183790671537767526745028724); - } + T one_over_pi(); + /// Return 2 / pi. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T two_over_pi() - { - return T(0.636619772367581343075535053490057448); - } + T two_over_pi(); + /// Return 2 / sqrt(pi). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T two_over_root_pi() - { - return T(1.12837916709551257389615890312154517); - } + T two_over_root_pi(); + /// Return 1 / sqrt(2). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T one_over_root_two() - { - return T(0.707106781186547524400844362104849039); - } + T one_over_root_two(); + /// Return sqrt(pi / 2). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T root_half_pi() - { - return T(1.253314137315500251); - } + T root_half_pi(); + /// Return sqrt(2 * pi). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T root_two_pi() - { - return T(2.506628274631000502); - } + T root_two_pi(); + /// Return sqrt(ln(4)). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T root_ln_four() - { - return T(1.17741002251547469); - } + T root_ln_four(); + /// Return e constant. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T e() - { - return T(2.71828182845904523536); - } + T e(); + /// Return Euler's constant. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T euler() - { - return T(0.577215664901532860606); - } + T euler(); + /// Return sqrt(2). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T root_two() - { - return T(1.41421356237309504880168872420969808); - } + T root_two(); + /// Return ln(2). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T ln_two() - { - return T(0.693147180559945309417232121458176568); - } + T ln_two(); + /// Return ln(10). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T ln_ten() - { - return T(2.30258509299404568401799145468436421); - } + T ln_ten(); + /// Return ln(ln(2)). + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T ln_ln_two() - { - return T(-0.3665129205816643); - } + T ln_ln_two(); + /// Return 1 / 3. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T third() - { - return T(0.333333333333333333); - } + T third(); + /// Return 2 / 3. + /// @see gtx_constants template - GLM_FUNC_QUALIFIER T twothirds() - { - return T(0.666666666666666666); - } + T twothirds(); /// @} } //namespace glm diff --git a/glm/gtx/constants.inl b/glm/gtx/constants.inl index 7a556919..0e696bfb 100644 --- a/glm/gtx/constants.inl +++ b/glm/gtx/constants.inl @@ -25,3 +25,126 @@ /// @date 2011-10-14 / 2011-10-14 /// @author Christophe Riccio /////////////////////////////////////////////////////////////////////////////////// + +namespace glm +{ + template + GLM_FUNC_QUALIFIER T epsilon() + { + return std::numeric_limits::epsilon(); + } + + template + GLM_FUNC_QUALIFIER T pi() + { + return T(3.14159265358979323846264338327950288); + } + + template + GLM_FUNC_QUALIFIER T root_pi() + { + return T(1.772453850905516027); + } + + template + GLM_FUNC_QUALIFIER T half_pi() + { + return T(1.57079632679489661923132169163975144); + } + + template + GLM_FUNC_QUALIFIER T quarter_pi() + { + return T(0.785398163397448309615660845819875721); + } + + template + GLM_FUNC_QUALIFIER T one_over_pi() + { + return T(0.318309886183790671537767526745028724); + } + + template + GLM_FUNC_QUALIFIER T two_over_pi() + { + return T(0.636619772367581343075535053490057448); + } + + template + GLM_FUNC_QUALIFIER T two_over_root_pi() + { + return T(1.12837916709551257389615890312154517); + } + + template + GLM_FUNC_QUALIFIER T one_over_root_two() + { + return T(0.707106781186547524400844362104849039); + } + + template + GLM_FUNC_QUALIFIER T root_half_pi() + { + return T(1.253314137315500251); + } + + template + GLM_FUNC_QUALIFIER T root_two_pi() + { + return T(2.506628274631000502); + } + + template + GLM_FUNC_QUALIFIER T root_ln_four() + { + return T(1.17741002251547469); + } + + template + GLM_FUNC_QUALIFIER T e() + { + return T(2.71828182845904523536); + } + + template + GLM_FUNC_QUALIFIER T euler() + { + return T(0.577215664901532860606); + } + + template + GLM_FUNC_QUALIFIER T root_two() + { + return T(1.41421356237309504880168872420969808); + } + + template + GLM_FUNC_QUALIFIER T ln_two() + { + return T(0.693147180559945309417232121458176568); + } + + template + GLM_FUNC_QUALIFIER T ln_ten() + { + return T(2.30258509299404568401799145468436421); + } + + template + GLM_FUNC_QUALIFIER T ln_ln_two() + { + return T(-0.3665129205816643); + } + + template + GLM_FUNC_QUALIFIER T third() + { + return T(0.333333333333333333); + } + + template + GLM_FUNC_QUALIFIER T twothirds() + { + return T(0.666666666666666667); + } +} //namespace glm diff --git a/glm/gtx/extend.hpp b/glm/gtx/extend.hpp index 2f25c5bb..5855cdfb 100644 --- a/glm/gtx/extend.hpp +++ b/glm/gtx/extend.hpp @@ -50,8 +50,8 @@ namespace glm /// @addtogroup gtx_extend /// @{ - //! Extends of Length the Origin position using the (Source - Origin) direction. - //! From GLM_GTX_extend extension. + /// Extends of Length the Origin position using the (Source - Origin) direction. + /// From GLM_GTX_extend extension. template genType extend( genType const & Origin,