OpenGL Mathematics (GLM)

Overview

glm

OpenGL Mathematics (GLM) is a header only C++ mathematics library for graphics software based on the OpenGL Shading Language (GLSL) specifications.

GLM provides classes and functions designed and implemented with the same naming conventions and functionality than GLSL so that anyone who knows GLSL, can use GLM as well in C++.

This project isn't limited to GLSL features. An extension system, based on the GLSL extension conventions, provides extended capabilities: matrix transformations, quaternions, data packing, random numbers, noise, etc...

This library works perfectly with OpenGL but it also ensures interoperability with other third party libraries and SDK. It is a good candidate for software rendering (raytracing / rasterisation), image processing, physics simulations and any development context that requires a simple and convenient mathematics library.

GLM is written in C++98 but can take advantage of C++11 when supported by the compiler. It is a platform independent library with no dependence and it officially supports the following compilers:

For more information about GLM, please have a look at the manual and the API reference documentation. The source code and the documentation are licensed under either the Happy Bunny License (Modified MIT) or the MIT License.

Thanks for contributing to the project by submitting pull requests.

#include <glm/vec3.hpp> // glm::vec3
#include <glm/vec4.hpp> // glm::vec4
#include <glm/mat4x4.hpp> // glm::mat4
#include <glm/ext/matrix_transform.hpp> // glm::translate, glm::rotate, glm::scale
#include <glm/ext/matrix_clip_space.hpp> // glm::perspective
#include <glm/ext/scalar_constants.hpp> // glm::pi

glm::mat4 camera(float Translate, glm::vec2 const& Rotate)
{
	glm::mat4 Projection = glm::perspective(glm::pi<float>() * 0.25f, 4.0f / 3.0f, 0.1f, 100.f);
	glm::mat4 View = glm::translate(glm::mat4(1.0f), glm::vec3(0.0f, 0.0f, -Translate));
	View = glm::rotate(View, Rotate.y, glm::vec3(-1.0f, 0.0f, 0.0f));
	View = glm::rotate(View, Rotate.x, glm::vec3(0.0f, 1.0f, 0.0f));
	glm::mat4 Model = glm::scale(glm::mat4(1.0f), glm::vec3(0.5f));
	return Projection * View * Model;
}

Lastest release

Project Health

Service System Compiler Status
Travis CI MacOSX, Linux 64 bits Clang 3.6, Clang 5.0, GCC 4.9, GCC 7.3 Travis CI
AppVeyor Windows 32 and 64 Visual Studio 2013, Visual Studio 2015, Visual Studio 2017 AppVeyor

Release notes

GLM 0.9.9.9 - 2020-XX-XX

Features:

  • Added GLM_EXT_scalar_reciprocal with tests
  • Added GLM_EXT_vector_reciprocal with tests
  • Added glm::iround and glm::uround to GLM_EXT_scalar_common and GLM_EXT_vector_common
  • Added GLM_EXT_matrix_integer with tests

Improvements:

  • Added constexpr qualifier for cross product #1040
  • Added constexpr qualifier for dot product #1040

Fixes:

  • Fixed incorrect assertion for glm::min and glm::max #1009
  • Fixed quaternion orientation in glm::decompose #1012
  • Fixed singularity in quaternion to euler angle roll conversion #1019
  • Fixed quat glm::pow handling of small magnitude quaternions #1022
  • Fixed glm::fastNormalize build error #1033
  • Fixed glm::isMultiple build error #1034
  • Fixed glm::adjugate calculation #1035
  • Fixed glm::angle discards the sign of result for angles in range (2pi-1, 2pi) #1038
  • Removed ban on using glm::string_cast with CUDA host code #1041

GLM 0.9.9.8 - 2020-04-13

Features:

  • Added GLM_EXT_vector_intX and GLM_EXT_vector_uintX extensions
  • Added GLM_EXT_matrix_intX and GLM_EXT_matrix_uintX extensions

Improvements:

  • Added glm::clamp, glm::repeat, glm::mirrorClamp and glm::mirrorRepeat function to GLM_EXT_scalar_commond and GLM_EXT_vector_commond extensions with tests

Fixes:

  • Fixed unnecessary warnings from matrix_projection.inl #995
  • Fixed quaternion glm::slerp overload which interpolates with extra spins #996
  • Fixed for glm::length using arch64 #992
  • Fixed singularity check for glm::quatLookAt #770

GLM 0.9.9.7 - 2020-01-05

Improvements:

  • Improved Neon support with more functions optimized #950
  • Added CMake GLM interface #963
  • Added glm::fma implementation based on std::fma #969
  • Added missing quat constexpr #955
  • Added GLM_FORCE_QUAT_DATA_WXYZ to store quat data as w,x,y,z instead of x,y,z,w #983

Fixes:

  • Fixed equal ULP variation when using negative sign #965
  • Fixed for intersection ray/plane and added related tests #953
  • Fixed ARM 64bit detection #949
  • Fixed GLM_EXT_matrix_clip_space warnings #980
  • Fixed Wimplicit-int-float-conversion warnings with clang 10+ #986
  • Fixed GLM_EXT_matrix_clip_space perspectiveFov

GLM 0.9.9.6 - 2019-09-08

Features:

  • Added Neon support #945
  • Added SYCL support #914
  • Added GLM_EXT_scalar_integer extension with power of two and multiple scalar functions
  • Added GLM_EXT_vector_integer extension with power of two and multiple vector functions

Improvements:

  • Added Visual C++ 2019 detection
  • Added Visual C++ 2017 15.8 and 15.9 detection
  • Added missing genType check for glm::bitCount and glm::bitfieldReverse #893

Fixes:

  • Fixed for g++6 where -std=c++1z sets __cplusplus to 201500 instead of 201402 #921
  • Fixed hash hashes qua instead of tquat #919
  • Fixed .natvis as structs renamed #915
  • Fixed glm::ldexp and glm::frexp declaration #895
  • Fixed missing const to quaternion conversion operators #890
  • Fixed GLM_EXT_scalar_ulp and GLM_EXT_vector_ulp API coding style
  • Fixed quaternion componant order: w, {x, y, z} #916
  • Fixed GLM_HAS_CXX11_STL broken on Clang with Linux #926
  • Fixed Clang or GCC build due to wrong GLM_HAS_IF_CONSTEXPR definition #907
  • Fixed CUDA 9 build #910

Deprecation:

  • Removed CMake install and uninstall scripts

GLM 0.9.9.5 - 2019-04-01

Fixes:

  • Fixed build errors when defining GLM_ENABLE_EXPERIMENTAL #884 #883
  • Fixed if constexpr warning #887
  • Fixed missing declarations for glm::frexp and glm::ldexp #886

GLM 0.9.9.4 - 2019-03-19

Features:

  • Added glm::mix implementation for matrices in *GLM_EXT_matrix_common/ #842
  • Added CMake BUILD_SHARED_LIBS and BUILD_STATIC_LIBS build options #871

Improvements:

  • Added GLM_FORCE_INTRINSICS to enable SIMD instruction code path. By default, it's disabled allowing constexpr support by default. #865
  • Optimized inverseTransform #867

Fixes:

  • Fixed in glm::mat4x3 conversion #829
  • Fixed constexpr issue on GCC #832 #865
  • Fixed glm::mix implementation to improve GLSL conformance #866
  • Fixed glm::int8 being defined as unsigned char with some compiler #839
  • Fixed glm::vec1 include #856
  • Ignore .vscode #848

GLM 0.9.9.3 - 2018-10-31

Features:

  • Added glm::equal and glm::notEqual overload with max ULPs parameters for scalar numbers #121
  • Added GLM_FORCE_SILENT_WARNINGS to silent GLM warnings when using language extensions but using W4 or Wpedantic warnings #814 #775
  • Added adjugate functions to GLM_GTX_matrix_operation #151
  • Added GLM_FORCE_ALIGNED_GENTYPES to enable aligned types and SIMD instruction are not enabled. This disable constexpr #816

Improvements:

  • Added constant time ULP distance between float #121
  • Added GLM_FORCE_SILENT_WARNINGS to suppress GLM warnings #822

Fixes:

  • Fixed glm::simplex noise build with double #734
  • Fixed glm::bitfieldInsert according to GLSL spec #818
  • Fixed glm::refract for negative 'k' #808

GLM 0.9.9.2 - 2018-09-14

Fixes:

  • Fixed GLM_FORCE_CXX** section in the manual
  • Fixed default initialization with vector and quaternion types using GLM_FORCE_CTOR_INIT #812

GLM 0.9.9.1 - 2018-09-03

Features:

  • Added bitfieldDeinterleave to GLM_GTC_bitfield
  • Added missing glm::equal and glm::notEqual with epsilon for quaternion types to GLM_GTC_quaternion
  • Added GLM_EXT_matrix_relational: glm::equal and glm::notEqual with epsilon for matrix types
  • Added missing aligned matrix types to GLM_GTC_type_aligned
  • Added C++17 detection
  • Added Visual C++ language standard version detection
  • Added PDF manual build from markdown

Improvements:

  • Added a section to the manual for contributing to GLM
  • Refactor manual, lists all configuration defines
  • Added missing glm::vec1 based constructors
  • Redesigned constexpr support which excludes both SIMD and constexpr #783
  • Added detection of Visual C++ 2017 toolsets
  • Added identity functions #765
  • Splitted headers into EXT extensions to improve compilation time #670
  • Added separated performance tests
  • Clarified refract valid range of the indices of refraction, between -1 and 1 inclusively #806

Fixes:

  • Fixed SIMD detection on Clang and GCC
  • Fixed build problems due to std::printf and std::clock_t #778
  • Fixed int mod
  • Anonymous unions require C++ language extensions
  • Fixed glm::ortho #790
  • Fixed Visual C++ 2013 warnings in vector relational code #782
  • Fixed ICC build errors with constexpr #704
  • Fixed defaulted operator= and constructors #791
  • Fixed invalid conversion from int scalar with vec4 constructor when using SSE instruction
  • Fixed infinite loop in random functions when using negative radius values using an assert #739

GLM 0.9.9.0 - 2018-05-22

Features:

  • Added RGBM encoding in GLM_GTC_packing #420
  • Added GLM_GTX_color_encoding extension
  • Added GLM_GTX_vec_swizzle, faster compile time swizzling then swizzle operator #558
  • Added GLM_GTX_exterior_product with a vec2 glm::cross implementation #621
  • Added GLM_GTX_matrix_factorisation to factor matrices in various forms #654
  • Added GLM_ENABLE_EXPERIMENTAL to enable experimental features.
  • Added packing functions for integer vectors #639
  • Added conan packaging configuration #643 #641
  • Added glm::quatLookAt to GLM_GTX_quaternion #659
  • Added glm::fmin, glm::fmax and glm::fclamp to GLM_GTX_extended_min_max #372
  • Added GLM_EXT_vector_relational: extend glm::equal and glm::notEqual to take an epsilon argument
  • Added GLM_EXT_vector_relational: glm::openBounded and glm::closeBounded
  • Added GLM_EXT_vec1: *vec1 types
  • Added GLM_GTX_texture: levels function
  • Added spearate functions to use both nagative one and zero near clip plans #680
  • Added GLM_FORCE_SINGLE_ONLY to use GLM on platforms that don't support double #627
  • Added GLM_GTX_easing for interpolation functions #761

Improvements:

  • No more default initialization of vector, matrix and quaternion types
  • Added lowp variant of GTC_color_space convertLinearToSRGB #419
  • Replaced the manual by a markdown version #458
  • Improved API documentation #668
  • Optimized GTC_packing implementation
  • Optimized GTC_noise functions
  • Optimized GTC_color_space HSV to RGB conversions
  • Optimised GTX_color_space_YCoCg YCoCgR conversions
  • Optimized GTX_matrix_interpolation axisAngle function
  • Added FAQ 12: Windows headers cause build errors... #557
  • Removed GCC shadow warnings #595
  • Added error for including of different versions of GLM #619
  • Added GLM_FORCE_IGNORE_VERSION to ignore error caused by including different version of GLM #619
  • Reduced warnings when using very strict compilation flags #646
  • length() member functions are constexpr #657
  • Added support of -Weverything with Clang #646
  • Improved exponential function test coverage
  • Enabled warnings as error with Clang unit tests
  • Conan package is an external repository: https://github.com/bincrafters/conan-glm
  • Clarify quat_cast documentation, applying on pure rotation matrices #759

Fixes:

  • Removed doxygen references to GLM_GTC_half_float which was removed in 0.9.4
  • Fixed glm::decompose #448
  • Fixed glm::intersectRayTriangle #6
  • Fixed dual quaternion != operator #629
  • Fixed usused variable warning in GLM_GTX_spline #618
  • Fixed references to GLM_FORCE_RADIANS which was removed #642
  • Fixed glm::fastInverseSqrt to use fast inverse square #640
  • Fixed glm::axisAngle NaN #638
  • Fixed integer pow from GLM_GTX_integer with null exponent #658
  • Fixed quat normalize build error #656
  • Fixed Visual C++ 2017.2 warning regarding __has_feature definision #655
  • Fixed documentation warnings
  • Fixed GLM_HAS_OPENMP when OpenMP is not enabled
  • Fixed Better follow GLSL min and max specification #372
  • Fixed quaternion constructor from two vectors special cases #469
  • Fixed glm::to_string on quaternions wrong components order #681
  • Fixed glm::acsch #698
  • Fixed glm::isnan on CUDA #727

