Commit Graph

1246 Commits

Author SHA1 Message Date
Christophe
88a6ed6ee1 Visual C++: Enables /Wall 2024-02-08 15:15:31 +01:00
Christophe
4eb3fe1d7d fcomp: Fix build in C++98 mode 2024-02-07 14:20:28 +01:00
Maximilian Sackel
c9ca4dc77c Implementing fcompMin / fcompMax, closes g-truc/glm#1215 2024-02-07 14:20:28 +01:00
Christophe
7b53739128 Only enable compiler warnings and warnings as error on unit tests 2024-02-06 20:37:11 +01:00
Christophe
31a5f56a7c Fix epsilon not declared in color_space.inl #1233 2024-02-06 20:37:11 +01:00
Christophe
f86092a658
Remove disabled warnings (#1213)
* Remove disabled warnings
2024-01-20 10:11:13 +01:00
Christophe
b6618171dd
Fix GLM_GTX_hash (#1202)
* Fix GLM_GTX_hash, requires C++ 11
2023-12-29 12:50:27 +01:00
Christophe
a40974fb86
Test multiple platforms to test multiple compiler versions (#1199) 2023-12-28 16:50:25 +01:00
Christophe
cf69137d6d quaternion: Revert #1069 2023-12-22 11:50:46 +01:00
Christophe
d6e24170b4 Nan is not supported with C++98 2023-12-21 18:14:20 +01:00
Christophe
0ceaba1da9 Nan is not supported with C++98 2023-12-21 18:14:20 +01:00
Christophe
0d52d5ddab Fix master build 2023-12-21 18:14:20 +01:00
Christophe
557f5f2731 Fix test 2023-12-21 17:45:01 +01:00
Christophe
92e945cc8a GLM_EXT_vector_integer: add integer mix tests 2023-12-21 17:45:01 +01:00
christophe
4681c5b347 Fix lib build dependent of test build 2023-12-21 15:20:01 +01:00
christophe
820557cf31 Fix GTC_matrix_transform test for C++98 2023-12-21 14:21:29 +01:00
azhirnov
ed1059731f add infinitePerspectiveRH_ZO 2023-12-21 14:12:18 +01:00
azhirnov
9cb19aa43f Added infinitePerspectiveLH_ZO and tests
Renamed infinitePerspectiveLH -> infinitePerspectiveLH_NO
2023-12-21 14:12:18 +01:00
Christophe
5ae05c9296 Fix GLM_DISABLE_AUTO_DETECTION error with Werror on Windows 2023-12-21 13:25:48 +01:00
Christophe
971f22222e C.I. Fix timeout 2023-12-21 13:25:48 +01:00
Christophe
66991e59aa Fix bitCount test version 2023-12-21 10:17:16 +01:00
Christophe
641bb363a7 gni 2023-12-20 22:33:20 +01:00
Christophe
edecbf1c59 Revert "Add support for non aligned SIMD for vec4"
This reverts commit 4e01e940de.
2023-12-20 22:33:20 +01:00
Christophe
2d38c41161 Fixes for tests build 2023-12-20 22:33:20 +01:00
Laurent Caumont
c2c1d15592 fix cmake version 2023-11-08 15:54:46 +01:00
Laurent Caumont
1b0f61e285 Add support for non aligned SIMD for vec4
It is used as default configuration for Visual Studio 64 bits compilation (needs Language Extension).
code changes:
- add new qualifiers:
  unaligned_simd_highp
  unaligned_simd_mediump
  unaligned_simd_lowp
- add use_simd and replace is_aligned
(code for ARM NEON is added but not tested)
2023-11-08 09:30:26 +01:00
Christophe
db0f79de12
Merge pull request #1137 from tetrisplusplus/fix_glm_gtx_matrix_query_isOrthogonal
fix: isOrthogonal for a zero matrix #1137
2023-08-18 15:04:55 +02:00
Christophe
99fe1c8f7d
Merge pull request #1142 from thp/recompose
gtx_matrix_decompose: Add glm::recompose() #1142
2023-08-18 14:55:41 +02:00
Mark Sheppard
3cb568cd37 Fix Clang 15 test build errors
Fixes for compiler errors when building the tests using Clang 15,
including:

    * Use explicit cast to silence Wimplicit-int-float-conversion
      warning for conversion of spin count in implementation of
      glm::slerp.
    * Use GLM_FORCE_MESSAGES instead of removed GLM_MESSAGES for
      messages in glm/gtx/hash.hpp, avoiding Wundef warning.
    * Encode en dash in URL for Gram-Schmit Process wikipedia page and
      replace similar en dashes in comments with regular dashes, to
      avoid Winvalid-utf8 warnings in glm/gtx/matrix_factorisation.inl.
    * Replace degree sign symbol with text "degrees" to avoid
      Winvalid-utf8 warnings in test/gtc/gtc_quaternion.cpp.
    * When using Clang, build tests with -Wno-float-equal to silence
      Wfloat-equal warning in implementation of glm::vec<L,T,Q>::equal.
    * For performance tests in test/gtx/gtx_fast_trigonometry.cpp, add
      statement explicitly casting result to void, to silence
      Wunused-but-set-variable warnings.
    * Add newline at end of test/gtx/gtx_hash.cpp to silence
      Wnewline-eof warning.
    * Rename namespace _1aga to agarose in test/gtx/gtx_pca.cpp to
      avoid Wreserved-identifier warning.
2023-03-31 17:39:53 +01:00
Thomas Perl
4afe953bff gtx_matrix_decompose: Add glm::recompose() 2023-02-26 18:33:47 +01:00
tetrisplusplus
2af53d5981 Added test_isOrthogonal for zero matrix 2023-01-23 21:05:35 +09:00
olga
97e09aa304 Fix round test
Depending on the developer environment, the output of round for o.5 or -0.5 may be different (according to the GLSL spec). So the test was too restrictive.
2023-01-13 14:08:46 +01:00
Thibault de Villèle [UM]
1c18fca789 Fix GLM_EXT_matrix_common : row to column-major
The previous patch made the incorrect assumption matrices were row-major
instead of column-major (got the two mixed up in my head).

This fixes this problem.

Also, this extends the test files to cover all matrix sizes (not types,
that would be redundant).
2022-10-26 11:17:23 +02:00
Christophe
7b9d310dbd
Merge pull request #1116 from Thibaulltt/master
GLM_EXT_matrix_common : add glm::mat<> support to glm::abs() #1116
2022-10-24 12:33:54 +02:00
Thibault de Villèle [UM]
48e1ff3fee Add glm::abs() function for the glm::mat<> class
This is added as part of the GLM_EXT_matrix_common extension, as this
function is not provided by the core GLSL specification (version 4.20).

The implementation of this glm::abs(mat<>) function mirrors the
glm::abs(vec<>) implementation. It should be functionning the same in
every way as the vec implementation.

Bonus points : AFAICT this allows to vectorize operations on compilers
that support optimization of these patterns, just like the functor1<>
struct in _vectorize.hpp for vectors.
2022-08-29 14:22:10 +02:00
Charles Huber
4b6284e39d GCC: Fix noexcept warnings on hash functions
Fix warnings on hash functions with GCC and -Wnoexcept:
* Add GLM_HAS_NOEXCEPT flag & GLM_NOEXCEPT #define to setup.hpp.
* Add GLM_NOEXCEPT to hash functions in hash.hpp.
* Add GLM_NOEXCEPT to matrix operator[] accessors.
* Add gtx_hash.cpp and a test to verify all hash overloads compile.
  Configure with -DCMAKE_CXX_FLAGS="-Werror -Wnoexcept" to test.
2022-08-24 15:21:11 -05:00
arikanli
0f318f63af feat: add shearing matrix operation on matrix_transfom 2022-01-20 21:27:30 +08:00
SGrottel
104c1214ee Avoid fp comparison of glm::sign return value by introducing a sign comparison helper function 2021-06-05 16:43:47 +02:00
SGrottel
5dbba35275 Changed test functions to explicitly define comparison epsilons.
Updated 1aga expected computation results, based on external experiment based on precise / symbolic computation
Unified result comparison to always use `vectorEpsilonEqual` or `matrixEpsilonEqual`
2021-06-05 16:30:40 +02:00
Christophe
dc9e555b4c
Merge pull request #1071 from sgrottel/gtx-pca
Implemented 'principle component analysis' utility in gtx #1071
2021-05-15 12:50:27 +02:00
SGrottel
d71dba9603 Introduced a second, less precise comparison epsilon for the tests for now. 2021-05-11 07:44:40 +02:00
SGrottel
18d9b97aa4 Further increased comparison float epsilon, and further test batch testEigenvectors also failes.
Added debug output to `testEigenvectors` in case the error persists.
2021-05-10 23:36:17 +02:00
SGrottel
593b7cc36b Increased float comparison epsilon to pass tests. 2021-05-10 22:49:57 +02:00
SGrottel
a0ccbcc63d Added further details on the comparison issue with covariance matrices on some VMs.
Also corrected some code style guide, and changed `nullptr` to `GLM_NULLPTR` for better compatibility.
Tests are now executed in blocks of related tests, and only inbetween blocks the tests will exit.
2021-05-10 21:32:01 +02:00
SGrottel
d0d7945141 Additional debug output to investigate why test-gtx_pca fails on some VMs on Travis.
Also, reworked the `#if` about CXX11; did not seem to work correctly.
2021-05-10 19:35:57 +02:00
SGrottel
c792a0a221 Disabled tests requiring random engine when CXX11 STL is not available.
Added missed `typename` keywords, and fixed variable initialization.
2021-05-10 17:48:35 +02:00
SGrottel
0f5b544d5d Corrected errors on Xcode C++98 pure related to language extensions accidentially used. 2021-05-10 16:38:38 +02:00
SGrottel
b8adc27808 Removed lambdas and initializer list ctors to be compatible with older cpp standards. 2021-05-10 15:45:42 +02:00
SGrottel
dd40903b74 Implemented 'principle component analysis' utility in gtx, including tests 2021-05-10 13:14:29 +02:00
Gaoyang Zhang
de7c83f1b6 Update test for GLM_FORCE_QUAT_DATA_XYZW
Signed-off-by: Gaoyang Zhang <gy@blurgy.xyz>
2021-05-06 14:12:41 +08:00