Deprecation:

  • Requires Visual Studio 2013, GCC 4.7, Clang 3.4, Cuda 7, ICC 2013 or a C++11 compiler
  • Removed GLM_GTX_simd_vec4 extension
  • Removed GLM_GTX_simd_mat4 extension
  • Removed GLM_GTX_simd_quat extension
  • Removed GLM_SWIZZLE, use GLM_FORCE_SWIZZLE instead
  • Removed GLM_MESSAGES, use GLM_FORCE_MESSAGES instead
  • Removed GLM_DEPTH_ZERO_TO_ONE, use GLM_FORCE_DEPTH_ZERO_TO_ONE instead
  • Removed GLM_LEFT_HANDED, use GLM_FORCE_LEFT_HANDED instead
  • Removed GLM_FORCE_NO_CTOR_INIT
  • Removed glm::uninitialize

GLM 0.9.8.5 - 2017-08-16

Features:

  • Added Conan package support #647

Fixes:

  • Fixed Clang version detection from source #608
  • Fixed glm::packF3x9_E1x5 exponent packing #614
  • Fixed build error min and max specializations with integer #616
  • Fixed simd_mat4 build error #652

GLM 0.9.8.4 - 2017-01-22

Fixes:

  • Fixed GLM_GTC_packing test failing on GCC x86 due to denorms #212 #577
  • Fixed POPCNT optimization build in Clang #512
  • Fixed glm::intersectRayPlane returns true in parallel case #578
  • Fixed GCC 6.2 compiler warnings #580
  • Fixed GLM_GTX_matrix_decompose glm::decompose #582 #448
  • Fixed GCC 4.5 and older build #566
  • Fixed Visual C++ internal error when declaring a global vec type with siwzzle expression enabled #594
  • Fixed GLM_FORCE_CXX11 with Clang and libstlc++ which wasn't using C++11 STL features. #604

GLM 0.9.8.3 - 2016-11-12

Improvements:

  • Broader support of GLM_FORCE_UNRESTRICTED_GENTYPE #378

Fixes:

  • Fixed Android build error with C++11 compiler but C++98 STL #284 #564
  • Fixed GLM_GTX_transform2 shear* functions #403
  • Fixed interaction between GLM_FORCE_UNRESTRICTED_GENTYPE and glm::ortho function #568
  • Fixed glm::bitCount with AVX on 32 bit builds #567
  • Fixed CMake find_package with version specification #572 #573

GLM 0.9.8.2 - 2016-11-01

Improvements:

  • Added Visual C++ 15 detection
  • Added Clang 4.0 detection
  • Added warning messages when using GLM_FORCE_CXX** but the compiler is known to not fully support the requested C++ version #555
  • Refactored GLM_COMPILER_VC values
  • Made quat, vec, mat type component length() static #565

Fixes:

  • Fixed Visual C++ constexpr build error #555, #556

GLM 0.9.8.1 - 2016-09-25

Improvements:

  • Optimized quaternion glm::log function #554

Fixes:

  • Fixed GCC warning filtering, replaced -pedantic by -Wpedantic
  • Fixed SIMD faceforward bug. #549
  • Fixed GCC 4.8 with C++11 compilation option #550
  • Fixed Visual Studio aligned type W4 warning #548
  • Fixed packing/unpacking function fixed for 5_6_5 and 5_5_5_1 #552

GLM 0.9.8.0 - 2016-09-11

Features:

  • Added right and left handed projection and clip control support #447 #415 #119
  • Added glm::compNormalize and glm::compScale functions to GLM_GTX_component_wise
  • Added glm::packF3x9_E1x5 and glm::unpackF3x9_E1x5 to GLM_GTC_packing for RGB9E5 #416
  • Added (un)packHalf to GLM_GTC_packing
  • Added (un)packUnorm and (un)packSnorm to GLM_GTC_packing
  • Added 16bit pack and unpack to GLM_GTC_packing
  • Added 8bit pack and unpack to GLM_GTC_packing
  • Added missing bvec* && and || operators
  • Added glm::iround and glm::uround to GLM_GTC_integer, fast round on positive values
  • Added raw SIMD API
  • Added 'aligned' qualifiers
  • Added GLM_GTC_type_aligned with aligned vec types
  • Added GLM_GTC_functions extension
  • Added quaternion version of glm::isnan and glm::isinf #521
  • Added glm::lowestBitValue to GLM_GTX_bit #536
  • Added GLM_FORCE_UNRESTRICTED_GENTYPE allowing non basic genType #543

Improvements:

  • Improved SIMD and swizzle operators interactions with GCC and Clang #474
  • Improved GLM_GTC_random linearRand documentation
  • Improved GLM_GTC_reciprocal documentation
  • Improved GLM_FORCE_EXPLICIT_CTOR coverage #481
  • Improved OpenMP support detection for Clang, GCC, ICC and VC
  • Improved GLM_GTX_wrap for SIMD friendliness
  • Added constexpr for *vec*, *mat*, *quat* and *dual_quat* types #493
  • Added NEON instruction set detection
  • Added MIPS CPUs detection
  • Added PowerPC CPUs detection
  • Use Cuda built-in function for abs function implementation with Cuda compiler
  • Factorized GLM_COMPILER_LLVM and GLM_COMPILER_APPLE_CLANG into GLM_COMPILER_CLANG
  • No more warnings for use of long long
  • Added more information to build messages

Fixes:

  • Fixed GLM_GTX_extended_min_max filename typo #386
  • Fixed glm::intersectRayTriangle to not do any unintentional backface culling
  • Fixed long long warnings when using C++98 on GCC and Clang #482
  • Fixed sign with signed integer function on non-x86 architecture
  • Fixed strict aliasing warnings #473
  • Fixed missing glm::vec1 overload to glm::length2 and glm::distance2 functions #431
  • Fixed GLM test '/fp:fast' and '/Za' command-line options are incompatible
  • Fixed quaterion to mat3 cast function glm::mat3_cast from GLM_GTC_quaternion #542
  • Fixed GLM_GTX_io for Cuda #547 #546

Deprecation:

  • Removed GLM_FORCE_SIZE_FUNC define
  • Deprecated GLM_GTX_simd_vec4 extension
  • Deprecated GLM_GTX_simd_mat4 extension
  • Deprecated GLM_GTX_simd_quat extension
  • Deprecated GLM_SWIZZLE, use GLM_FORCE_SWIZZLE instead
  • Deprecated GLM_MESSAGES, use GLM_FORCE_MESSAGES instead

GLM 0.9.7.6 - 2016-07-16

Improvements:

  • Added pkg-config file #509
  • Updated list of compiler versions detected
  • Improved C++ 11 STL detection #523

Fixes:

  • Fixed STL for C++11 detection on ICC #510
  • Fixed missing vec1 overload to length2 and distance2 functions #431
  • Fixed long long warnings when using C++98 on GCC and Clang #482
  • Fixed scalar reciprocal functions (GTC_reciprocal) #520

GLM 0.9.7.5 - 2016-05-24

Improvements:

  • Added Visual C++ Clang toolset detection

Fixes:

  • Fixed uaddCarry warning #497
  • Fixed roundPowerOfTwo and floorPowerOfTwo #503
  • Fixed Visual C++ SIMD instruction set automatic detection in 64 bits
  • Fixed to_string when used with GLM_FORCE_INLINE #506
  • Fixed GLM_FORCE_INLINE with binary vec4 operators
  • Fixed GTX_extended_min_max filename typo #386
  • Fixed intersectRayTriangle to not do any unintentional backface culling

GLM 0.9.7.4 - 2016-03-19

Fixes:

  • Fixed asinh and atanh warning with C++98 STL #484
  • Fixed polar coordinates function latitude #485
  • Fixed outerProduct defintions and operator signatures for mat2x4 and vec4 #475
  • Fixed eulerAngles precision error, returns NaN #451
  • Fixed undefined reference errors #489
  • Fixed missing GLM_PLATFORM_CYGWIN declaration #495
  • Fixed various undefined reference errors #490

GLM 0.9.7.3 - 2016-02-21

Improvements:

  • Added AVX512 detection

Fixes:

  • Fixed CMake policy warning
  • Fixed GCC 6.0 detection #477
  • Fixed Clang build on Windows #479
  • Fixed 64 bits constants warnings on GCC #463

GLM 0.9.7.2 - 2016-01-03

Fixes:

  • Fixed GTC_round floorMultiple/ceilMultiple #412
  • Fixed GTC_packing unpackUnorm3x10_1x2 #414
  • Fixed GTC_matrix_inverse affineInverse #192
  • Fixed ICC on Linux build errors #449
  • Fixed ldexp and frexp compilation errors
  • Fixed "Declaration shadows a field" warning #468
  • Fixed 'GLM_COMPILER_VC2005 is not defined' warning #468
  • Fixed various 'X is not defined' warnings #468
  • Fixed missing unary + operator #435
  • Fixed Cygwin build errors when using C++11 #405

GLM 0.9.7.1 - 2015-09-07

Improvements:

  • Improved constexpr for constant functions coverage #198
  • Added to_string for quat and dual_quat in GTX_string_cast #375
  • Improved overall execution time of unit tests #396

Fixes:

  • Fixed strict alignment warnings #235 #370
  • Fixed link errors on compilers not supported default function #377
  • Fixed compilation warnings in vec4
  • Fixed non-identity quaternions for equal vectors #234
  • Fixed excessive GTX_fast_trigonometry execution time #396
  • Fixed Visual Studio 2015 'hides class member' warnings #394
  • Fixed builtin bitscan never being used #392
  • Removed unused func_noise.* files #398

GLM 0.9.7.0 - 2015-08-02

Features:

  • Added GTC_color_space: convertLinearToSRGB and convertSRGBToLinear functions
  • Added 'fmod' overload to GTX_common with tests #308
  • Left handed perspective and lookAt functions #314
  • Added functions eulerAngleXYZ and extractEulerAngleXYZ #311
  • Added <glm/gtx/hash.hpp> to perform std::hash on GLM types #320 #367
  • Added <glm/gtx/wrap.hpp> for texcoord wrapping
  • Added static components and precision members to all vector and quat types #350
  • Added .gitignore #349
  • Added support of defaulted functions to GLM types, to use them in unions #366

Improvements:

  • Changed usage of __has_include to support Intel compiler #307
  • Specialized integer implementation of YCoCg-R #310
  • Don't show status message in 'FindGLM' if 'QUIET' option is set. #317
  • Added master branch continuous integration service on Linux 64 #332
  • Clarified manual regarding angle unit in GLM, added FAQ 11 #326
  • Updated list of compiler versions

Fixes:

  • Fixed default precision for quat and dual_quat type #312
  • Fixed (u)int64 MSB/LSB handling on BE archs #306
  • Fixed multi-line comment warning in g++. #315
  • Fixed specifier removal by 'std::make_pair<>' #333
  • Fixed perspective fovy argument documentation #327
  • Removed -m64 causing build issues on Linux 32 #331
  • Fixed isfinite with C++98 compilers #343
  • Fixed Intel compiler build error on Linux #354
  • Fixed use of libstdc++ with Clang #351
  • Fixed quaternion pow #346
  • Fixed decompose warnings #373
  • Fixed matrix conversions #371

Deprecation:

  • Removed integer specification for 'mod' in GTC_integer #308
  • Removed GTX_multiple, replaced by GTC_round

GLM 0.9.6.3 - 2015-02-15

  • Fixed Android doesn't have C++ 11 STL #284

GLM 0.9.6.2 - 2015-02-15

Features:

  • Added display of GLM version with other GLM_MESSAGES
  • Added ARM instruction set detection

Improvements:

  • Removed assert for perspective with zFar < zNear #298
  • Added Visual Studio natvis support for vec1, quat and dualqual types
  • Cleaned up C++11 feature detections
  • Clarify GLM licensing

Fixes:

  • Fixed faceforward build #289
  • Fixed conflict with Xlib #define True 1 #293
  • Fixed decompose function VS2010 templating issues #294
  • Fixed mat4x3 = mat2x3 * mat4x2 operator #297
  • Fixed warnings in F2x11_1x10 packing function in GTC_packing #295
  • Fixed Visual Studio natvis support for vec4 #288
  • Fixed GTC_packing packnormx build and added tests #292
  • Disabled GTX_scalar_multiplication for GCC, failing to build tests #242
  • Fixed Visual C++ 2015 constexpr errors: Disabled only partial support
  • Fixed functions not inlined with Clang #302
  • Fixed memory corruption (undefined behaviour) #303

GLM 0.9.6.1 - 2014-12-10

Features:

  • Added GLM_LANG_CXX14_FLAG and GLM_LANG_CXX1Z_FLAG language feature flags
  • Added C++14 detection

Improvements:

  • Clean up GLM_MESSAGES compilation log to report only detected capabilities

Fixes:

  • Fixed scalar uaddCarry build error with Cuda #276
  • Fixed C++11 explicit conversion operators detection #282
  • Fixed missing explicit conversion when using integer log2 with *vec1 types
  • Fixed 64 bits integer GTX_string_cast to_string on VC 32 bit compiler
  • Fixed Android build issue, STL C++11 is not supported by the NDK #284
  • Fixed unsupported _BitScanForward64 and _BitScanReverse64 in VC10
  • Fixed Visual C++ 32 bit build #283
  • Fixed GLM_FORCE_SIZE_FUNC pragma message
  • Fixed C++98 only build
  • Fixed conflict between GTX_compatibility and GTC_quaternion #286
  • Fixed C++ language restriction using GLM_FORCE_CXX**

GLM 0.9.6.0 - 2014-11-30

Features:

  • Exposed template vector and matrix types in 'glm' namespace #239, #244
  • Added GTX_scalar_multiplication for C++ 11 compiler only #242
  • Added GTX_range for C++ 11 compiler only #240
  • Added closestPointOnLine function for tvec2 to GTX_closest_point #238
  • Added GTC_vec1 extension, *vec1 support to vec types
  • Updated GTX_associated_min_max with vec1 support
  • Added support of precision and integers to linearRand #230
  • Added Integer types support to GTX_string_cast #249
  • Added vec3 slerp #237
  • Added GTX_common with isdenomal #223
  • Added GLM_FORCE_SIZE_FUNC to replace .length() by .size() #245
  • Added GLM_FORCE_NO_CTOR_INIT
  • Added 'uninitialize' to explicitly not initialize a GLM type
  • Added GTC_bitfield extension, promoted GTX_bit
  • Added GTC_integer extension, promoted GTX_bit and GTX_integer
  • Added GTC_round extension, promoted GTX_bit
  • Added GLM_FORCE_EXPLICIT_CTOR to require explicit type conversions #269
  • Added GTX_type_aligned for aligned vector, matrix and quaternion types

Improvements:

  • Rely on C++11 to implement isinf and isnan
  • Removed GLM_FORCE_CUDA, Cuda is implicitly detected
  • Separated Apple Clang and LLVM compiler detection
  • Used pragma once
  • Undetected C++ compiler automatically compile with GLM_FORCE_CXX98 and GLM_FORCE_PURE
  • Added not function (from GLSL specification) on VC12
  • Optimized bitfieldReverse and bitCount functions
  • Optimized findLSB and findMSB functions.
  • Optimized matrix-vector multiple performance with Cuda #257, #258
  • Reduced integer type redifinitions #233
  • Rewrited of GTX_fast_trigonometry #264 #265
  • Made types trivially copyable #263
  • Removed in GLM tests
  • Used std features within GLM without redeclaring
  • Optimized cot function #272
  • Optimized sign function #272
  • Added explicit cast from quat to mat3 and mat4 #275

Fixes:

  • Fixed std::nextafter not supported with C++11 on Android #217
  • Fixed missing value_type for dual quaternion
  • Fixed return type of dual quaternion length
  • Fixed infinite loop in isfinite function with GCC #221
  • Fixed Visual Studio 14 compiler warnings
  • Fixed implicit conversion from another tvec2 type to another tvec2 #241
  • Fixed lack of consistency of quat and dualquat constructors
  • Fixed uaddCarray #253
  • Fixed float comparison warnings #270

Deprecation:

  • Requires Visual Studio 2010, GCC 4.2, Apple Clang 4.0, LLVM 3.0, Cuda 4, ICC 2013 or a C++98 compiler
  • Removed degrees for function parameters
  • Removed GLM_FORCE_RADIANS, active by default
  • Removed VC 2005 / 8 and 2008 / 9 support
  • Removed GCC 3.4 to 4.3 support
  • Removed LLVM GCC support
  • Removed LLVM 2.6 to 3.1 support
  • Removed CUDA 3.0 to 3.2 support

GLM 0.9.5.4 - 2014-06-21

  • Fixed non-utf8 character #196
  • Added FindGLM install for CMake #189
  • Fixed GTX_color_space - saturation #195
  • Fixed glm::isinf and glm::isnan for with Android NDK 9d #191
  • Fixed builtin GLM_ARCH_SSE4 #204
  • Optimized Quaternion vector rotation #205
  • Fixed missing doxygen @endcond tag #211
  • Fixed instruction set detection with Clang #158
  • Fixed orientate3 function #207
  • Fixed lerp when cosTheta is close to 1 in quaternion slerp #210
  • Added GTX_io for io with #144
  • Fixed fastDistance ambiguity #215
  • Fixed tweakedInfinitePerspective #208 and added user-defined epsilon to tweakedInfinitePerspective
  • Fixed std::copy and std::vector with GLM types #214
  • Fixed strict aliasing issues #212, #152
  • Fixed std::nextafter not supported with C++11 on Android #213
  • Fixed corner cases in exp and log functions for quaternions #199

GLM 0.9.5.3 - 2014-04-02

  • Added instruction set auto detection with Visual C++ using _M_IX86_FP - /arch compiler argument
  • Fixed GTX_raw_data code dependency
  • Fixed GCC instruction set detection
  • Added GLM_GTX_matrix_transform_2d extension (#178, #176)
  • Fixed CUDA issues (#169, #168, #183, #182)
  • Added support for all extensions but GTX_string_cast to CUDA
  • Fixed strict aliasing warnings in GCC 4.8.1 / Android NDK 9c (#152)
  • Fixed missing bitfieldInterleave definisions
  • Fixed usubBorrow (#171)
  • Fixed eulerAngle*** not consistent for right-handed coordinate system (#173)
  • Added full tests for eulerAngle*** functions (#173)
  • Added workaround for a CUDA compiler bug (#186, #185)

GLM 0.9.5.2 - 2014-02-08

  • Fixed initializer list ambiguity (#159, #160)
  • Fixed warnings with the Android NDK 9c
  • Fixed non power of two matrix products
  • Fixed mix function link error
  • Fixed SSE code included in GLM tests on "pure" platforms
  • Fixed undefined reference to fastInverseSqrt (#161)
  • Fixed GLM_FORCE_RADIANS with <glm/ext.hpp> build error (#165)
  • Fix dot product clamp range for vector angle functions. (#163)
  • Tentative fix for strict aliasing warning in GCC 4.8.1 / Android NDK 9c (#152)
  • Fixed GLM_GTC_constants description brief (#162)

GLM 0.9.5.1 - 2014-01-11

  • Fixed angle and orientedAngle that sometimes return NaN values (#145)
  • Deprecated degrees for function parameters and display a message
  • Added possible static_cast conversion of GLM types (#72)
  • Fixed error 'inverse' is not a member of 'glm' from glm::unProject (#146)
  • Fixed mismatch between some declarations and definitions
  • Fixed inverse link error when using namespace glm; (#147)
  • Optimized matrix inverse and division code (#149)
  • Added intersectRayPlane function (#153)
  • Fixed outerProduct return type (#155)

GLM 0.9.5.0 - 2013-12-25

  • Added forward declarations (glm/fwd.hpp) for faster compilations
  • Added per feature headers
  • Minimized GLM internal dependencies
  • Improved Intel Compiler detection
  • Added bitfieldInterleave and _mm_bit_interleave_si128 functions
  • Added GTX_scalar_relational
  • Added GTX_dual_quaternion
  • Added rotation function to GTX_quaternion (#22)
  • Added precision variation of each type
  • Added quaternion comparison functions
  • Fixed GTX_multiple for negative value
  • Removed GTX_ocl_type extension
  • Fixed post increment and decrement operators
  • Fixed perspective with zNear == 0 (#71)
  • Removed l-value swizzle operators
  • Cleaned up compiler detection code for unsupported compilers
  • Replaced C cast by C++ casts
  • Fixed .length() that should return a int and not a size_t
  • Added GLM_FORCE_SIZE_T_LENGTH and glm::length_t
  • Removed unnecessary conversions
  • Optimized packing and unpacking functions
  • Removed the normalization of the up argument of lookAt function (#114)
  • Added low precision specializations of inversesqrt
  • Fixed ldexp and frexp implementations
  • Increased assert coverage
  • Increased static_assert coverage
  • Replaced GLM traits by STL traits when possible
  • Allowed including individual core feature
  • Increased unit tests completness
  • Added creating of a quaternion from two vectors
  • Added C++11 initializer lists
  • Fixed umulExtended and imulExtended implementations for vector types (#76)
  • Fixed CUDA coverage for GTC extensions
  • Added GTX_io extension
  • Improved GLM messages enabled when defining GLM_MESSAGES
  • Hidden matrix _inverse function implementation detail into private section

GLM 0.9.4.6 - 2013-09-20

  • Fixed detection to select the last known compiler if newer version #106
  • Fixed is_int and is_uint code duplication with GCC and C++11 #107
  • Fixed test suite build while using Clang in C++11 mode
  • Added c++1y mode support in CMake test suite
  • Removed ms extension mode to CMake when no using Visual C++
  • Added pedantic mode to CMake test suite for Clang and GCC
  • Added use of GCC frontend on Unix for ICC and Visual C++ fronted on Windows for ICC
  • Added compilation errors for unsupported compiler versions
  • Fixed glm::orientation with GLM_FORCE_RADIANS defined #112
  • Fixed const ref issue on assignment operator taking a scalar parameter #116
  • Fixed glm::eulerAngleY implementation #117

GLM 0.9.4.5 - 2013-08-12

  • Fixed CUDA support
  • Fixed inclusion of intrinsics in "pure" mode #92
  • Fixed language detection on GCC when the C++0x mode isn't enabled #95
  • Fixed issue #97: register is deprecated in C++11
  • Fixed issue #96: CUDA issues
  • Added Windows CE detection #92
  • Added missing value_ptr for quaternions #99

GLM 0.9.4.4 - 2013-05-29

  • Fixed slerp when costheta is close to 1 #65
  • Fixed mat4x2 value_type constructor #70
  • Fixed glm.natvis for Visual C++ 12 #82
  • Added assert in inversesqrt to detect division by zero #61
  • Fixed missing swizzle operators #86
  • Fixed CUDA warnings #86
  • Fixed GLM natvis for VC11 #82
  • Fixed GLM_GTX_multiple with negative values #79
  • Fixed glm::perspective when zNear is zero #71

GLM 0.9.4.3 - 2013-03-20

  • Detected qualifier for Clang
  • Fixed C++11 mode for GCC, couldn't be enabled without MS extensions
  • Fixed squad, intermediate and exp quaternion functions
  • Fixed GTX_polar_coordinates euclidean function, takes a vec2 instead of a vec3
  • Clarify the license applying on the manual
  • Added a docx copy of the manual
  • Fixed GLM_GTX_matrix_interpolation
  • Fixed isnan and isinf on Android with Clang
  • Autodetected C++ version using __cplusplus value
  • Fixed mix for bool and bvec* third parameter

GLM 0.9.4.2 - 2013-02-14

  • Fixed compAdd from GTX_component_wise
  • Fixed SIMD support for Intel compiler on Windows
  • Fixed isnan and isinf for CUDA compiler
  • Fixed GLM_FORCE_RADIANS on glm::perspective
  • Fixed GCC warnings
  • Fixed packDouble2x32 on Xcode
  • Fixed mix for vec4 SSE implementation
  • Fixed 0x2013 dash character in comments that cause issue in Windows Japanese mode
  • Fixed documentation warnings
  • Fixed CUDA warnings

GLM 0.9.4.1 - 2012-12-22

  • Improved half support: -0.0 case and implicit conversions
  • Fixed Intel Composer Compiler support on Linux
  • Fixed interaction between quaternion and euler angles
  • Fixed GTC_constants build
  • Fixed GTX_multiple
  • Fixed quat slerp using mix function when cosTheta close to 1
  • Improved fvec4SIMD and fmat4x4SIMD implementations
  • Fixed assert messages
  • Added slerp and lerp quaternion functions and tests

GLM 0.9.4.0 - 2012-11-18

  • Added Intel Composer Compiler support
  • Promoted GTC_espilon extension
  • Promoted GTC_ulp extension
  • Removed GLM website from the source repository
  • Added GLM_FORCE_RADIANS so that all functions takes radians for arguments
  • Fixed detection of Clang and LLVM GCC on MacOS X
  • Added debugger visualizers for Visual C++ 2012
  • Requires Visual Studio 2005, GCC 4.2, Clang 2.6, Cuda 3, ICC 2013 or a C++98 compiler

GLM 0.9.3.4 - 2012-06-30

  • Added SSE4 and AVX2 detection.
  • Removed VIRTREV_xstream and the incompatibility generated with GCC
  • Fixed C++11 compiler option for GCC
  • Removed MS language extension option for GCC (not fonctionnal)
  • Fixed bitfieldExtract for vector types
  • Fixed warnings
  • Fixed SSE includes

GLM 0.9.3.3 - 2012-05-10

  • Fixed isinf and isnan
  • Improved compatibility with Intel compiler
  • Added CMake test build options: SIMD, C++11, fast math and MS land ext
  • Fixed SIMD mat4 test on GCC
  • Fixed perspectiveFov implementation
  • Fixed matrixCompMult for none-square matrices
  • Fixed namespace issue on stream operators
  • Fixed various warnings
  • Added VC11 support

GLM 0.9.3.2 - 2012-03-15

  • Fixed doxygen documentation
  • Fixed Clang version detection
  • Fixed simd mat4 /= operator

GLM 0.9.3.1 - 2012-01-25

  • Fixed platform detection
  • Fixed warnings
  • Removed detail code from Doxygen doc

GLM 0.9.3.0 - 2012-01-09

  • Added CPP Check project
  • Fixed conflict with Windows headers
  • Fixed isinf implementation
  • Fixed Boost conflict
  • Fixed warnings

GLM 0.9.3.B - 2011-12-12

  • Added support for Chrone Native Client
  • Added epsilon constant
  • Removed value_size function from vector types
  • Fixed roundEven on GCC
  • Improved API documentation
  • Fixed modf implementation
  • Fixed step function accuracy
  • Fixed outerProduct

GLM 0.9.3.A - 2011-11-11

  • Improved doxygen documentation
  • Added new swizzle operators for C++11 compilers
  • Added new swizzle operators declared as functions
  • Added GLSL 4.20 length for vector and matrix types
  • Promoted GLM_GTC_noise extension: simplex, perlin, periodic noise functions
  • Promoted GLM_GTC_random extension: linear, gaussian and various random number generation distribution
  • Added GLM_GTX_constants: provides useful constants
  • Added extension versioning
  • Removed many unused namespaces
  • Fixed half based type contructors
  • Added GLSL core noise functions

GLM 0.9.2.7 - 2011-10-24

  • Added more swizzling constructors
  • Added missing none-squared matrix products

GLM 0.9.2.6 - 2011-10-01

  • Fixed half based type build on old GCC
  • Fixed /W4 warnings on Visual C++
  • Fixed some missing l-value swizzle operators

GLM 0.9.2.5 - 2011-09-20

  • Fixed floatBitToXint functions
  • Fixed pack and unpack functions
  • Fixed round functions

GLM 0.9.2.4 - 2011-09-03

  • Fixed extensions bugs

GLM 0.9.2.3 - 2011-06-08

  • Fixed build issues

GLM 0.9.2.2 - 2011-06-02

  • Expend matrix constructors flexibility
  • Improved quaternion implementation
  • Fixed many warnings across platforms and compilers

GLM 0.9.2.1 - 2011-05-24

  • Automatically detect CUDA support
  • Improved compiler detection
  • Fixed errors and warnings in VC with C++ extensions disabled
  • Fixed and tested GLM_GTX_vector_angle
  • Fixed and tested GLM_GTX_rotate_vector

GLM 0.9.2.0 - 2011-05-09

  • Added CUDA support
  • Added CTest test suite
  • Added GLM_GTX_ulp extension
  • Added GLM_GTX_noise extension
  • Added GLM_GTX_matrix_interpolation extension
  • Updated quaternion slerp interpolation

GLM 0.9.1.3 - 2011-05-07

  • Fixed bugs

GLM 0.9.1.2 - 2011-04-15

  • Fixed bugs

GLM 0.9.1.1 - 2011-03-17

  • Fixed bugs

GLM 0.9.1.0 - 2011-03-03

  • Fixed bugs

GLM 0.9.1.B - 2011-02-13

  • Updated API documentation
  • Improved SIMD implementation
  • Fixed Linux build

GLM 0.9.0.8 - 2011-02-13

  • Added quaternion product operator.
  • Clarify that GLM is a header only library.

GLM 0.9.1.A - 2011-01-31

  • Added SIMD support
  • Added new swizzle functions
  • Improved static assert error message with C++0x static_assert
  • New setup system
  • Reduced branching
  • Fixed trunc implementation

GLM 0.9.0.7 - 2011-01-30

  • Added GLSL 4.10 packing functions
  • Added == and != operators for every types.

GLM 0.9.0.6 - 2010-12-21

  • Many matrices bugs fixed

GLM 0.9.0.5 - 2010-11-01

  • Improved Clang support
  • Fixed bugs

GLM 0.9.0.4 - 2010-10-04

  • Added autoexp for GLM
  • Fixed bugs

GLM 0.9.0.3 - 2010-08-26

  • Fixed non-squared matrix operators

GLM 0.9.0.2 - 2010-07-08

  • Added GLM_GTX_int_10_10_10_2
  • Fixed bugs

GLM 0.9.0.1 - 2010-06-21

  • Fixed extensions errors

GLM 0.9.0.0 - 2010-05-25

  • Objective-C support
  • Fixed warnings
  • Updated documentation

GLM 0.9.B.2 - 2010-04-30

  • Git transition
  • Removed experimental code from releases
  • Fixed bugs

GLM 0.9.B.1 - 2010-04-03

  • Based on GLSL 4.00 specification
  • Added the new core functions
  • Added some implicit conversion support

GLM 0.9.A.2 - 2010-02-20

  • Improved some possible errors messages
  • Improved declarations and definitions match

GLM 0.9.A.1 - 2010-02-09

  • Removed deprecated features
  • Internal redesign

GLM 0.8.4.4 final - 2010-01-25

  • Fixed warnings

GLM 0.8.4.3 final - 2009-11-16

  • Fixed Half float arithmetic
  • Fixed setup defines

GLM 0.8.4.2 final - 2009-10-19

  • Fixed Half float adds

GLM 0.8.4.1 final - 2009-10-05

  • Updated documentation
  • Fixed MacOS X build

GLM 0.8.4.0 final - 2009-09-16

  • Added GCC 4.4 and VC2010 support
  • Added matrix optimizations

GLM 0.8.3.5 final - 2009-08-11

  • Fixed bugs

GLM 0.8.3.4 final - 2009-08-10

  • Updated GLM according GLSL 1.5 spec
  • Fixed bugs

GLM 0.8.3.3 final - 2009-06-25

  • Fixed bugs

GLM 0.8.3.2 final - 2009-06-04

  • Added GLM_GTC_quaternion
  • Added GLM_GTC_type_precision

GLM 0.8.3.1 final - 2009-05-21

  • Fixed old extension system.

GLM 0.8.3.0 final - 2009-05-06

  • Added stable extensions.
  • Added new extension system.

GLM 0.8.2.3 final - 2009-04-01

  • Fixed bugs.

GLM 0.8.2.2 final - 2009-02-24

  • Fixed bugs.

GLM 0.8.2.1 final - 2009-02-13

  • Fixed bugs.

GLM 0.8.2 final - 2009-01-21

  • Fixed bugs.

GLM 0.8.1 final - 2008-10-30

  • Fixed bugs.

GLM 0.8.0 final - 2008-10-23

  • New method to use extension.

GLM 0.8.0 beta3 - 2008-10-10

  • Added CMake support for GLM tests.

GLM 0.8.0 beta2 - 2008-10-04

  • Improved half scalars and vectors support.

GLM 0.8.0 beta1 - 2008-09-26

  • Improved GLSL conformance
  • Added GLSL 1.30 support
  • Improved API documentation

GLM 0.7.6 final - 2008-08-08

  • Improved C++ standard comformance
  • Added Static assert for types checking

GLM 0.7.5 final - 2008-07-05

  • Added build message system with Visual Studio
  • Pedantic build with GCC

GLM 0.7.4 final - 2008-06-01

  • Added external dependencies system.

GLM 0.7.3 final - 2008-05-24

  • Fixed bugs
  • Added new extension group

GLM 0.7.2 final - 2008-04-27

  • Updated documentation
  • Added preprocessor options

GLM 0.7.1 final - 2008-03-24

  • Disabled half on GCC
  • Fixed extensions

GLM 0.7.0 final - 2008-03-22

  • Changed to MIT license
  • Added new documentation

GLM 0.6.4 - 2007-12-10

  • Fixed swizzle operators

GLM 0.6.3 - 2007-11-05

  • Fixed type data accesses
  • Fixed 3DSMax sdk conflict

GLM 0.6.2 - 2007-10-08

  • Fixed extension

GLM 0.6.1 - 2007-10-07

  • Fixed a namespace error
  • Added extensions

GLM 0.6.0 : 2007-09-16

  • Added new extension namespace mecanium
  • Added Automatic compiler detection

GLM 0.5.1 - 2007-02-19

  • Fixed swizzle operators

GLM 0.5.0 - 2007-01-06

  • Upgrated to GLSL 1.2
  • Added swizzle operators
  • Added setup settings

GLM 0.4.1 - 2006-05-22

  • Added OpenGL examples

GLM 0.4.0 - 2006-05-17

  • Added missing operators to vec* and mat*
  • Added first GLSL 1.2 features
  • Fixed windows.h before glm.h when windows.h required

GLM 0.3.2 - 2006-04-21

  • Fixed texcoord components access.
  • Fixed mat4 and imat4 division operators.

GLM 0.3.1 - 2006-03-28

  • Added GCC 4.0 support under MacOS X.
  • Added GCC 4.0 and 4.1 support under Linux.
  • Added code optimisations.

GLM 0.3 - 2006-02-19

  • Improved GLSL type conversion and construction compliance.
  • Added experimental extensions.
  • Added Doxygen Documentation.
  • Added code optimisations.
  • Fixed bugs.

GLM 0.2 - 2005-05-05

  • Improve adaptative from GLSL.
  • Add experimental extensions based on OpenGL extension process.
  • Fixe bugs.

GLM 0.1 - 2005-02-21

  • Add vec2, vec3, vec4 GLSL types
  • Add ivec2, ivec3, ivec4 GLSL types
  • Add bvec2, bvec3, bvec4 GLSL types
  • Add mat2, mat3, mat4 GLSL types
  • Add almost all functions
Comments
  • LaTeX-ify the manual

    LaTeX-ify the manual

    Why did I bother?

    • The new manual looks way nicer and more consistent
    • I also cleaned up a lot of text to make it clearer
    • It's easier to contribute to the manual since it's no longer in binary form
    • The compiled manual is half the size of the original .docx

    Just a few things before I think it's ready to merge:

    • [x] Finish proofreading the entire manual
    • [x] Introduce some more macros for adding links to other documentation
    • [x] Test the build process for the manual on Mac and Windows
    • [x] Better document the build process for the manual (especially packages that need to be installed)
    • [x] See what role minted should play in the build process (it does source highlighting, but it has some other dependencies; I need to see what these dependencies are)
    • [x] Adding a few images that were in the original manual (e.g. one of your duck photos)
    • [ ] Figure out why the figures (e.g. of the noise and random extensions) aren't all on contiguous pages
    • [x] ~~You should probably put a build of the manual on the official website, too~~ Not going to happen, as discussed below, and I'm in no position to argue otherwise

    Thoughts so far?

    enhancement 
    opened by JesseTG 23
  • Add Simpler GLM CMake Config

    Add Simpler GLM CMake Config

    This PR adds back in a CMake package config to allow finding GLM with CMake, with some improvements over the original one:

    • It's no longer necessary to "build" glm to generate the CMake config file to use, this is now just included in the root of the repository. As a result the CMake config is also easy to package in the release archives as well, since it's as easy as including glmConfig.cmake and glmConfig-version.cmake in the zip file. An important note is that the version number tracked in these files must be updated for each release, since it's no longer generated during the CMake build.

    • Added a test to verify the CMake package works on Travis and Appveyor (https://github.com/Twinklebear/glm/tree/master/test/cmake)

    • Documentation in the manual on how to find GLM from CMake (https://github.com/Twinklebear/glm/blob/master/manual.md#section1_5)

    How the new glmConfig.cmake and glmConfig-version.cmake work:

    In CMake 3 the method for finding libraries has gotten a lot easier, when calling find_package(<library>) if the user passes -D<library>_DIR=<path> CMake will check that path for the library's package files (<library>Config.cmake). If a version is specified as find_package(<library> 0.9.8) it will use the <library>Config-version.cmake file to check if the version is suitable.

    The library CMake packages can then export variables (2.x style) or targets (3.x style) which the user's code can use or link against. For header only libraries like glm we can use an INTERFACE target, which lets us set include directories, dependencies and compile options, but doesn't actually refer to any compiled libraries or code. The properties set on this target then get propagated to the user's code:

    cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
    cmake_policy(VERSION 3.2)
    
    set(GLM_VERSION 0.9.9)
    # Set the old GLM_INCLUDE_DIRS variable for backwards compatibility
    set(GLM_INCLUDE_DIRS ${CMAKE_CURRENT_LIST_DIR})
    
    # We define a new interface target glm::glm which is being imported from
    # some existing code
    add_library(glm::glm INTERFACE IMPORTED)
    # If the user links our target against some library, the following directories
    # will be added to their target's include directories
    set_target_properties(glm::glm PROPERTIES
        INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_CURRENT_LIST_DIR})
    # Hide the glm_DIR parameter in the CMake UI
    mark_as_advanced(glm_DIR)
    

    Now in the user's CMakeLists:

    cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
    project(test_find_glm)
    
    find_package(glm REQUIRED)
    
    add_executable(test_find_glm test_find_glm.cpp)
    # "Linking" the glm interface target will have the same effect as
    # target_include_directories(test_find_glm ${GLM_INCLUDE_DIRS})
    target_link_libraries(test_find_glm glm::glm)
    
    opened by Twinklebear 16
  • Add missing cols/rows constants

    Add missing cols/rows constants

    Should I add anything like rows or cols to the vector type traits? Because they can be treated as either column vectors or row vectors, so I dunno...

    opened by JesseTG 14
  • Create an install and package targets in cmake tree

    Create an install and package targets in cmake tree

    This PR should hopefully clear up some of the confusion about how CMake should be finding GLM. It should also make it easier for package maintainers with the packages being generated by CPack.

    CMake should now be able to use its internal templates to generate appropriate glmConfig.cmake and glmConfigVersion.cmake files. Those files should be installed by the install target, as well as included in the CPack packages.

    opened by kiroma 10
  • Templatize most (if not all) unary GLM conversions

    Templatize most (if not all) unary GLM conversions

    Now you can seamlessly convert between a bvec3 and a uvec4. Also added constructors for converting smaller vector types to larger ones (the extra components are set to zero).

    enhancement 
    opened by JesseTG 10
  • Dedicated extension to represent angle values

    Dedicated extension to represent angle values

    Hi, in my experience dealing with angles has always been a source of bugs and headaches if an API/software only uses plain floats to represent them. It immediately raises the question "radians or degrees?" and often goes wrong either because people don't read the documentation or the API itself is inconsistent.

    As a consequence in any project I come to I always have to introduce a dedicated class to encapsulate angles and provide only explicit factory methods which are unambiguous about whether it is in degrees or radians. The class is then treated as having a dimension and supports only operations which do not violate dimensional analysis. Using this type consistently in the entire codebase saves one lots of trouble, and the reduced number of manual rad/deg conversions can potentially speed things up. The class follows value semantics and is no bigger and no less efficient than a plain float or double, only the factory/extraction methods do more work than is evident from code. alpha + beta does really only a single addition and nothing more. Operations which do not rely on std or glm functions are constexpr if the compiler supports it.

    This pull request adds an extension with such a class: tangle<T, P> with the convenience typedefs fangle (sadly angle is already taken) and dangle. Creating an instance requires one to explicitly state the kind of unit to use:

    // radians() and degrees() are already taken by glm
    alpha = glm::rad(3.14f); // :: float -> angle
    beta = glm::deg(270.f);  // :: float -> angle
    

    The operations supported on tangle do not misbehave under dimensional analysis and therefore allow the compiler to tell if the type is misused in an equation that doesn't make sense.

    alpha + beta;     // :: angle + angle -> angle
    alpha - beta;     // :: angle - angle -> angle
    5.f * alpha;      // :: float * angle -> angle
    alpha / beta;     // :: angle / angle -> float
    alpha / 5.f;      // :: angle / float -> angle
    mod(alpha, beta); // :: angle % angle -> angle
    
    1.f / alpha;  // Error: unit is angle^-1
    alpha * beta; // Error: unit is angle^2
    

    tangle's interface is deliberately agnostic to the actual unit stored inside, if one does require the actual numeric value it must be extracted from it (which should only happen on foreign API boundaries):

    someExternalFunctionTakingRadians(rad(alpha), rad(beta));
    someExternalFunctionTakingDegrees(deg(alpha), deg(beta));
    

    Overloads to common functions are provided accepting angle instances:

    cosine = cos(alpha); // :: angle -> float
    sine = sin(alpha);   // :: angle -> float
    tangent = tan(beta); // :: angle -> float
    
    delta = abs(alpha);
    gamma = clamp(delta, alpha, beta);
    // Others: max, min, mix, sign
    
    // Inverse trigonometric not possible due to conflict with existing functions :(
    delta = acos(1.f);   // :: float -> angle
    gamma = asin(2.f);   // :: float -> angle
    epsilon = atan(3.f); // :: float -> angle
    // Workaround:
    delta = rad(acos(1.f));   // :: float -> float -> angle
    gamma = rad(asin(2.f));   // :: float -> float -> angle
    epsilon = rad(atan(3.f)); // :: float -> float -> angle
    

    There are also two special functions only applicable to angles that I find frequently used:

    gamma = normalize(alpha); // Converts the stored magnitude so it lies within [0; 2pi)
    // Compute the shortest distance between two normalized angles.
    // Result is always in range [-pi;+pi] (undefined if both inputs not normalized)
    delta = distance(alpha, beta);
    // This always animates using the shortest path without doing a 360.
    // (assuming from and to are normalized)
    interpolated = mix(from, from + distance(from, to), t);
    

    There are also optional overloads of other GTC/GTX functions replacing float arguments with angles where applicable, one simply has to include the extension header first to enable them.

    Let me know what you think and if there's anything crucially important missing. I look forward to a world where nobody uses plain floats in their code for angles anymore. Changing the existing GLM functions would certainly break existing code, but maybe this can be part of 2.0 or something :)

    Miro

    enhancement 
    opened by mknejp 9
  • Extension for Euler angles

    Extension for Euler angles

    This PR adds the following:

    • Creates the derived matrix from the rotation matrix about the X-, Y-, and Z-axis
    • Creates the rotation matrix from the Euler angles (intrinsic rotations): Proper Euler angles (z-x-z, x-y-x, y-z-y, z-y-z, x-z-x, y-x-y) Tait–Bryan angles (y-z-x, z-x-y, x-z-y, z-y-x).
    • Extracts the Euler angles from the rotation matrix (intrinsic rotations): Proper Euler angles (z-x-z, x-y-x, y-z-y, z-y-z, x-z-x, y-x-y) Tait–Bryan angles (y-z-x, z-x-y, x-z-y, z-y-x, y-x-z).
    • Tests for these features
    extension feature 
    opened by vitali-parkhomenko 8
  • Fix clang version detection

    Fix clang version detection

    I needed to make a minor change to get the clang version detection to work in my project (on linux). I noticed that the platform define was being tested against a compiler define which seemed strange. I made this adjustment on my side to fix the issue but please let me know if there is a more appropriate solution

    opened by pmcmorris 8
  • Implemented 'principle component analysis' utility in gtx

    Implemented 'principle component analysis' utility in gtx

    PCA (principle component analysis) is a handy utility to analyze the spatial distribution of points. It can be used to compute object-oriented bounding boxes, arbitrary bsp-tree creation, etc. I used it in previous works together with particle data.

    I maybe went a little overboard with the tests....

    enhancement extension 
    opened by sgrottel 7
  • Fix quaternion orientation in `glm::decompose`

    Fix quaternion orientation in `glm::decompose`

    Between 0.9.8 and 0.9.9 a change to the implementation of decompose caused the conjugate of the rotation quaternion to be returned. This has also been noted in this Stack Overflow question, in particular this comment. This seems like a regression that ought to be fixed to avoid having to conjugate the result of decompose in the future.

    bug 
    opened by bosmacs 6
  • Fix loss of precision on small angles in qua's pow

    Fix loss of precision on small angles in qua's pow

    I encountered loss of precision when using quaternions with very small angles with the function pow(). This is because it determines the angle in the quaternion by applying acos() to the scale component w, which is equal to 1. because of dramatic cancellation.

    However, it is still possible to recover an accurate angle by looking at the non-scale components (which are then very close to, but different than, 0.) and using asin(). I have written a fix to verify that this was possible, and it might be useful to merge it into the project.

    I have tried to take non-normalized quaternions into account, but I may have missed something. Any feedback is welcome.

    Edit: I have included a similar fix for qua's angle() function

    enhancement 
    opened by qsantos 6
  • ci: Add AppVeyor testing support for C++20 and VS2022

    ci: Add AppVeyor testing support for C++20 and VS2022

    • Add VS 2022 to test matrix
    • Only build for C++20 with VS 2022
    • Reorder build with newest variants first, so they get built first.
    • Build VS2022 and VS2019 with Ninja; build time is 2.5 minutes per variant which is a good reduction from the previous 15 minutes per variant.
    opened by rleigh-codelibre 4
  • Make vec4, mat4x3 and mat4x4 binary operators and contructors for scalars consistent with other types

    Make vec4, mat4x3 and mat4x4 binary operators and contructors for scalars consistent with other types

    Binary operators with a scalar type generally use T scalar in the signature:

    $ git grep 'operator.*\*.*scalar' "glm/**.hpp"
    glm/detail/type_mat2x2.hpp:     GLM_FUNC_DECL mat<2, 2, T, Q> operator*(mat<2, 2, T, Q> const& m, T scalar);
    glm/detail/type_mat2x2.hpp:     GLM_FUNC_DECL mat<2, 2, T, Q> operator*(T scalar, mat<2, 2, T, Q> const& m);
    glm/detail/type_mat2x3.hpp:     GLM_FUNC_DECL mat<2, 3, T, Q> operator*(mat<2, 3, T, Q> const& m, T scalar);
    glm/detail/type_mat2x3.hpp:     GLM_FUNC_DECL mat<2, 3, T, Q> operator*(T scalar, mat<2, 3, T, Q> const& m);
    glm/detail/type_mat2x4.hpp:     GLM_FUNC_DECL mat<2, 4, T, Q> operator*(mat<2, 4, T, Q> const& m, T scalar);
    glm/detail/type_mat2x4.hpp:     GLM_FUNC_DECL mat<2, 4, T, Q> operator*(T scalar, mat<2, 4, T, Q> const& m);
    glm/detail/type_mat3x2.hpp:     GLM_FUNC_DECL mat<3, 2, T, Q> operator*(mat<3, 2, T, Q> const& m, T scalar);
    glm/detail/type_mat3x2.hpp:     GLM_FUNC_DECL mat<3, 2, T, Q> operator*(T scalar, mat<3, 2, T, Q> const& m);
    glm/detail/type_mat3x3.hpp:     GLM_FUNC_DECL mat<3, 3, T, Q> operator*(mat<3, 3, T, Q> const& m, T scalar);
    glm/detail/type_mat3x3.hpp:     GLM_FUNC_DECL mat<3, 3, T, Q> operator*(T scalar, mat<3, 3, T, Q> const& m);
    glm/detail/type_mat3x4.hpp:     GLM_FUNC_DECL mat<3, 4, T, Q> operator*(mat<3, 4, T, Q> const& m, T scalar);
    glm/detail/type_mat3x4.hpp:     GLM_FUNC_DECL mat<3, 4, T, Q> operator*(T scalar, mat<3, 4, T, Q> const& m);
    glm/detail/type_mat4x2.hpp:     GLM_FUNC_DECL mat<4, 2, T, Q> operator*(mat<4, 2, T, Q> const& m, T scalar);
    glm/detail/type_mat4x2.hpp:     GLM_FUNC_DECL mat<4, 2, T, Q> operator*(T scalar, mat<4, 2, T, Q> const& m);
    glm/detail/type_vec1.hpp:               GLM_FUNC_DECL GLM_CONSTEXPR vec<1, T, Q> & operator*=(U scalar);
    glm/detail/type_vec1.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<1, T, Q> operator*(vec<1, T, Q> const& v, T scalar);
    glm/detail/type_vec1.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<1, T, Q> operator*(T scalar, vec<1, T, Q> const& v);
    glm/detail/type_vec2.hpp:               GLM_FUNC_DECL GLM_CONSTEXPR vec<2, T, Q> & operator*=(U scalar);
    glm/detail/type_vec2.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<2, T, Q> operator*(vec<2, T, Q> const& v, T scalar);
    glm/detail/type_vec2.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<2, T, Q> operator*(T scalar, vec<2, T, Q> const& v);
    glm/detail/type_vec3.hpp:               GLM_FUNC_DECL GLM_CONSTEXPR vec<3, T, Q> & operator*=(U scalar);
    glm/detail/type_vec3.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<3, T, Q> operator*(vec<3, T, Q> const& v, T scalar);
    glm/detail/type_vec3.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<3, T, Q> operator*(T scalar, vec<3, T, Q> const& v);
    glm/detail/type_vec4.hpp:               GLM_FUNC_DECL GLM_CONSTEXPR vec<4, T, Q>& operator*=(U scalar);
    glm/detail/type_vec4.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<4, T, Q> operator*(vec<4, T, Q> const& v, T const & scalar);
    glm/detail/type_vec4.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<4, T, Q> operator*(T scalar, vec<4, T, Q> const& v);
    

    vec4 is different, as are mat4x3 and mat4x4:

    $ git grep 'operator.*\*.*scalar' "glm/**.hpp" | grep "T const"
    glm/detail/type_vec4.hpp:       GLM_FUNC_DECL GLM_CONSTEXPR vec<4, T, Q> operator*(vec<4, T, Q> const& v, T const & scalar);
    

    This change updates the signatures for the vec4, mat4x3 and mat4x4 types to match those of the other vector and matrix type binary operators.

    I noticed this when writing Lua/Sol2 bindings for GLM and found that the signatures were not compatible. Here's an example of the binding of vec3 vs vec4 for the basic operators:

      state.new_usertype<glm::vec3>(
          "vec3",
          sol::constructors<glm::vec3(), glm::vec3(float const &),
                            glm::vec3(float const &, float const &, float const &)>(),
          sol::meta_function::multiplication,
          sol::overload(
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec3 const &)>(
                  &glm::operator*),
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec1 const &)>(
                  &glm::operator*),
              sol::resolve<glm::vec3(glm::vec3 const &, float)>(&glm::operator*)),
          sol::meta_function::division,
          sol::overload(
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec3 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec3(glm::vec3 const &, float)>(&glm::operator/)),
          sol::meta_function::addition,
          sol::overload(
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec3 const &)>(
                  &glm::operator+),
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec3(glm::vec3 const &, float)>(&glm::operator/)),
          sol::meta_function::subtraction,
          sol::overload(
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec3 const &)>(
                  &glm::operator-),
              sol::resolve<glm::vec3(glm::vec3 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec3(glm::vec3 const &, float)>(&glm::operator/)),
          sol::meta_function::index,
          sol::resolve<const float &(glm::vec3 const &, glm::length_t)>(fetchIndex),
          sol::meta_function::new_index,
          sol::resolve<void(glm::vec3 &, glm::length_t, float const &)>(
              storeIndex));
    
      state.new_usertype<glm::vec4>(
          "vec4",
          sol::constructors<glm::vec4(), glm::vec4(float const &),
                            glm::vec4(float const &, float const &, float const &, float const &)>(),
          sol::meta_function::multiplication,
          sol::overload(
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec4 const &)>(
                  &glm::operator*),
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec1 const &)>(
                  &glm::operator*),
              sol::resolve<glm::vec4(glm::vec4 const &, float const &)>(
                  &glm::operator*)),
          sol::meta_function::division,
          sol::overload(
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec4 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec4(glm::vec4 const &, float const &)>(
                  &glm::operator/)),
          sol::meta_function::addition,
          sol::overload(
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec4 const &)>(
                  &glm::operator+),
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec4(glm::vec4 const &, float const &)>(
                  &glm::operator/)),
          sol::meta_function::subtraction,
          sol::overload(
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec4 const &)>(
                  &glm::operator-),
              sol::resolve<glm::vec4(glm::vec4 const &, glm::vec1 const &)>(
                  &glm::operator/),
              sol::resolve<glm::vec4(glm::vec4 const &, float const &)>(
                  &glm::operator/)),
          sol::meta_function::index,
          sol::resolve<const float &(glm::vec4 const &, glm::length_t)>(fetchIndex),
          sol::meta_function::new_index,
          sol::resolve<void(glm::vec4 &, glm::length_t, float const &)>(
              storeIndex));
    

    Note the float const& in the vec4 case vs the float in the vec3 case (likewise for vec2 and vec1).

    Note: I have not yet wrapped all overloads, just vecn, vec1 and float for each operator.

    For ease of writing bindings, having consistency would enable more generalised template functions to be written to automate the wrapping.

    enhancement 
    opened by rleigh-codelibre 1
  • build: various install improvements

    build: various install improvements

    With this PR I've made two main improvements:

    • Moved install location of the .cmake files from lib/ to share/
    • (re)added a pkg-config file

    Also, please don't squash this PR on merge, otherwise all the information in the commits will be lost. Thanks :)

    Here are the commit messages:

    1. As GLM is a header-only library, its cmake config files should be installed to share/ (GNUInstallDirs' DATADIR), as share/ is the canonical directory where architecture-independent files should be stored, while lib/ is for architecture-dependent stuff (see the FHS).

      Apart from being technically correct, installing to share/ can help with cross-compiling, for example in Debian-based environments. If you're interested, I'd suggest reading this [thread].

      I've also made a few minor fixes, like moving GNUInstallDirs in the main CMakeLists.txt so that it is accessible project-wide and removed the unneeded include(CPack) directive.

      [thread]: https://github.com/marzer/tomlplusplus/pull/165 (comment)

    2. GLM used to ship a pkg-config file since version 0.9.8.0, added in commit https://github.com/Tachi107/glm/commit/0e018a5262b881e3b49b8a49ae56292ab9a7bb10, but it was removed together with the install target in commit https://github.com/Tachi107/glm/commit/5f352ecce21bb1ab37fa56fac0f383c779b351a3. While the install target was re-added in commit https://github.com/Tachi107/glm/commit/631faffab37bd14f0ac8cec74711d670538a2702, the .pc file has been left behind.

      This patch re-adds it, and, compared to the old one, this pkg-config file also accounts for the cases where GLM is installed in an include directory that is not a subdirectory of the install prefix (i.e. it does the right thing™ when CMAKE_INSTALL_INCLUDEDIR is an absolute path).

      To read why the JoinPaths module is needed, take a look at https://github.com/jtojnar/cmake-snips#concatenating-paths-when-building-pkg-config-files

    opened by Tachi107 0
  • Proposal for major version upgrade

    Proposal for major version upgrade

    Hi, as already discussed with @paulharris in #1108 I would suggest that we increase the version of glm to 1.0.0. I think the current situation of having a version number 0.9.9.9, and not really being able to increase it any further, is just a result of not being able to handle double-digit version numbers because it would interfere with the definition of the GLM_VERSION macro. Instead I would suggest adopting a macro in lieu of VK_MAKE_API_VERSION(major, minor, patch). This would give us room for 1024 minor versions and 4096 patch versions before running out of space in the version number ;)

    For future updates, I would suggest adhering to the semantic versioning rules:

    MAJOR version when you make incompatible API changes MINOR version when you add functionality in a backwards compatible manner PATCH version when you make backwards compatible bug fixes

    Therefore I have included the removal of features marked as deprecated in this PR.

    enhancement 
    opened by tomix1024 1
  • Fix glm::rotate for GLM_FORCE_QUAT_DATA_XYZW configuration

    Fix glm::rotate for GLM_FORCE_QUAT_DATA_XYZW configuration

    GLM_FORCE_QUAT_DATA_XYZW doesn't simply change the data layout, it also changes the meaning of quat constructor. This means that every call inside glm itself that passes 4 arguments needs to check that define.

    This change fixes glm::rotate specifically by relying on scalar+vector ctor (which is stable across configurations), although there are other instances in glm that are likely problematic eg glm::cross.

    opened by zeux 0
Releases(0.9.9.8)
  • 0.9.9.8(Apr 13, 2020)

    Features:

    • Added GLM_EXT_vector_intX* and GLM_EXT_vector_uintX* extensions
    • Added GLM_EXT_matrix_intX* and GLM_EXT_matrix_uintX* extensions

    Improvements:

    • Added clamp, repeat, mirrorClamp and mirrorRepeat function to GLM_EXT_scalar_commond and GLM_EXT_vector_commond extensions with tests

    Fixes:

    • Fixed unnecessary warnings from matrix_projection.inl #995
    • Fixed quaternion slerp overload which interpolates with extra spins #996
    • Fixed for glm::length using arch64 #992
    • Fixed singularity check for quatLookAt #770
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.8.7z(3.26 MB)
    glm-0.9.9.8.zip(5.40 MB)
  • 0.9.9.7(Jan 5, 2020)

    Improvements:

    • Improved Neon support with more functions optimized #950
    • Added CMake GLM interface #963
    • Added fma implementation based on std::fma #969
    • Added missing quat constexpr #955
    • Added GLM_FORCE_QUAT_DATA_WXYZ to store quat data as w,x,y,z instead of x,y,z,w #983

    Fixes:

    • Fixed equal ULP variation when using negative sign #965
    • Fixed for intersection ray/plane and added related tests #953
    • Fixed ARM 64bit detection #949
    • Fixed GLM_EXT_matrix_clip_space warnings #980
    • Fixed Wimplicit-int-float-conversion warnings with clang 10+ #986
    • Fixed EXT_matrix_clip_space perspectiveFov
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.7.7z(3.19 MB)
    glm-0.9.9.7.zip(5.36 MB)
  • 0.9.9.6(Sep 8, 2019)

    Features:

    • Added Neon support to glm #945
    • Added SYCL support #914
    • Added EXT_scalar_integer extension with power of two and multiple scalar functions
    • Added EXT_vector_integer extension with power of two and multiple vector functions

    Improvements:

    • Added Visual C++ 2019 detection
    • Added Visual C++ 2017 15.8 and 15.9 detection
    • Added missing genType check for bitCount and bitfieldReverse #893

    Fixes:

    • Fixed for g++6 where -std=c++1z sets __cplusplus to 201500 instead of 201402 #921
    • Fixed hash hashes qua instead of tquat #919
    • Fixed .natvis as structs renamed #915
    • Fixed ldexp and frexp declaration #895
    • Fixed missing const to quaternion conversion operators #890
    • Fixed EXT_scalar_ulp and EXT_vector_ulp API coding style
    • Fixed quaternion componant order: w, {x, y, z} #916
    • Fixed GLM_HAS_CXX11_STL broken on Clang with Linux #926
    • Fixed Clang or GCC build due to wrong GLM_HAS_IF_CONSTEXPR definition #907
    • Fixed CUDA 9 build #910
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.6.7z(3.20 MB)
    glm-0.9.9.6.zip(5.35 MB)
  • 0.9.9.5(Apr 2, 2019)

  • 0.9.9.4(Mar 19, 2019)

    Features:

    • Added mix implementation for matrices in EXT_matrix_common #842
    • Added BUILD_SHARED_LIBS and BUILD_STATIC_LIBS build options #871

    Improvements:

    • Added GLM_FORCE_INTRINSICS to enable SIMD instruction code path. By default, it's disabled allowing constexpr support by default. #865
    • Optimized inverseTransform #867

    Fixes:

    • Fixed in mat4x3 conversion #829
    • Fixed constexpr issue on GCC #832 #865
    • Fixed mix implementation to improve GLSL conformance #866
    • Fixed int8 being defined as unsigned char with some compiler #839
    • Fixed vec1 include #856
    • Ignore .vscode #848
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.4.7z(3.21 MB)
    glm-0.9.9.4.zip(5.68 MB)
  • 0.9.9.3(Oct 31, 2018)

    Features:

    • Added equal and notEqual overload with max ULPs parameters for scalar numbers #121
    • Added GLM_FORCE_SILENT_WARNINGS to silent GLM warnings when using language extensions but using W4 or Wpedantic warnings #814 #775
    • Added adjugate functions to GTX_matrix_operation #151
    • Added GLM_FORCE_ALIGNED_GENTYPES to enable aligned types and SIMD instruction are not enabled. This disable constexpr #816

    Improvements:

    • Added constant time ULP distance between float #121
    • Added GLM_FORCE_SILENT_WARNINGS to suppress GLM warnings #822

    Fixes:

    • Fixed simplex noise build with double #734
    • Fixed bitfieldInsert according to GLSL spec #818
    • Fixed refract for negative 'k' #808
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.3.7z(3.21 MB)
    glm-0.9.9.3.zip(5.68 MB)
  • 0.9.9.2(Sep 14, 2018)

  • 0.9.9.1(Sep 3, 2018)

    Features:

    • Added bitfieldDeinterleave to GTC_bitfield
    • Added missing equal and notEqual with epsilon for quaternion types to GTC_quaternion
    • Added EXT_matrix_relational: equal and notEqual with epsilon for matrix types
    • Added missing aligned matrix types to GTC_type_aligned
    • Added C++17 detection
    • Added Visual C++ language standard version detection
    • Added PDF manual build from markdown

    Improvements:

    • Added a section to the manual for contributing to GLM
    • Refactor manual, lists all configuration defines
    • Added missing vec1 based constructors
    • Redesigned constexpr support which excludes both SIMD and constexpr #783
    • Added detection of Visual C++ 2017 toolsets
    • Added identity functions #765
    • Splitted headers into EXT extensions to improve compilation time #670
    • Added separated performance tests
    • Clarified refract valid range of the indices of refraction, between -1 and 1 inclusively #806

    Fixes:

    • Fixed SIMD detection on Clang and GCC
    • Fixed build problems due to printf and std::clock_t #778
    • Fixed int mod
    • Anonymous unions require C++ language extensions
    • Fixed ortho #790
    • Fixed Visual C++ 2013 warnings in vector relational code #782
    • Fixed ICC build errors with constexpr #704
    • Fixed defaulted operator= and constructors #791
    • Fixed invalid conversion from int scalar with vec4 constructor when using SSE instruction
    • Fixed infinite loop in random functions when using negative radius values using an assert #739
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.1.7z(3.21 MB)
    glm-0.9.9.1.zip(5.67 MB)
  • 0.9.9.0(May 22, 2018)

    Features:

    • Added RGBM encoding in GTC_packing #420
    • Added GTX_color_encoding extension
    • Added GTX_vec_swizzle, faster compile time swizzling then swizzle operator #558
    • Added GTX_exterior_product with a vec2 cross implementation #621
    • Added GTX_matrix_factorisation to factor matrices in various forms #654
    • Added GLM_ENABLE_EXPERIMENTAL to enable experimental features.
    • Added packing functions for integer vectors #639
    • Added conan packaging configuration #643 #641
    • Added quatLookAt to GTX_quaternion #659
    • Added fmin, fmax and fclamp to GTX_extended_min_max #372
    • Added EXT_vector_relational: extend equal and notEqual to take an epsilon argument
    • Added EXT_vector_relational: openBounded and closeBounded
    • Added EXT_vec1: *vec1 types
    • Added GTX_texture: levels function
    • Added spearate functions to use both nagative one and zero near clip plans #680
    • Added GLM_FORCE_SINGLE_ONLY to use GLM on platforms that don't support double #627
    • Added GTX_easing for interpolation functions #761

    Improvements:

    • No more default initialization of vector, matrix and quaternion types
    • Added lowp variant of GTC_color_space convertLinearToSRGB #419
    • Replaced the manual by a markdown version #458
    • Improved API documentation #668
    • Optimized GTC_packing implementation
    • Optimized GTC_noise functions
    • Optimized GTC_color_space HSV to RGB conversions
    • Optimised GTX_color_space_YCoCg YCoCgR conversions
    • Optimized GTX_matrix_interpolation axisAngle function
    • Added FAQ 12: Windows headers cause build errors... #557
    • Removed GCC shadow warnings #595
    • Added error for including of different versions of GLM #619
    • Added GLM_FORCE_IGNORE_VERSION to ignore error caused by including different version of GLM #619
    • Reduced warnings when using very strict compilation flags #646
    • length() member functions are constexpr #657
    • Added support of -Weverything with Clang #646
    • Improved exponential funtion test coverage
    • Enabled warnings as error with Clang unit tests
    • Conan package is an external repository: https://github.com/bincrafters/conan-glm
    • Clarify quat_cast documentation, applying on pure rotation matrices #759

    Fixes:

    • Removed doxygen references to GTC_half_float which was removed in 0.9.4
    • Fixed glm::decompose #448
    • Fixed intersectRayTriangle #6
    • Fixed dual quaternion != operator #629
    • Fixed usused variable warning in GTX_spline #618
    • Fixed references to GLM_FORCE_RADIANS which was removed #642
    • Fixed glm::fastInverseSqrt to use fast inverse square #640
    • Fixed axisAngle NaN #638
    • Fixed integer pow from GTX_integer with null exponent #658
    • Fixed quat normalize build error #656
    • Fixed Visual C++ 2017.2 warning regarding __has_feature definision #655
    • Fixed documentation warnings
    • Fixed GLM_HAS_OPENMP when OpenMP is not enabled
    • Fixed Better follow GLSL min and max specification #372
    • Fixed quaternion constructor from two vectors special cases #469
    • Fixed glm::to_string on quaternions wrong components order #681
    • Fixed acsch #698
    • Fixed isnan on CUDA #727

    Deprecation:

    • Removed default initialization, use GLM_FORCE_CTOR_INIT to restore the old behavior
    • Requires Visual Studio 2013, GCC 4.7, Clang 3.4, Cuda 7, ICC 2013 or a C++11 compiler
    • Removed GLM_GTX_simd_vec4 extension
    • Removed GLM_GTX_simd_mat4 extension
    • Removed GLM_GTX_simd_quat extension
    • Removed GLM_SWIZZLE, use GLM_FORCE_SWIZZLE instead
    • Removed GLM_MESSAGES, use GLM_FORCE_MESSAGES instead
    • Removed GLM_DEPTH_ZERO_TO_ONE, use GLM_FORCE_DEPTH_ZERO_TO_ONE instead
    • Removed GLM_LEFT_HANDED, use GLM_FORCE_LEFT_HANDED instead
    • Removed GLM_FORCE_NO_CTOR_INIT
    • Removed glm::uninitialize
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.9.0.7z(1.77 MB)
    glm-0.9.9.0.zip(3.31 MB)
  • 0.9.8.5(Aug 16, 2017)

  • 0.9.8.4(Jan 22, 2017)

    Fixes:
    • Fixed GTC_packing test failing on GCC x86 due to denorms #212 #577
    • Fixed POPCNT optimization build in Clang #512
    • Fixed intersectRayPlane returns true in parallel case #578
    • Fixed GCC 6.2 compiler warnings #580
    • Fixed GTX_matrix_decompose decompose #582 #448
    • Fixed GCC 4.5 and older build #566
    • Fixed Visual C++ internal error when declaring a global vec type with siwzzle expression enabled #594
    • Fixed GLM_FORCE_CXX11 with Clang and libstlc++ which wasn't using C++11 STL features. #604
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.8.4.7z(3.05 MB)
    glm-0.9.8.4.zip(4.15 MB)
  • 0.9.8.3(Nov 12, 2016)

    Improvements:
    • Broader support of GLM_FORCE_UNRESTRICTED_GENTYPE #378
    Fixes:
    • Fixed Android build error with C++11 compiler but C++98 STL #284 #564
    • Fixed GTX_transform2 shear* functions #403
    • Fixed interaction between GLM_FORCE_UNRESTRICTED_GENTYPE and ortho function #568
    • Fixed bitCount with AVX on 32 bit builds #567
    • Fixed CMake find_package with version specification #572 #573
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.8.3.7z(3.05 MB)
    glm-0.9.8.3.zip(4.15 MB)
  • 0.9.8.2(Nov 1, 2016)

    Improvements:
    • Added Visual C++ 15 detection
    • Added Clang 4.0 detection
    • Added warning messages when using GLM_FORCE_CXX** but the compiler is known to not fully support the requested C++ version #555
    • Refactored GLM_COMPILER_VC values
    • Made quat, vec, mat type component length() static #565
    Fixes:
    • Fixed Visual C++ constexpr build error #555, #556
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.8.2.7z(3.06 MB)
    glm-0.9.8.2.zip(4.15 MB)
  • 0.9.8.1(Sep 25, 2016)

  • 0.9.8.0(Sep 11, 2016)

    Features:
    • Added right and left handed projection and clip control support #447 #415 #119
    • Added compNormalize and compScale functions to GTX_component_wise
    • Added packF3x9_E1x5 and unpackF3x9_E1x5 to GTC_packing for RGB9E5 #416
    • Added (un)packHalf to GTC_packing
    • Added (un)packUnorm and (un)packSnorm to GTC_packing
    • Added 16bit pack and unpack to GTC_packing
    • Added 8bit pack and unpack to GTC_packing
    • Added missing bvec* && and || operators
    • Added iround and uround to GTC_integer, fast round on positive values
    • Added raw SIMD API
    • Added 'aligned' qualifiers
    • Added GTC_type_aligned with aligned vec types
    • Added GTC_functions extension
    • Added quaternion version of isnan and isinf #521
    • Added lowestBitValue to GTX_bit #536
    • Added GLM_FORCE_UNRESTRICTED_GENTYPE allowing non basic genType #543
    Improvements:
    • Improved SIMD and swizzle operators interactions with GCC and Clang #474
    • Improved GTC_random linearRand documentation
    • Improved GTC_reciprocal documentation
    • Improved GLM_FORCE_EXPLICIT_CTOR coverage #481
    • Improved OpenMP support detection for Clang, GCC, ICC and VC
    • Improved GTX_wrap for SIMD friendliness
    • Added constexpr for vec, mat, quat and dual_quat types #493
    • Added NEON instruction set detection
    • Added MIPS CPUs detection
    • Added PowerPC CPUs detection
    • Use Cuda built-in function for abs function implementation with Cuda compiler
    • Factorized GLM_COMPILER_LLVM and GLM_COMPILER_APPLE_CLANG into GLM_COMPILER_CLANG
    • No more warnings for use of long long
    • Added more information to build messages
    Fixes:
    • Fixed GTX_extended_min_max filename typo #386
    • Fixed intersectRayTriangle to not do any unintentional backface culling
    • Fixed long long warnings when using C++98 on GCC and Clang #482
    • Fixed sign with signed integer function on non-x86 architecture
    • Fixed strict aliasing warnings #473
    • Fixed missing vec1 overload to length2 and distance2 functions #431
    • Fixed GLM test '/fp:fast' and '/Za' command-line options are incompatible
    • Fixed quaterion to mat3 cast function mat3_cast from GTC_quaternion #542
    • Fixed GLM_GTX_io for Cuda #547 #546
    Deprecation:
    • Removed GLM_FORCE_SIZE_FUNC define
    • Deprecated GLM_GTX_simd_vec4 extension
    • Deprecated GLM_GTX_simd_mat4 extension
    • Deprecated GLM_GTX_simd_quat extension
    • Deprecated GLM_SWIZZLE, use GLM_FORCE_SWIZZLE instead
    • Deprecated GLM_MESSAGES, use GLM_FORCE_MESSAGES instead
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.8.0.7z(3.06 MB)
    glm-0.9.8.0.zip(4.14 MB)
  • 0.9.7.6(Jul 16, 2016)

    Improvements:
    • Added pkg-config file #509
    • Updated list of compiler versions detected
    • Improved C++ 11 STL detection #523
    Fixes:
    • Fixed STL for C++11 detection on ICC #510
    • Fixed missing vec1 overload to length2 and distance2 functions #431
    • Fixed long long warnings when using C++98 on GCC and Clang #482
    • Fixed scalar reciprocal functions (GTC_reciprocal) #520
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.7.6.7z(2.70 MB)
    glm-0.9.7.6.zip(4.14 MB)
  • 0.9.7.5(May 24, 2016)

  • 0.9.7.4(Mar 19, 2016)

    Fixes:
    • Fixed asinh and atanh warning with C++98 STL #484
    • Fixed polar coordinates function latitude #485
    • Fixed outerProduct defintions and operator signatures for mat2x4 and vec4 #475
    • Fixed eulerAngles precision error, returns NaN #451
    • Fixed undefined reference errors #489
    • Fixed missing GLM_PLATFORM_CYGWIN declaration #495
    • Fixed various undefined reference errors #490
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.7.4.7z(2.70 MB)
    glm-0.9.7.4.zip(4.14 MB)
  • 0.9.7.3(Feb 21, 2016)

  • 0.9.7.2(Jan 3, 2016)

    Fixes:
    • Fixed GTC_round floorMultiple/ceilMultiple #412
    • Fixed GTC_packing unpackUnorm3x10_1x2 #414
    • Fixed GTC_matrix_inverse affineInverse #192
    • Fixed ICC on Linux build errors #449
    • Fixed ldexp and frexp compilation errors
    • Fixed "Declaration shadows a field" warning #468
    • Fixed 'GLM_COMPILER_VC2005 is not defined' warning #468
    • Fixed various 'X is not defined' warnings #468
    • Fixed missing unary + operator #435
    • Fixed Cygwin build errors when using C++11 #405
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.7.2.7z(2.69 MB)
    glm-0.9.7.2.zip(4.14 MB)
  • 0.9.7.1(Sep 7, 2015)

    Improvements:
    • Improved constexpr for constant functions coverage #198
    • Added to_string for quat and dual_quat in GTX_string_cast #375
    • Improved overall execution time of unit tests #396
    Fixes:
    • Fixed strict alignment warnings #235 #370
    • Fixed link errors on compilers not supported default function #377
    • Fixed compilation warnings in vec4
    • Fixed non-identity quaternions for equal vectors #234
    • Fixed excessive GTX_fast_trigonometry execution time #396
    • Fixed Visual Studio 2015 'hides class member' warnings #394
    • Fixed builtin bitscan never being used #392
    • Removed unused func_noise.* files #398
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.7.1.7z(2.69 MB)
    glm-0.9.7.1.zip(4.14 MB)
  • 0.9.7.0(Aug 2, 2015)

    Features:
    • Added GTC_color_space: convertLinearToSRGB and convertSRGBToLinear functions
    • Added 'fmod' overload to GTX_common with tests #308
    • Left handed perspective and lookAt functions #314
    • Added functions eulerAngleXYZ and extractEulerAngleXYZ #311
    • Added <glm/gtx/hash.hpp> to perform std::hash on GLM types #320 #367
    • Added <glm/gtx/wrap.hpp> for texcoord wrapping
    • Added static components and precision members to all vector and quat types #350
    • Added .gitignore #349
    • Added support of defaulted functions to GLM types, to use them in unions #366
    Improvements:
    • Changed usage of __has_include to support Intel compiler #307
    • Specialized integer implementation of YCoCg-R #310
    • Don't show status message in 'FindGLM' if 'QUIET' option is set. #317
    • Added master branch continuous integration service on Linux 64 #332
    • Clarified manual regarding angle unit in GLM, added FAQ 11 #326
    • Updated list of compiler versions
    Fixes:
    • Fixed default precision for quat and dual_quat type #312
    • Fixed (u)int64 MSB/LSB handling on BE archs #306
    • Fixed multi-line comment warning in g++. #315
    • Fixed specifier removal by 'std::make_pair<>' #333
    • Fixed perspective fovy argument documentation #327
    • Removed -m64 causing build issues on Linux 32 #331
    • Fixed isfinite with C++98 compilers #343
    • Fixed Intel compiler build error on Linux #354
    • Fixed use of libstdc++ with Clang #351
    • Fixed quaternion pow #346
    • Fixed decompose warnings #373
    • Fixed matrix conversions #371
    Deprecation:
    • Removed integer specification for 'mod' in GTC_integer #308
    • Removed GTX_multiple, replaced by GTC_round
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.7.0.7z(2.69 MB)
    glm-0.9.7.0.zip(4.14 MB)
  • 0.9.6.3(May 1, 2015)

  • 0.9.6.2(Aug 2, 2015)

  • 0.9.6.1(Aug 2, 2015)

    Features:
    • Added GLM_LANG_CXX14_FLAG and GLM_LANG_CXX1Z_FLAG language feature flags
    • Added C++14 detection
    Improvements:
    • Clean up GLM_MESSAGES compilation log to report only detected capabilities
    Fixes:
    • Fixed scalar uaddCarry build error with Cuda #276
    • Fixed C++11 explicit conversion operators detection #282
    • Fixed missing explicit convertion when using integer log2 with *vec1 types
    • Fixed 64 bits integer GTX_string_cast to_string on VC 32 bit compiler
    • Fixed Android build issue, STL C++11 is not supported by the NDK #284
    • Fixed unsupported _BitScanForward64 and _BitScanReverse64 in VC10
    • Fixed Visual C++ 32 bit build #283
    • Fixed GLM_FORCE_SIZE_FUNC pragma message
    • Fixed C++98 only build
    • Fixed conflict between GTX_compatibility and GTC_quaternion #286
    • Fixed C++ language restriction using GLM_FORCE_CXX**
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.6.1.7z(2.60 MB)
    glm-0.9.6.1.zip(4.03 MB)
  • 0.9.6.0(Aug 2, 2015)

    Features:
    • Exposed template vector and matrix types in 'glm' namespace #239, #244
    • Added GTX_scalar_multiplication for C++ 11 compiler only #242
    • Added GTX_range for C++ 11 compiler only #240
    • Added closestPointOnLine function for tvec2 to GTX_closest_point #238
    • Added GTC_vec1 extension, vec1 support to *vec types
    • Updated GTX_associated_min_max with vec1 support
    • Added support of precision and integers to linearRand #230
    • Added Integer types support to GTX_string_cast #249
    • Added vec3 slerp #237
    • Added GTX_common with isdenomal #223
    • Added GLM_FORCE_SIZE_FUNC to replace .length() by .size() #245
    • Added GLM_FORCE_NO_CTOR_INIT
    • Added 'uninitialize' to explicitly not initialize a GLM type
    • Added GTC_bitfield extension, promoted GTX_bit
    • Added GTC_integer extension, promoted GTX_bit and GTX_integer
    • Added GTC_round extension, promoted GTX_bit
    • Added GLM_FORCE_EXPLICIT_CTOR to require explicit type conversions #269
    • Added GTX_type_aligned for aligned vector, matrix and quaternion types
    Improvements:
    • Rely on C++11 to implement isinf and isnan
    • Removed GLM_FORCE_CUDA, Cuda is implicitly detected
    • Separated Apple Clang and LLVM compiler detection
    • Used pragma once
    • Undetected C++ compiler automatically compile with GLM_FORCE_CXX98 and GLM_FORCE_PURE
    • Added not function (from GLSL specification) on VC12
    • Optimized bitfieldReverse and bitCount functions
    • Optimized findLSB and findMSB functions.
    • Optimized matrix-vector multiple performance with Cuda #257, #258
    • Reduced integer type redifinitions #233
    • Rewrited of GTX_fast_trigonometry #264 #265
    • Made types trivially copyable #263
    • Removed in GLM tests
    • Used std features within GLM without redeclaring
    • Optimized cot function #272
    • Optimized sign function #272
    • Added explicit cast from quat to mat3 and mat4 #275
    Fixes:
    • Fixed std::nextafter not supported with C++11 on Android #217
    • Fixed missing value_type for dual quaternion
    • Fixed return type of dual quaternion length
    • Fixed infinite loop in isfinite function with GCC #221
    • Fixed Visual Studio 14 compiler warnings
    • Fixed implicit conversion from another tvec2 type to another tvec2 #241
    • Fixed lack of consistency of quat and dualquat constructors
    • Fixed uaddCarray #253
    • Fixed float comparison warnings #270
    Deprecation:
    • Removed degrees for function parameters
    • Removed GLM_FORCE_RADIANS, active by default
    • Removed VC 2005 / 8 and 2008 / 9 support
    • Removed GCC 3.4 to 4.3 support
    • Removed LLVM GCC support
    • Removed LLVM 2.6 to 3.1 support
    • Removed CUDA 3.0 to 3.2 support
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.6.0.7z(2.59 MB)
    glm-0.9.6.0.zip(4.02 MB)
  • 0.9.5.4(May 1, 2015)

    • Fixed non-utf8 character #196
    • Added FindGLM install for CMake #189
    • Fixed GTX_color_space - saturation #195
    • Fixed glm::isinf and glm::isnan for with Android NDK 9d #191
    • Fixed builtin GLM_ARCH_SSE4 #204
    • Optimized Quaternion vector rotation #205
    • Fixed missing doxygen @endcond tag #211
    • Fixed instruction set detection with Clang #158
    • Fixed orientate3 function #207
    • Fixed lerp when cosTheta is close to 1 in quaternion slerp #210
    • Added GTX_io for io with #144
    • Fixed fastDistance ambiguity #215
    • Fixed tweakedInfinitePerspective #208 and added user-defined epsilon to tweakedInfinitePerspective
    • Fixed std::copy and std::vector with GLM types #214
    • Fixed strict aliasing issues #212, #152
    • Fixed std::nextafter not supported with C++11 on Android #213
    • Fixed corner cases in exp and log functions for quaternions #199
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.5.4.7z(2.57 MB)
    glm-0.9.5.4.zip(3.89 MB)
  • 0.9.5.3(Aug 2, 2015)

    • Added instruction set auto detection with Visual C++ using _M_IX86_FP - /arch compiler argument
    • Fixed GTX_raw_data code dependency
    • Fixed GCC instruction set detection
    • Added GLM_GTX_matrix_transform_2d extension (#178, #176)
    • Fixed CUDA issues (#169, #168, #183, #182)
    • Added support for all extensions but GTX_string_cast to CUDA
    • Fixed strict aliasing warnings in GCC 4.8.1 / Android NDK 9c (#152)
    • Fixed missing bitfieldInterleave definisions
    • Fixed usubBorrow (#171)
    • Fixed eulerAngle*** not consistent for right-handed coordinate system (#173)
    • Added full tests for eulerAngle*** functions (#173)
    • Added workaround for a CUDA compiler bug (#186, #185)
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.5.3.7z(2.57 MB)
    glm-0.9.5.3.zip(3.88 MB)
  • 0.9.5.2(Aug 2, 2015)

    • Fixed initializer list ambiguity (#159, #160)
    • Fixed warnings with the Android NDK 9c
    • Fixed non power of two matrix products
    • Fixed mix function link error
    • Fixed SSE code included in GLM tests on "pure" platforms
    • Fixed undefined reference to fastInverseSqrt (#161)
    • Fixed GLM_FORCE_RADIANS with <glm/ext.hpp> build error (#165)
    • Fix dot product clamp range for vector angle functions. (#163)
    • Tentative fix for strict aliasing warning in GCC 4.8.1 / Android NDK 9c (#152)
    • Fixed GLM_GTC_constants description brief (#162)
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.5.2.7z(2.57 MB)
    glm-0.9.5.2.zip(3.88 MB)
  • 0.9.5.1(Aug 2, 2015)

    • Fixed angle and orientedAngle that sometimes return NaN values (#145)
    • Deprecated degrees for function parameters and display a message
    • Added possible static_cast conversion of GLM types (#72)
    • Fixed error 'inverse' is not a member of 'glm' from glm::unProject (#146)
    • Fixed mismatch between some declarations and definitions
    • Fixed inverse link error when using namespace glm; (#147)
    • Optimized matrix inverse and division code (#149)
    • Added intersectRayPlane function (#153)
    • Fixed outerProduct return type (#155)
    Source code(tar.gz)
    Source code(zip)
    glm-0.9.5.1.7z(2.55 MB)
    glm-0.9.5.1.zip(3.88 MB)
Owner
G-Truc Creation
G-Truc Creation
📽 Highly optimized 2D|3D math library, also known as OpenGL Mathematics (glm) for `C

Highly optimized 2D|3D math library, also known as OpenGL Mathematics (glm) for `C`. cglm provides lot of utils to help math operations to be fast and quick to write. It is community friendly, feel free to bring any issues, bugs you faced.

Recep Aslantas 1.5k Nov 30, 2022
OpenGL®-Starter is a template for your upcoming OpenGL Projects which has been compiled to run the most basic Hello World OpenGL Program from LearnOpenGL.com.

OpenGL®-Starter OpenGL®-Starter is a template for your upcoming OpenGL Projects which has been compiled to run the most basic Hello World OpenGL Progr

Kushagra 9 Sep 7, 2022
OpenGL Template Engine - a C++ OpenGL graphics engine which aimed to be a simple startup template for 3D OpenGL projects.

OpenGL Template Engine is a C++ OpenGL graphics engine which aimed to be a simple startup template for 3D OpenGL projects. This is the template I personally use for my own projects and provides me with the general OpenGL 3D render setup with model import and UI.

Marcus Nesse Madland 2 May 16, 2022
📽 Highly Optimized Graphics Math (glm) for C

?? OpenGL Mathematics (glm) for C Documentation Almost all functions (inline versions) and parameters are documented inside the corresponding headers.

Recep Aslantas 1.5k Dec 2, 2022
📽 Highly Optimized Graphics Math (glm) for C

?? OpenGL Mathematics (glm) for C Documentation Almost all functions (inline versions) and parameters are documented inside the corresponding headers.

Recep Aslantas 1.5k Nov 27, 2022
Collection of various algorithms in mathematics, machine learning, computer science, physics, etc implemented in C for educational purposes.

The Algorithms - C # {#mainpage} Overview The repository is a collection of open-source implementation of a variety of algorithms implemented in C and

The Algorithms 15k Nov 25, 2022
This repository contains notes and starter code for Bit manipulation and mathematics session for DSA bootcamp organized by Codeflows.

Bitmanipulation_maths This repository contains notes and starter code for Bit manipulation and mathematics session for DSA bootcamp organized by Codef

Joe 7 Jun 15, 2022
Examples for the "Introduction to programming" course given by me and @bzareva @ Faculty of Mathematics and Informatics, Sofia University (2021/22)

Теми от практикумите по "Увод в програмирането", зимен семестър 2021/2022, спец. "Информатика", група 5 Тема 1 (04.10.2021) : Променливи. Типове проме

null 12 Dec 3, 2022
This repository consists an implementation of the Algorithms encountered in Computer Science, Physics and Mathematics.

All the Algorithms you'll ever need xD This repository contains all the algorithms we have encountered in the fields of Computer Science, Mathematics

ACM VIT 8 Oct 4, 2022
Metamath - Meta mathematics. Symbolic functions and derivatives.

metamath Meta mathematic metamath is a tiny header-only library. It can be used for symbolic computations on single-variable functions, such as dynami

eg 31 Nov 4, 2022
A multi-platform library for OpenGL, OpenGL ES, Vulkan, window and input

GLFW Introduction GLFW is an Open Source, multi-platform library for OpenGL, OpenGL ES and Vulkan application development. It provides a simple, platf

GLFW 9.9k Nov 30, 2022
C++ OpenGL 3D Game Tutorial Series - Learn to code an OpenGL 3D Game in C++ from scratch

C++ OpenGL 3D Game Tutorial Series is a YouTube Tutorial Series, whose purpose is to help all those who want to take their first steps in the game dev

 PardCode 115 Nov 26, 2022
A legacy OpenGL simulator for OpenGL 4.4, written in C++.

the-ancient-tri A legacy OpenGL simulator for OpenGL 4.4, written in C++. Why? My Uni forces us to use legacy OpenGL (eww!), and I didn't want to lear

Mohammad Issawi 4 Feb 10, 2022
Several GX2 test programs to compare it with OpenGL. (With additional GLFW+OpenGL implementation provided)

GX2-Tests Provided are GX2 test programs and samples for comparison with OpenGL and with additional GLFW+OpenGL implementation for test on PC. These s

AboodXD 1 Nov 15, 2021
Minimalistic C++/Python GUI library for OpenGL, GLES2/3, Metal, and WebAssembly/WebGL

NanoGUI NanoGUI is a minimalistic cross-platform widget library for OpenGL 3+, GLES 2/3, and Metal. It supports automatic layout generation, stateful

Mitsuba Physically Based Renderer 1.1k Nov 25, 2022
Low Level Graphics Library (LLGL) is a thin abstraction layer for the modern graphics APIs OpenGL, Direct3D, Vulkan, and Metal

Low Level Graphics Library (LLGL) Documentation NOTE: This repository receives bug fixes only, but no major updates. Pull requests may still be accept

Lukas Hermanns 1.5k Nov 28, 2022
Antialiased 2D vector drawing library on top of OpenGL for UI and visualizations.

This project is not actively maintained. NanoVG NanoVG is small antialiased vector graphics rendering library for OpenGL. It has lean API modeled afte

Mikko Mononen 4.6k Dec 3, 2022
Epoxy is a library for handling OpenGL function pointer management for you

Epoxy is a library for handling OpenGL function pointer management for you. It hides the complexity of dlopen(), dlsym(), glXGetProcAddress(), eglGetP

Eric Anholt 574 Nov 24, 2022
Epoxy is a library for handling OpenGL function pointer management for you

Epoxy is a library for handling OpenGL function pointer management for you. It hides the complexity of dlopen(), dlsym(), glXGetProcAddress(), eglGetP

Eric Anholt 574 Nov 24, 2022
3D engine from scratch (without OpenGL or any other 3D graphics library)

Simple 3d engine based on SFML library. I tried to make this engine powerful and easy to understand.

Vectozavr 62 Nov 16, 2022