Codebase list glm / 5b0e27b
Update upstream source from tag 'upstream/0.9.9.8+ds' Update to upstream version '0.9.9.8+ds' with Debian dir 36e592196eafcef2344c3656bdb57b23bc73cd4e Carsten Schoenert 3 years ago
125 changed file(s) with 4998 addition(s) and 1094 deletion(s). Raw diff Collapse all Expand all
7676
7777 test_script:
7878 - ctest -j4 -C %CONFIGURATION%
79 - cd ..
80 - ps: |
81 mkdir build_test_cmake
82 cd build_test_cmake
83 cmake ..\test\cmake\ -G "$env:generator" -Dglm_DIR="$env:APPVEYOR_BUILD_FOLDER/cmake/glm/"
84 - cmake --build . --config %CONFIGURATION% -- /m /v:minimal
7985
8086 deploy: off
3232 cmake_install.cmake
3333 install_manifest.txt
3434 *.cmake
35 !glmConfig.cmake
36 !glmConfig-version.cmake
3537 # ^ May need to add future .cmake files as exceptions
3638
3739 # Test logs
5557 /.vscode
5658 /CMakeSettings.json
5759 .DS_Store
60 *.swp
1010 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_DISABLE_AUTO_DETECTION=ON ..
1111 - cmake -E time cmake --build .
1212 - ctest
13 - cd $TRAVIS_BUILD_DIR
14 - mkdir ./build_test_cmake
15 - cd ./build_test_cmake
16 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
17 - cmake --build .
1318 env:
1419 - MATRIX_EVAL="INFO=C++unknown-release"
1520
2227 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_98=ON -DGLM_TEST_FORCE_PURE=ON ..
2328 - cmake -E time cmake --build .
2429 - ctest
30 - cd $TRAVIS_BUILD_DIR
31 - mkdir ./build_test_cmake
32 - cd ./build_test_cmake
33 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
34 - cmake --build .
2535 env:
2636 - MATRIX_EVAL="INFO=C++98-pure-release"
2737
3444 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_98=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON ..
3545 - cmake -E time cmake --build .
3646 - ctest
47 - cd $TRAVIS_BUILD_DIR
48 - mkdir ./build_test_cmake
49 - cd ./build_test_cmake
50 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
51 - cmake --build .
3752 env:
3853 - MATRIX_EVAL="INFO=C++98-pure-ms-release"
3954
4661 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_FORCE_PURE=ON ..
4762 - cmake -E time cmake --build .
4863 - ctest
64 - cd $TRAVIS_BUILD_DIR
65 - mkdir ./build_test_cmake
66 - cd ./build_test_cmake
67 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
68 - cmake --build .
4969 env:
5070 - MATRIX_EVAL="INFO=C++11-pure-release"
5171
5878 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE2=ON ..
5979 - cmake -E time cmake --build .
6080 - ctest
81 - cd $TRAVIS_BUILD_DIR
82 - mkdir ./build_test_cmake
83 - cd ./build_test_cmake
84 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
85 - cmake --build .
6186 env:
6287 - MATRIX_EVAL="INFO=C++11-sse2-release"
6388
7095 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_FORCE_PURE=ON ..
7196 - cmake -E time cmake --build .
7297 - ctest
98 - cd $TRAVIS_BUILD_DIR
99 - mkdir ./build_test_cmake
100 - cd ./build_test_cmake
101 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
102 - cmake --build .
73103 env:
74104 - MATRIX_EVAL="INFO=C++14-pure-release"
75105
82112 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
83113 - cmake -E time cmake --build .
84114 - ctest
115 - cd $TRAVIS_BUILD_DIR
116 - mkdir ./build_test_cmake
117 - cd ./build_test_cmake
118 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
119 - cmake --build .
85120 env:
86121 - MATRIX_EVAL="INFO=C++14-sse3-release"
87122
94129 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
95130 - cmake -E time cmake --build .
96131 - ctest
132 - cd $TRAVIS_BUILD_DIR
133 - mkdir ./build_test_cmake
134 - cd ./build_test_cmake
135 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
136 - cmake --build .
97137 env:
98138 - MATRIX_EVAL="INFO=C++14-avx-release"
99139
106146 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
107147 - cmake -E time cmake --build .
108148 - ctest
149 - cd $TRAVIS_BUILD_DIR
150 - mkdir ./build_test_cmake
151 - cd ./build_test_cmake
152 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
153 - cmake --build .
109154 env:
110155 - MATRIX_EVAL="INFO=C++14-avx-debug"
111156
118163 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_FORCE_PURE=ON ..
119164 - cmake -E time cmake --build .
120165 - ctest
166 - cd $TRAVIS_BUILD_DIR
167 - mkdir ./build_test_cmake
168 - cd ./build_test_cmake
169 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
170 - cmake --build .
121171 env:
122172 - MATRIX_EVAL="INFO=C++17-pure-release"
123173
130180 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_FORCE_PURE=ON ..
131181 - cmake -E time cmake --build .
132182 - ctest
183 - cd $TRAVIS_BUILD_DIR
184 - mkdir ./build_test_cmake
185 - cd ./build_test_cmake
186 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
187 - cmake --build .
133188 env:
134189 - MATRIX_EVAL="INFO=C++17-pure-debug"
135190
142197 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
143198 - cmake -E time cmake --build .
144199 - ctest
200 - cd $TRAVIS_BUILD_DIR
201 - mkdir ./build_test_cmake
202 - cd ./build_test_cmake
203 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
204 - cmake --build .
145205 env:
146206 - MATRIX_EVAL="INFO=C++17-avx-release"
147207
154214 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
155215 - cmake -E time cmake --build .
156216 - ctest
217 - cd $TRAVIS_BUILD_DIR
218 - mkdir ./build_test_cmake
219 - cd ./build_test_cmake
220 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
221 - cmake --build .
157222 env:
158223 - MATRIX_EVAL="INFO=C++17-avx-debug"
159224
173238 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_98=ON -DGLM_TEST_FORCE_PURE=ON ..
174239 - cmake --build .
175240 - ctest
241 - cd $TRAVIS_BUILD_DIR
242 - mkdir ./build_test_cmake
243 - cd ./build_test_cmake
244 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
245 - cmake --build .
176246
177247 - os: linux
178248 addons:
190260 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_98=ON -DGLM_TEST_FORCE_PURE=ON ..
191261 - cmake --build .
192262 - ctest
263 - cd $TRAVIS_BUILD_DIR
264 - mkdir ./build_test_cmake
265 - cd ./build_test_cmake
266 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
267 - cmake --build .
193268
194269 - os: linux
195270 addons:
207282 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_98=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_FORCE_PURE=ON ..
208283 - cmake --build .
209284 - ctest
285 - cd $TRAVIS_BUILD_DIR
286 - mkdir ./build_test_cmake
287 - cd ./build_test_cmake
288 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
289 - cmake --build .
210290
211291 - os: linux
212292 addons:
224304 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_FORCE_PURE=ON ..
225305 - cmake --build .
226306 - ctest
307 - cd $TRAVIS_BUILD_DIR
308 - mkdir ./build_test_cmake
309 - cd ./build_test_cmake
310 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
311 - cmake --build .
227312
228313 - os: linux
229314 addons:
241326 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_FORCE_PURE=ON ..
242327 - cmake --build .
243328 - ctest
329 - cd $TRAVIS_BUILD_DIR
330 - mkdir ./build_test_cmake
331 - cd ./build_test_cmake
332 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
333 - cmake --build .
244334
245335 - os: linux
246336 addons:
258348 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_FORCE_PURE=ON ..
259349 - cmake --build .
260350 - ctest
351 - cd $TRAVIS_BUILD_DIR
352 - mkdir ./build_test_cmake
353 - cd ./build_test_cmake
354 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
355 - cmake --build .
261356
262357 - os: linux
263358 addons:
275370 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_11=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
276371 - cmake --build .
277372 - ctest
373 - cd $TRAVIS_BUILD_DIR
374 - mkdir ./build_test_cmake
375 - cd ./build_test_cmake
376 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
377 - cmake --build .
278378
279379 - os: linux
280380 addons:
292392 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_FORCE_PURE=ON ..
293393 - cmake --build .
294394 - ctest
395 - cd $TRAVIS_BUILD_DIR
396 - mkdir ./build_test_cmake
397 - cd ./build_test_cmake
398 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
399 - cmake --build .
295400
296401 - os: linux
297402 addons:
309414 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_FORCE_PURE=ON ..
310415 - cmake --build .
311416 - ctest
417 - cd $TRAVIS_BUILD_DIR
418 - mkdir ./build_test_cmake
419 - cd ./build_test_cmake
420 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
421 - cmake --build .
312422
313423 - os: linux
314424 addons:
326436 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_FORCE_PURE=ON ..
327437 - cmake --build .
328438 - ctest
439 - cd $TRAVIS_BUILD_DIR
440 - mkdir ./build_test_cmake
441 - cd ./build_test_cmake
442 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
443 - cmake --build .
329444
330445 - os: linux
331446 addons:
343458 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
344459 - cmake --build .
345460 - ctest
461 - cd $TRAVIS_BUILD_DIR
462 - mkdir ./build_test_cmake
463 - cd ./build_test_cmake
464 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
465 - cmake --build .
346466
347467 - os: linux
348468 addons:
360480 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_FORCE_PURE=ON ..
361481 - cmake -E time cmake --build .
362482 - ctest
483 - cd $TRAVIS_BUILD_DIR
484 - mkdir ./build_test_cmake
485 - cd ./build_test_cmake
486 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
487 - cmake --build .
363488
364489 - os: linux
365490 addons:
377502 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE2=ON ..
378503 - cmake -E time cmake --build .
379504 - ctest
505 - cd $TRAVIS_BUILD_DIR
506 - mkdir ./build_test_cmake
507 - cd ./build_test_cmake
508 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
509 - cmake --build .
380510
381511 - os: linux
382512 addons:
394524 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
395525 - cmake -E time cmake --build .
396526 - ctest
527 - cd $TRAVIS_BUILD_DIR
528 - mkdir ./build_test_cmake
529 - cd ./build_test_cmake
530 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
531 - cmake --build .
397532
398533 - os: linux
399534 addons:
411546 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
412547 - cmake -E time cmake --build .
413548 - ctest
549 - cd $TRAVIS_BUILD_DIR
550 - mkdir ./build_test_cmake
551 - cd ./build_test_cmake
552 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
553 - cmake --build .
414554
415555 - os: linux
416556 addons:
428568 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX2=ON ..
429569 - cmake -E time cmake --build .
430570 - ctest
571 - cd $TRAVIS_BUILD_DIR
572 - mkdir ./build_test_cmake
573 - cd ./build_test_cmake
574 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
575 - cmake --build .
431576
432577 - os: linux
433578 addons:
446591 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_FORCE_PURE=ON ..
447592 - cmake -E time cmake --build .
448593 - ctest
594 - cd $TRAVIS_BUILD_DIR
595 - mkdir ./build_test_cmake
596 - cd ./build_test_cmake
597 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
598 - cmake --build .
449599
450600 - os: linux
451601 addons:
464614 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_FORCE_PURE=ON ..
465615 - cmake -E time cmake --build .
466616 - ctest
617 - cd $TRAVIS_BUILD_DIR
618 - mkdir ./build_test_cmake
619 - cd ./build_test_cmake
620 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
621 - cmake --build .
467622
468623 - os: linux
469624 addons:
482637 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_14=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_AVX=ON ..
483638 - cmake -E time cmake --build .
484639 - ctest
640 - cd $TRAVIS_BUILD_DIR
641 - mkdir ./build_test_cmake
642 - cd ./build_test_cmake
643 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
644 - cmake --build .
485645
486646 - os: linux
487647 dist: bionic
488648 env:
489 - MATRIX_EVAL="CC=clang-7.0 && INFO=C++17-pure-release"
649 - MATRIX_EVAL="CC=clang && CXX=clang++ && INFO=C++17-pure-release"
490650 script:
491651 - cmake --version
492652 - mkdir ./build_pure_17_release
494654 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_FORCE_PURE=ON ..
495655 - cmake -E time cmake --build .
496656 - ctest
657 - cd $TRAVIS_BUILD_DIR
658 - mkdir ./build_test_cmake
659 - cd ./build_test_cmake
660 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
661 - cmake --build .
497662
498663 - os: linux
499664 dist: bionic
500665 env:
501 - MATRIX_EVAL="CC=clang-7.0 && INFO=C++17-pure-debug"
666 - MATRIX_EVAL="CC=clang && CXX=clang++ && INFO=C++17-pure-debug"
502667 script:
503668 - cmake --version
504669 - mkdir ./build_pure_17_debug
506671 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_FORCE_PURE=ON ..
507672 - cmake -E time cmake --build .
508673 - ctest
674 - cd $TRAVIS_BUILD_DIR
675 - mkdir ./build_test_cmake
676 - cd ./build_test_cmake
677 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
678 - cmake --build .
509679
510680 - os: linux
511681 dist: bionic
512682 env:
513 - MATRIX_EVAL="CC=clang-7.0 && INFO=C++17-sse3-release"
683 - MATRIX_EVAL="CC=clang && CXX=clang++ && INFO=C++17-sse3-release
514684 script:
515685 - cmake --version
516686 - mkdir ./build_sse3_17_release
518688 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
519689 - cmake -E time cmake --build .
520690 - ctest
691 - cd $TRAVIS_BUILD_DIR
692 - mkdir ./build_test_cmake
693 - cd ./build_test_cmake
694 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
695 - cmake --build .
521696
522697 - os: linux
523698 dist: bionic
524699 env:
525 - MATRIX_EVAL="CC=clang-7.0 && INFO=C++17-sse3-debug"
700 - MATRIX_EVAL="CC=clang && CXX=clang++ && INFO=C++17-sse3-debug"
526701 script:
527702 - cmake --version
528703 - mkdir ./build_sse3_17_debug
530705 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Debug -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSE3=ON ..
531706 - cmake -E time cmake --build .
532707 - ctest
708 - cd $TRAVIS_BUILD_DIR
709 - mkdir ./build_test_cmake
710 - cd ./build_test_cmake
711 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
712 - cmake --build .
533713
534714 - os: linux
535715 dist: bionic
536716 env:
537 - MATRIX_EVAL="CC=clang-7.0 && INFO=C++17-ssse3-release"
717 - MATRIX_EVAL="CC=clang && CXX=clang++ && INFO=C++17-ssse3-release"
538718 script:
539719 - cmake --version
540720 - mkdir ./build_ssse3_17_release
542722 - cmake -DCMAKE_CXX_COMPILER=$COMPILER -DCMAKE_BUILD_TYPE=Release -DGLM_TEST_ENABLE=ON -DGLM_TEST_ENABLE_CXX_17=ON -DGLM_TEST_ENABLE_LANG_EXTENSIONS=ON -DGLM_TEST_ENABLE_SIMD_SSSE3=ON ..
543723 - cmake -E time cmake --build .
544724 - ctest
725 - cd $TRAVIS_BUILD_DIR
726 - mkdir ./build_test_cmake
727 - cd ./build_test_cmake
728 - cmake -DCMAKE_CXX_COMPILER=$COMPILER $TRAVIS_BUILD_DIR/test/cmake/ -Dglm_DIR=$TRAVIS_BUILD_DIR/cmake/glm/
729 - cmake --build .
545730
546731 before_install:
547732 - eval "${MATRIX_EVAL}"
0 if(${PACKAGE_FIND_VERSION_MAJOR} EQUAL 0)
1 if (${PACKAGE_FIND_VERSION} VERSION_LESS ${GLM_VERSION})
2 set(PACKAGE_VERSION_COMPATIBLE 1)
3 endif()
4 if(${PACKAGE_FIND_VERSION} VERSION_EQUAL ${GLM_VERSION})
5 set(PACKAGE_VERSION_EXACT 1)
6 endif()
7 else()
8 set(PACKAGE_VERSION_UNSUITABLE 1)
9 endif()
10
0 cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
1 cmake_policy(VERSION 3.2)
2
3 set(GLM_VERSION 0.9.9)
4
5 get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
6 get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
7 get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
8 if (_IMPORT_PREFIX STREQUAL "/")
9 set(_IMPORT_PREFIX "")
10 endif()
11
12 # Set the old GLM_INCLUDE_DIRS variable for backwards compatibility
13 set(GLM_INCLUDE_DIRS ${_IMPORT_PREFIX})
14
15 add_library(glm::glm INTERFACE IMPORTED)
16 set_target_properties(glm::glm PROPERTIES
17 INTERFACE_INCLUDE_DIRECTORIES ${GLM_INCLUDE_DIRS})
18
19 mark_as_advanced(glm_DIR)
20 set(_IMPORT_PREFIX)
21
104104 {
105105 GLM_FUNC_QUALIFIER static float call(vec<4, float, Q> const& v)
106106 {
107 return compute_dot<vec<4, float, Q>, float, true>::call(v, v);
107 return sqrt(compute_dot<vec<4, float, Q>, float, true>::call(v, v));
108108 }
109109 };
110110
125125 {
126126 #if GLM_ARCH & GLM_ARCH_ARMV8_BIT
127127 float32x4_t v = vmulq_f32(x.data, y.data);
128 v = vpaddq_f32(v, v);
129 v = vpaddq_f32(v, v);
130 return vgetq_lane_f32(v, 0);
128 return vaddvq_f32(v);
131129 #else // Armv7a with Neon
132130 float32x4_t p = vmulq_f32(x.data, y.data);
133131 float32x2_t v = vpadd_f32(vget_low_f32(p), vget_high_f32(p));
55 #define GLM_VERSION_MAJOR 0
66 #define GLM_VERSION_MINOR 9
77 #define GLM_VERSION_PATCH 9
8 #define GLM_VERSION_REVISION 7
9 #define GLM_VERSION 997
10 #define GLM_VERSION_MESSAGE "GLM: version 0.9.9.7"
8 #define GLM_VERSION_REVISION 8
9 #define GLM_VERSION 998
10 #define GLM_VERSION_MESSAGE "GLM: version 0.9.9.8"
1111
1212 #define GLM_SETUP_INCLUDED GLM_VERSION
1313
484484 GLM_FUNC_QUALIFIER GLM_CONSTEXPR vec<1, T, Q> operator<<(T scalar, vec<1, T, Q> const& v)
485485 {
486486 return vec<1, T, Q>(
487 scalar << v.x);
487 static_cast<T>(scalar << v.x));
488488 }
489489
490490 template<typename T, qualifier Q>
491491 GLM_FUNC_QUALIFIER GLM_CONSTEXPR vec<1, T, Q> operator<<(vec<1, T, Q> const& v1, vec<1, T, Q> const& v2)
492492 {
493493 return vec<1, T, Q>(
494 v1.x << v2.x);
494 static_cast<T>(v1.x << v2.x));
495495 }
496496
497497 template<typename T, qualifier Q>
498498 GLM_FUNC_QUALIFIER GLM_CONSTEXPR vec<1, T, Q> operator>>(vec<1, T, Q> const& v, T scalar)
499499 {
500500 return vec<1, T, Q>(
501 v.x >> scalar);
501 static_cast<T>(v.x >> scalar));
502502 }
503503
504504 template<typename T, qualifier Q>
505505 GLM_FUNC_QUALIFIER GLM_CONSTEXPR vec<1, T, Q> operator>>(T scalar, vec<1, T, Q> const& v)
506506 {
507507 return vec<1, T, Q>(
508 scalar >> v.x);
508 static_cast<T>(scalar >> v.x));
509509 }
510510
511511 template<typename T, qualifier Q>
512512 GLM_FUNC_QUALIFIER GLM_CONSTEXPR vec<1, T, Q> operator>>(vec<1, T, Q> const& v1, vec<1, T, Q> const& v2)
513513 {
514514 return vec<1, T, Q>(
515 v1.x >> v2.x);
515 static_cast<T>(v1.x >> v2.x));
516516 }
517517
518518 template<typename T, qualifier Q>
0 /// @ref ext_matrix_int2x2
1 /// @file glm/ext/matrix_int2x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x2 GLM_EXT_matrix_int2x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int2x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int2x2
24 /// @{
25
26 /// Signed integer 2x2 matrix.
27 ///
28 /// @see ext_matrix_int2x2
29 typedef mat<2, 2, int, defaultp> imat2x2;
30
31 /// Signed integer 2x2 matrix.
32 ///
33 /// @see ext_matrix_int2x2
34 typedef mat<2, 2, int, defaultp> imat2;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_int2x2_sized
1 /// @file glm/ext/matrix_int2x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x2_sized GLM_EXT_matrix_int2x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x2.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int2x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int2x2_sized
25 /// @{
26
27 /// 8 bit signed integer 2x2 matrix.
28 ///
29 /// @see ext_matrix_int2x2_sized
30 typedef mat<2, 2, int8, defaultp> i8mat2x2;
31
32 /// 16 bit signed integer 2x2 matrix.
33 ///
34 /// @see ext_matrix_int2x2_sized
35 typedef mat<2, 2, int16, defaultp> i16mat2x2;
36
37 /// 32 bit signed integer 2x2 matrix.
38 ///
39 /// @see ext_matrix_int2x2_sized
40 typedef mat<2, 2, int32, defaultp> i32mat2x2;
41
42 /// 64 bit signed integer 2x2 matrix.
43 ///
44 /// @see ext_matrix_int2x2_sized
45 typedef mat<2, 2, int64, defaultp> i64mat2x2;
46
47
48 /// 8 bit signed integer 2x2 matrix.
49 ///
50 /// @see ext_matrix_int2x2_sized
51 typedef mat<2, 2, int8, defaultp> i8mat2;
52
53 /// 16 bit signed integer 2x2 matrix.
54 ///
55 /// @see ext_matrix_int2x2_sized
56 typedef mat<2, 2, int16, defaultp> i16mat2;
57
58 /// 32 bit signed integer 2x2 matrix.
59 ///
60 /// @see ext_matrix_int2x2_sized
61 typedef mat<2, 2, int32, defaultp> i32mat2;
62
63 /// 64 bit signed integer 2x2 matrix.
64 ///
65 /// @see ext_matrix_int2x2_sized
66 typedef mat<2, 2, int64, defaultp> i64mat2;
67
68 /// @}
69 }//namespace glm
0 /// @ref ext_matrix_int2x3
1 /// @file glm/ext/matrix_int2x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x3 GLM_EXT_matrix_int2x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int2x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int2x3
24 /// @{
25
26 /// Signed integer 2x3 matrix.
27 ///
28 /// @see ext_matrix_int2x3
29 typedef mat<2, 3, int, defaultp> imat2x3;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int2x3_sized
1 /// @file glm/ext/matrix_int2x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x3_sized GLM_EXT_matrix_int2x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x3.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int2x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int2x3_sized
25 /// @{
26
27 /// 8 bit signed integer 2x3 matrix.
28 ///
29 /// @see ext_matrix_int2x3_sized
30 typedef mat<2, 3, int8, defaultp> i8mat2x3;
31
32 /// 16 bit signed integer 2x3 matrix.
33 ///
34 /// @see ext_matrix_int2x3_sized
35 typedef mat<2, 3, int16, defaultp> i16mat2x3;
36
37 /// 32 bit signed integer 2x3 matrix.
38 ///
39 /// @see ext_matrix_int2x3_sized
40 typedef mat<2, 3, int32, defaultp> i32mat2x3;
41
42 /// 64 bit signed integer 2x3 matrix.
43 ///
44 /// @see ext_matrix_int2x3_sized
45 typedef mat<2, 3, int64, defaultp> i64mat2x3;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int2x4
1 /// @file glm/ext/matrix_int2x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x4 GLM_EXT_matrix_int2x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int2x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int2x4
24 /// @{
25
26 /// Signed integer 2x4 matrix.
27 ///
28 /// @see ext_matrix_int2x4
29 typedef mat<2, 4, int, defaultp> imat2x4;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int2x4_sized
1 /// @file glm/ext/matrix_int2x4_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x4_sized GLM_EXT_matrix_int2x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int2x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x4.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int2x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int2x4_sized
25 /// @{
26
27 /// 8 bit signed integer 2x4 matrix.
28 ///
29 /// @see ext_matrix_int2x4_sized
30 typedef mat<2, 4, int8, defaultp> i8mat2x4;
31
32 /// 16 bit signed integer 2x4 matrix.
33 ///
34 /// @see ext_matrix_int2x4_sized
35 typedef mat<2, 4, int16, defaultp> i16mat2x4;
36
37 /// 32 bit signed integer 2x4 matrix.
38 ///
39 /// @see ext_matrix_int2x4_sized
40 typedef mat<2, 4, int32, defaultp> i32mat2x4;
41
42 /// 64 bit signed integer 2x4 matrix.
43 ///
44 /// @see ext_matrix_int2x4_sized
45 typedef mat<2, 4, int64, defaultp> i64mat2x4;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int3x2
1 /// @file glm/ext/matrix_int3x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x2 GLM_EXT_matrix_int3x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int3x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int3x2
24 /// @{
25
26 /// Signed integer 3x2 matrix.
27 ///
28 /// @see ext_matrix_int3x2
29 typedef mat<3, 2, int, defaultp> imat3x2;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int3x2_sized
1 /// @file glm/ext/matrix_int3x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x2_sized GLM_EXT_matrix_int3x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x2.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int3x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int3x2_sized
25 /// @{
26
27 /// 8 bit signed integer 3x2 matrix.
28 ///
29 /// @see ext_matrix_int3x2_sized
30 typedef mat<3, 2, int8, defaultp> i8mat3x2;
31
32 /// 16 bit signed integer 3x2 matrix.
33 ///
34 /// @see ext_matrix_int3x2_sized
35 typedef mat<3, 2, int16, defaultp> i16mat3x2;
36
37 /// 32 bit signed integer 3x2 matrix.
38 ///
39 /// @see ext_matrix_int3x2_sized
40 typedef mat<3, 2, int32, defaultp> i32mat3x2;
41
42 /// 64 bit signed integer 3x2 matrix.
43 ///
44 /// @see ext_matrix_int3x2_sized
45 typedef mat<3, 2, int64, defaultp> i64mat3x2;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int3x3
1 /// @file glm/ext/matrix_int3x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x3 GLM_EXT_matrix_int3x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int3x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int3x3
24 /// @{
25
26 /// Signed integer 3x3 matrix.
27 ///
28 /// @see ext_matrix_int3x3
29 typedef mat<3, 3, int, defaultp> imat3x3;
30
31 /// Signed integer 3x3 matrix.
32 ///
33 /// @see ext_matrix_int3x3
34 typedef mat<3, 3, int, defaultp> imat3;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_int3x3_sized
1 /// @file glm/ext/matrix_int3x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x3_sized GLM_EXT_matrix_int3x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x3.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int3x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int3x3_sized
25 /// @{
26
27 /// 8 bit signed integer 3x3 matrix.
28 ///
29 /// @see ext_matrix_int3x3_sized
30 typedef mat<3, 3, int8, defaultp> i8mat3x3;
31
32 /// 16 bit signed integer 3x3 matrix.
33 ///
34 /// @see ext_matrix_int3x3_sized
35 typedef mat<3, 3, int16, defaultp> i16mat3x3;
36
37 /// 32 bit signed integer 3x3 matrix.
38 ///
39 /// @see ext_matrix_int3x3_sized
40 typedef mat<3, 3, int32, defaultp> i32mat3x3;
41
42 /// 64 bit signed integer 3x3 matrix.
43 ///
44 /// @see ext_matrix_int3x3_sized
45 typedef mat<3, 3, int64, defaultp> i64mat3x3;
46
47
48 /// 8 bit signed integer 3x3 matrix.
49 ///
50 /// @see ext_matrix_int3x3_sized
51 typedef mat<3, 3, int8, defaultp> i8mat3;
52
53 /// 16 bit signed integer 3x3 matrix.
54 ///
55 /// @see ext_matrix_int3x3_sized
56 typedef mat<3, 3, int16, defaultp> i16mat3;
57
58 /// 32 bit signed integer 3x3 matrix.
59 ///
60 /// @see ext_matrix_int3x3_sized
61 typedef mat<3, 3, int32, defaultp> i32mat3;
62
63 /// 64 bit signed integer 3x3 matrix.
64 ///
65 /// @see ext_matrix_int3x3_sized
66 typedef mat<3, 3, int64, defaultp> i64mat3;
67
68 /// @}
69 }//namespace glm
0 /// @ref ext_matrix_int3x4
1 /// @file glm/ext/matrix_int3x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x4 GLM_EXT_matrix_int3x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int3x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int3x4
24 /// @{
25
26 /// Signed integer 3x4 matrix.
27 ///
28 /// @see ext_matrix_int3x4
29 typedef mat<3, 4, int, defaultp> imat3x4;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int3x4_sized
1 /// @file glm/ext/matrix_int3x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x4_sized GLM_EXT_matrix_int3x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int3x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x4.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int3x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int3x4_sized
25 /// @{
26
27 /// 8 bit signed integer 3x4 matrix.
28 ///
29 /// @see ext_matrix_int3x4_sized
30 typedef mat<3, 4, int8, defaultp> i8mat3x4;
31
32 /// 16 bit signed integer 3x4 matrix.
33 ///
34 /// @see ext_matrix_int3x4_sized
35 typedef mat<3, 4, int16, defaultp> i16mat3x4;
36
37 /// 32 bit signed integer 3x4 matrix.
38 ///
39 /// @see ext_matrix_int3x4_sized
40 typedef mat<3, 4, int32, defaultp> i32mat3x4;
41
42 /// 64 bit signed integer 3x4 matrix.
43 ///
44 /// @see ext_matrix_int3x4_sized
45 typedef mat<3, 4, int64, defaultp> i64mat3x4;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int4x2
1 /// @file glm/ext/matrix_int4x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x2 GLM_EXT_matrix_int4x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int4x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int4x2
24 /// @{
25
26 /// Signed integer 4x2 matrix.
27 ///
28 /// @see ext_matrix_int4x2
29 typedef mat<4, 2, int, defaultp> imat4x2;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int4x2_sized
1 /// @file glm/ext/matrix_int4x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x2_sized GLM_EXT_matrix_int4x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x2.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int4x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int4x2_sized
25 /// @{
26
27 /// 8 bit signed integer 4x2 matrix.
28 ///
29 /// @see ext_matrix_int4x2_sized
30 typedef mat<4, 2, int8, defaultp> i8mat4x2;
31
32 /// 16 bit signed integer 4x2 matrix.
33 ///
34 /// @see ext_matrix_int4x2_sized
35 typedef mat<4, 2, int16, defaultp> i16mat4x2;
36
37 /// 32 bit signed integer 4x2 matrix.
38 ///
39 /// @see ext_matrix_int4x2_sized
40 typedef mat<4, 2, int32, defaultp> i32mat4x2;
41
42 /// 64 bit signed integer 4x2 matrix.
43 ///
44 /// @see ext_matrix_int4x2_sized
45 typedef mat<4, 2, int64, defaultp> i64mat4x2;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int4x3
1 /// @file glm/ext/matrix_int4x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x3 GLM_EXT_matrix_int4x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int4x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int4x3
24 /// @{
25
26 /// Signed integer 4x3 matrix.
27 ///
28 /// @see ext_matrix_int4x3
29 typedef mat<4, 3, int, defaultp> imat4x3;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_int4x3_sized
1 /// @file glm/ext/matrix_int4x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x3_sized GLM_EXT_matrix_int4x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x3.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int4x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int4x3_sized
25 /// @{
26
27 /// 8 bit signed integer 4x3 matrix.
28 ///
29 /// @see ext_matrix_int4x3_sized
30 typedef mat<4, 3, int8, defaultp> i8mat4x3;
31
32 /// 16 bit signed integer 4x3 matrix.
33 ///
34 /// @see ext_matrix_int4x3_sized
35 typedef mat<4, 3, int16, defaultp> i16mat4x3;
36
37 /// 32 bit signed integer 4x3 matrix.
38 ///
39 /// @see ext_matrix_int4x3_sized
40 typedef mat<4, 3, int32, defaultp> i32mat4x3;
41
42 /// 64 bit signed integer 4x3 matrix.
43 ///
44 /// @see ext_matrix_int4x3_sized
45 typedef mat<4, 3, int64, defaultp> i64mat4x3;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_int4x4
1 /// @file glm/ext/matrix_int4x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x4 GLM_EXT_matrix_int4x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_int4x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_int4x4
24 /// @{
25
26 /// Signed integer 4x4 matrix.
27 ///
28 /// @see ext_matrix_int4x4
29 typedef mat<4, 4, int, defaultp> imat4x4;
30
31 /// Signed integer 4x4 matrix.
32 ///
33 /// @see ext_matrix_int4x4
34 typedef mat<4, 4, int, defaultp> imat4;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_int4x4_sized
1 /// @file glm/ext/matrix_int4x4_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int4x4_sized GLM_EXT_matrix_int4x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_int4x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x4.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_int4x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_int4x4_sized
25 /// @{
26
27 /// 8 bit signed integer 4x4 matrix.
28 ///
29 /// @see ext_matrix_int4x4_sized
30 typedef mat<4, 4, int8, defaultp> i8mat4x4;
31
32 /// 16 bit signed integer 4x4 matrix.
33 ///
34 /// @see ext_matrix_int4x4_sized
35 typedef mat<4, 4, int16, defaultp> i16mat4x4;
36
37 /// 32 bit signed integer 4x4 matrix.
38 ///
39 /// @see ext_matrix_int4x4_sized
40 typedef mat<4, 4, int32, defaultp> i32mat4x4;
41
42 /// 64 bit signed integer 4x4 matrix.
43 ///
44 /// @see ext_matrix_int4x4_sized
45 typedef mat<4, 4, int64, defaultp> i64mat4x4;
46
47
48 /// 8 bit signed integer 4x4 matrix.
49 ///
50 /// @see ext_matrix_int4x4_sized
51 typedef mat<4, 4, int8, defaultp> i8mat4;
52
53 /// 16 bit signed integer 4x4 matrix.
54 ///
55 /// @see ext_matrix_int4x4_sized
56 typedef mat<4, 4, int16, defaultp> i16mat4;
57
58 /// 32 bit signed integer 4x4 matrix.
59 ///
60 /// @see ext_matrix_int4x4_sized
61 typedef mat<4, 4, int32, defaultp> i32mat4;
62
63 /// 64 bit signed integer 4x4 matrix.
64 ///
65 /// @see ext_matrix_int4x4_sized
66 typedef mat<4, 4, int64, defaultp> i64mat4;
67
68 /// @}
69 }//namespace glm
3434 template<typename T, typename U, qualifier Q>
3535 GLM_FUNC_QUALIFIER vec<3, T, Q> project(vec<3, T, Q> const& obj, mat<4, 4, T, Q> const& model, mat<4, 4, T, Q> const& proj, vec<4, U, Q> const& viewport)
3636 {
37 if(GLM_CONFIG_CLIP_CONTROL & GLM_CLIP_CONTROL_ZO_BIT)
37 # if GLM_CONFIG_CLIP_CONTROL & GLM_CLIP_CONTROL_ZO_BIT
3838 return projectZO(obj, model, proj, viewport);
39 else
39 # else
4040 return projectNO(obj, model, proj, viewport);
41 # endif
4142 }
4243
4344 template<typename T, typename U, qualifier Q>
7677 template<typename T, typename U, qualifier Q>
7778 GLM_FUNC_QUALIFIER vec<3, T, Q> unProject(vec<3, T, Q> const& win, mat<4, 4, T, Q> const& model, mat<4, 4, T, Q> const& proj, vec<4, U, Q> const& viewport)
7879 {
79 if(GLM_CONFIG_CLIP_CONTROL & GLM_CLIP_CONTROL_ZO_BIT)
80 # if GLM_CONFIG_CLIP_CONTROL & GLM_CLIP_CONTROL_ZO_BIT
8081 return unProjectZO(win, model, proj, viewport);
81 else
82 # else
8283 return unProjectNO(win, model, proj, viewport);
84 # endif
8385 }
8486
8587 template<typename T, qualifier Q, typename U>
0 /// @ref ext_matrix_uint2x2
1 /// @file glm/ext/matrix_uint2x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint2x2 GLM_EXT_matrix_uint2x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint2x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint2x2
24 /// @{
25
26 /// Unsigned integer 2x2 matrix.
27 ///
28 /// @see ext_matrix_uint2x2
29 typedef mat<2, 2, uint, defaultp> umat2x2;
30
31 /// Unsigned integer 2x2 matrix.
32 ///
33 /// @see ext_matrix_uint2x2
34 typedef mat<2, 2, uint, defaultp> umat2;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_uint2x2_sized
1 /// @file glm/ext/matrix_uint2x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint2x2_sized GLM_EXT_matrix_uint2x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x2.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint2x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint2x2_sized
25 /// @{
26
27 /// 8 bit unsigned integer 2x2 matrix.
28 ///
29 /// @see ext_matrix_uint2x2_sized
30 typedef mat<2, 2, uint8, defaultp> u8mat2x2;
31
32 /// 16 bit unsigned integer 2x2 matrix.
33 ///
34 /// @see ext_matrix_uint2x2_sized
35 typedef mat<2, 2, uint16, defaultp> u16mat2x2;
36
37 /// 32 bit unsigned integer 2x2 matrix.
38 ///
39 /// @see ext_matrix_uint2x2_sized
40 typedef mat<2, 2, uint32, defaultp> u32mat2x2;
41
42 /// 64 bit unsigned integer 2x2 matrix.
43 ///
44 /// @see ext_matrix_uint2x2_sized
45 typedef mat<2, 2, uint64, defaultp> u64mat2x2;
46
47
48 /// 8 bit unsigned integer 2x2 matrix.
49 ///
50 /// @see ext_matrix_uint2x2_sized
51 typedef mat<2, 2, uint8, defaultp> u8mat2;
52
53 /// 16 bit unsigned integer 2x2 matrix.
54 ///
55 /// @see ext_matrix_uint2x2_sized
56 typedef mat<2, 2, uint16, defaultp> u16mat2;
57
58 /// 32 bit unsigned integer 2x2 matrix.
59 ///
60 /// @see ext_matrix_uint2x2_sized
61 typedef mat<2, 2, uint32, defaultp> u32mat2;
62
63 /// 64 bit unsigned integer 2x2 matrix.
64 ///
65 /// @see ext_matrix_uint2x2_sized
66 typedef mat<2, 2, uint64, defaultp> u64mat2;
67
68 /// @}
69 }//namespace glm
0 /// @ref ext_matrix_uint2x3
1 /// @file glm/ext/matrix_uint2x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int2x3 GLM_EXT_matrix_uint2x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint2x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint2x3
24 /// @{
25
26 /// Unsigned integer 2x3 matrix.
27 ///
28 /// @see ext_matrix_uint2x3
29 typedef mat<2, 3, uint, defaultp> umat2x3;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint2x3_sized
1 /// @file glm/ext/matrix_uint2x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint2x3_sized GLM_EXT_matrix_uint2x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x3.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint2x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint2x3_sized
25 /// @{
26
27 /// 8 bit unsigned integer 2x3 matrix.
28 ///
29 /// @see ext_matrix_uint2x3_sized
30 typedef mat<2, 3, uint8, defaultp> u8mat2x3;
31
32 /// 16 bit unsigned integer 2x3 matrix.
33 ///
34 /// @see ext_matrix_uint2x3_sized
35 typedef mat<2, 3, uint16, defaultp> u16mat2x3;
36
37 /// 32 bit unsigned integer 2x3 matrix.
38 ///
39 /// @see ext_matrix_uint2x3_sized
40 typedef mat<2, 3, uint32, defaultp> u32mat2x3;
41
42 /// 64 bit unsigned integer 2x3 matrix.
43 ///
44 /// @see ext_matrix_uint2x3_sized
45 typedef mat<2, 3, uint64, defaultp> u64mat2x3;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint2x4
1 /// @file glm/ext/matrix_uint2x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint2x4 GLM_EXT_matrix_int2x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint2x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint2x4
24 /// @{
25
26 /// Unsigned integer 2x4 matrix.
27 ///
28 /// @see ext_matrix_uint2x4
29 typedef mat<2, 4, uint, defaultp> umat2x4;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint2x4_sized
1 /// @file glm/ext/matrixu_uint2x4_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint2x4_sized GLM_EXT_matrix_uint2x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint2x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat2x4.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint2x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint2x4_sized
25 /// @{
26
27 /// 8 bit unsigned integer 2x4 matrix.
28 ///
29 /// @see ext_matrix_uint2x4_sized
30 typedef mat<2, 4, uint8, defaultp> u8mat2x4;
31
32 /// 16 bit unsigned integer 2x4 matrix.
33 ///
34 /// @see ext_matrix_uint2x4_sized
35 typedef mat<2, 4, uint16, defaultp> u16mat2x4;
36
37 /// 32 bit unsigned integer 2x4 matrix.
38 ///
39 /// @see ext_matrix_uint2x4_sized
40 typedef mat<2, 4, uint32, defaultp> u32mat2x4;
41
42 /// 64 bit unsigned integer 2x4 matrix.
43 ///
44 /// @see ext_matrix_uint2x4_sized
45 typedef mat<2, 4, uint64, defaultp> u64mat2x4;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint3x2
1 /// @file glm/ext/matrix_uint3x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_int3x2 GLM_EXT_matrix_uint3x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint3x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint3x2
24 /// @{
25
26 /// Unsigned integer 3x2 matrix.
27 ///
28 /// @see ext_matrix_uint3x2
29 typedef mat<3, 2, uint, defaultp> umat3x2;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint3x2_sized
1 /// @file glm/ext/matrix_uint3x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint3x2_sized GLM_EXT_matrix_uint3x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x2.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint3x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint3x2_sized
25 /// @{
26
27 /// 8 bit signed integer 3x2 matrix.
28 ///
29 /// @see ext_matrix_uint3x2_sized
30 typedef mat<3, 2, uint8, defaultp> u8mat3x2;
31
32 /// 16 bit signed integer 3x2 matrix.
33 ///
34 /// @see ext_matrix_uint3x2_sized
35 typedef mat<3, 2, uint16, defaultp> u16mat3x2;
36
37 /// 32 bit signed integer 3x2 matrix.
38 ///
39 /// @see ext_matrix_uint3x2_sized
40 typedef mat<3, 2, uint32, defaultp> u32mat3x2;
41
42 /// 64 bit signed integer 3x2 matrix.
43 ///
44 /// @see ext_matrix_uint3x2_sized
45 typedef mat<3, 2, uint64, defaultp> u64mat3x2;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint3x3
1 /// @file glm/ext/matrix_uint3x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint3x3 GLM_EXT_matrix_uint3x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint3x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint3x3
24 /// @{
25
26 /// Unsigned integer 3x3 matrix.
27 ///
28 /// @see ext_matrix_uint3x3
29 typedef mat<3, 3, uint, defaultp> umat3x3;
30
31 /// Unsigned integer 3x3 matrix.
32 ///
33 /// @see ext_matrix_uint3x3
34 typedef mat<3, 3, uint, defaultp> umat3;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_uint3x3_sized
1 /// @file glm/ext/matrix_uint3x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint3x3_sized GLM_EXT_matrix_uint3x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x3.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint3x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint3x3_sized
25 /// @{
26
27 /// 8 bit unsigned integer 3x3 matrix.
28 ///
29 /// @see ext_matrix_uint3x3_sized
30 typedef mat<3, 3, uint8, defaultp> u8mat3x3;
31
32 /// 16 bit unsigned integer 3x3 matrix.
33 ///
34 /// @see ext_matrix_uint3x3_sized
35 typedef mat<3, 3, uint16, defaultp> u16mat3x3;
36
37 /// 32 bit unsigned integer 3x3 matrix.
38 ///
39 /// @see ext_matrix_uint3x3_sized
40 typedef mat<3, 3, uint32, defaultp> u32mat3x3;
41
42 /// 64 bit unsigned integer 3x3 matrix.
43 ///
44 /// @see ext_matrix_uint3x3_sized
45 typedef mat<3, 3, uint64, defaultp> u64mat3x3;
46
47
48 /// 8 bit unsigned integer 3x3 matrix.
49 ///
50 /// @see ext_matrix_uint3x3_sized
51 typedef mat<3, 3, uint8, defaultp> u8mat3;
52
53 /// 16 bit unsigned integer 3x3 matrix.
54 ///
55 /// @see ext_matrix_uint3x3_sized
56 typedef mat<3, 3, uint16, defaultp> u16mat3;
57
58 /// 32 bit unsigned integer 3x3 matrix.
59 ///
60 /// @see ext_matrix_uint3x3_sized
61 typedef mat<3, 3, uint32, defaultp> u32mat3;
62
63 /// 64 bit unsigned integer 3x3 matrix.
64 ///
65 /// @see ext_matrix_uint3x3_sized
66 typedef mat<3, 3, uint64, defaultp> u64mat3;
67
68 /// @}
69 }//namespace glm
0 /// @ref ext_matrix_uint3x4
1 /// @file glm/ext/matrix_uint3x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint3x4 GLM_EXT_matrix_uint3x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint3x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint3x4
24 /// @{
25
26 /// Signed integer 3x4 matrix.
27 ///
28 /// @see ext_matrix_uint3x4
29 typedef mat<3, 4, uint, defaultp> umat3x4;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint3x4_sized
1 /// @file glm/ext/matrix_uint3x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint3x4_sized GLM_EXT_matrix_uint3x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint3x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat3x4.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint3x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint3x4_sized
25 /// @{
26
27 /// 8 bit unsigned integer 3x4 matrix.
28 ///
29 /// @see ext_matrix_uint3x4_sized
30 typedef mat<3, 4, uint8, defaultp> u8mat3x4;
31
32 /// 16 bit unsigned integer 3x4 matrix.
33 ///
34 /// @see ext_matrix_uint3x4_sized
35 typedef mat<3, 4, uint16, defaultp> u16mat3x4;
36
37 /// 32 bit unsigned integer 3x4 matrix.
38 ///
39 /// @see ext_matrix_uint3x4_sized
40 typedef mat<3, 4, uint32, defaultp> u32mat3x4;
41
42 /// 64 bit unsigned integer 3x4 matrix.
43 ///
44 /// @see ext_matrix_uint3x4_sized
45 typedef mat<3, 4, uint64, defaultp> u64mat3x4;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint4x2
1 /// @file glm/ext/matrix_uint4x2.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x2 GLM_EXT_matrix_uint4x2
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x2.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x2.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint4x2 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint4x2
24 /// @{
25
26 /// Unsigned integer 4x2 matrix.
27 ///
28 /// @see ext_matrix_uint4x2
29 typedef mat<4, 2, uint, defaultp> umat4x2;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint4x2_sized
1 /// @file glm/ext/matrix_uint4x2_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x2_sized GLM_EXT_matrix_uint4x2_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x2_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x2.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint4x2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint4x2_sized
25 /// @{
26
27 /// 8 bit unsigned integer 4x2 matrix.
28 ///
29 /// @see ext_matrix_uint4x2_sized
30 typedef mat<4, 2, uint8, defaultp> u8mat4x2;
31
32 /// 16 bit unsigned integer 4x2 matrix.
33 ///
34 /// @see ext_matrix_uint4x2_sized
35 typedef mat<4, 2, uint16, defaultp> u16mat4x2;
36
37 /// 32 bit unsigned integer 4x2 matrix.
38 ///
39 /// @see ext_matrix_uint4x2_sized
40 typedef mat<4, 2, uint32, defaultp> u32mat4x2;
41
42 /// 64 bit unsigned integer 4x2 matrix.
43 ///
44 /// @see ext_matrix_uint4x2_sized
45 typedef mat<4, 2, uint64, defaultp> u64mat4x2;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint4x3
1 /// @file glm/ext/matrix_uint4x3.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x3 GLM_EXT_matrix_uint4x3
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x3.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x3.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint4x3 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint4x3
24 /// @{
25
26 /// Unsigned integer 4x3 matrix.
27 ///
28 /// @see ext_matrix_uint4x3
29 typedef mat<4, 3, uint, defaultp> umat4x3;
30
31 /// @}
32 }//namespace glm
0 /// @ref ext_matrix_uint4x3_sized
1 /// @file glm/ext/matrix_uint4x3_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x3_sized GLM_EXT_matrix_uint4x3_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x3_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x3.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint4x3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint4x3_sized
25 /// @{
26
27 /// 8 bit unsigned integer 4x3 matrix.
28 ///
29 /// @see ext_matrix_uint4x3_sized
30 typedef mat<4, 3, uint8, defaultp> u8mat4x3;
31
32 /// 16 bit unsigned integer 4x3 matrix.
33 ///
34 /// @see ext_matrix_uint4x3_sized
35 typedef mat<4, 3, uint16, defaultp> u16mat4x3;
36
37 /// 32 bit unsigned integer 4x3 matrix.
38 ///
39 /// @see ext_matrix_uint4x3_sized
40 typedef mat<4, 3, uint32, defaultp> u32mat4x3;
41
42 /// 64 bit unsigned integer 4x3 matrix.
43 ///
44 /// @see ext_matrix_uint4x3_sized
45 typedef mat<4, 3, uint64, defaultp> u64mat4x3;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_matrix_uint4x4
1 /// @file glm/ext/matrix_uint4x4.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x4 GLM_EXT_matrix_uint4x4
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x4.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x4.hpp"
16
17 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
18 # pragma message("GLM: GLM_EXT_matrix_uint4x4 extension included")
19 #endif
20
21 namespace glm
22 {
23 /// @addtogroup ext_matrix_uint4x4
24 /// @{
25
26 /// Unsigned integer 4x4 matrix.
27 ///
28 /// @see ext_matrix_uint4x4
29 typedef mat<4, 4, uint, defaultp> umat4x4;
30
31 /// Unsigned integer 4x4 matrix.
32 ///
33 /// @see ext_matrix_uint4x4
34 typedef mat<4, 4, uint, defaultp> umat4;
35
36 /// @}
37 }//namespace glm
0 /// @ref ext_matrix_uint4x4_sized
1 /// @file glm/ext/matrix_uint4x4_sized.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_matrix_uint4x4_sized GLM_EXT_matrix_uint4x4_sized
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/matrix_uint4x4_sized.hpp> to use the features of this extension.
9 ///
10 /// Defines a number of matrices with integer types.
11
12 #pragma once
13
14 // Dependency:
15 #include "../mat4x4.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_matrix_uint4x4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_matrix_uint4x4_sized
25 /// @{
26
27 /// 8 bit unsigned integer 4x4 matrix.
28 ///
29 /// @see ext_matrix_uint4x4_sized
30 typedef mat<4, 4, uint8, defaultp> u8mat4x4;
31
32 /// 16 bit unsigned integer 4x4 matrix.
33 ///
34 /// @see ext_matrix_uint4x4_sized
35 typedef mat<4, 4, uint16, defaultp> u16mat4x4;
36
37 /// 32 bit unsigned integer 4x4 matrix.
38 ///
39 /// @see ext_matrix_uint4x4_sized
40 typedef mat<4, 4, uint32, defaultp> u32mat4x4;
41
42 /// 64 bit unsigned integer 4x4 matrix.
43 ///
44 /// @see ext_matrix_uint4x4_sized
45 typedef mat<4, 4, uint64, defaultp> u64mat4x4;
46
47
48 /// 8 bit unsigned integer 4x4 matrix.
49 ///
50 /// @see ext_matrix_uint4x4_sized
51 typedef mat<4, 4, uint8, defaultp> u8mat4;
52
53 /// 16 bit unsigned integer 4x4 matrix.
54 ///
55 /// @see ext_matrix_uint4x4_sized
56 typedef mat<4, 4, uint16, defaultp> u16mat4;
57
58 /// 32 bit unsigned integer 4x4 matrix.
59 ///
60 /// @see ext_matrix_uint4x4_sized
61 typedef mat<4, 4, uint32, defaultp> u32mat4;
62
63 /// 64 bit unsigned integer 4x4 matrix.
64 ///
65 /// @see ext_matrix_uint4x4_sized
66 typedef mat<4, 4, uint64, defaultp> u64mat4;
67
68 /// @}
69 }//namespace glm
7575 template<typename T, qualifier Q>
7676 GLM_FUNC_DECL qua<T, Q> slerp(qua<T, Q> const& x, qua<T, Q> const& y, T a);
7777
78 /// Spherical linear interpolation of two quaternions with multiple spins over rotation axis.
79 /// The interpolation always take the short path when the spin count is positive and long path
80 /// when count is negative. Rotation is performed at constant speed.
81 ///
82 /// @param x A quaternion
83 /// @param y A quaternion
84 /// @param a Interpolation factor. The interpolation is defined beyond the range [0, 1].
85 /// @param k Additional spin count. If Value is negative interpolation will be on "long" path.
86 ///
87 /// @tparam T A floating-point scalar type
88 /// @tparam S An integer scalar type
89 /// @tparam Q A value from qualifier enum
90 template<typename T, typename S, qualifier Q>
91 GLM_FUNC_DECL qua<T, Q> slerp(qua<T, Q> const& x, qua<T, Q> const& y, T a, S k);
92
7893 /// Returns the q conjugate.
7994 ///
8095 /// @tparam T A floating-point scalar type
7171 }
7272 }
7373
74 template<typename T, typename S, qualifier Q>
75 GLM_FUNC_QUALIFIER qua<T, Q> slerp(qua<T, Q> const& x, qua<T, Q> const& y, T a, S k)
76 {
77 GLM_STATIC_ASSERT(std::numeric_limits<T>::is_iec559, "'slerp' only accept floating-point inputs");
78 GLM_STATIC_ASSERT(std::numeric_limits<S>::is_integer, "'slerp' only accept integer for spin count");
79
80 qua<T, Q> z = y;
81
82 T cosTheta = dot(x, y);
83
84 // If cosTheta < 0, the interpolation will take the long way around the sphere.
85 // To fix this, one quat must be negated.
86 if (cosTheta < static_cast<T>(0))
87 {
88 z = -y;
89 cosTheta = -cosTheta;
90 }
91
92 // Perform a linear interpolation when cosTheta is close to 1 to avoid side effect of sin(angle) becoming a zero denominator
93 if (cosTheta > static_cast<T>(1) - epsilon<T>())
94 {
95 // Linear interpolation
96 return qua<T, Q>(
97 mix(x.w, z.w, a),
98 mix(x.x, z.x, a),
99 mix(x.y, z.y, a),
100 mix(x.z, z.z, a));
101 }
102 else
103 {
104 // Graphics Gems III, page 96
105 T angle = acos(cosTheta);
106 T phi = angle + k * glm::pi<T>();
107 return (sin(angle - a * phi)* x + sin(a * phi) * z) / sin(angle);
108 }
109 }
110
74111 template<typename T, qualifier Q>
75112 GLM_FUNC_QUALIFIER qua<T, Q> conjugate(qua<T, Q> const& q)
76113 {
2727 /// Returns the minimum component-wise values of 3 inputs
2828 ///
2929 /// @tparam T A floating-point scalar type.
30 ///
31 /// @see ext_scalar_common
3032 template<typename T>
3133 GLM_FUNC_DECL T min(T a, T b, T c);
3234
3335 /// Returns the minimum component-wise values of 4 inputs
3436 ///
3537 /// @tparam T A floating-point scalar type.
38 ///
39 /// @see ext_scalar_common
3640 template<typename T>
3741 GLM_FUNC_DECL T min(T a, T b, T c, T d);
3842
3943 /// Returns the maximum component-wise values of 3 inputs
4044 ///
4145 /// @tparam T A floating-point scalar type.
46 ///
47 /// @see ext_scalar_common
4248 template<typename T>
4349 GLM_FUNC_DECL T max(T a, T b, T c);
4450
4551 /// Returns the maximum component-wise values of 4 inputs
4652 ///
4753 /// @tparam T A floating-point scalar type.
54 ///
55 /// @see ext_scalar_common
4856 template<typename T>
4957 GLM_FUNC_DECL T max(T a, T b, T c, T d);
5058
5361 /// @tparam T A floating-point scalar type.
5462 ///
5563 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmin">std::fmin documentation</a>
64 /// @see ext_scalar_common
5665 template<typename T>
5766 GLM_FUNC_DECL T fmin(T a, T b);
5867
6170 /// @tparam T A floating-point scalar type.
6271 ///
6372 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmin">std::fmin documentation</a>
73 /// @see ext_scalar_common
6474 template<typename T>
6575 GLM_FUNC_DECL T fmin(T a, T b, T c);
6676
6979 /// @tparam T A floating-point scalar type.
7080 ///
7181 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmin">std::fmin documentation</a>
82 /// @see ext_scalar_common
7283 template<typename T>
7384 GLM_FUNC_DECL T fmin(T a, T b, T c, T d);
7485
7788 /// @tparam T A floating-point scalar type.
7889 ///
7990 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmax">std::fmax documentation</a>
91 /// @see ext_scalar_common
8092 template<typename T>
8193 GLM_FUNC_DECL T fmax(T a, T b);
8294
8597 /// @tparam T A floating-point scalar type.
8698 ///
8799 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmax">std::fmax documentation</a>
100 /// @see ext_scalar_common
88101 template<typename T>
89102 GLM_FUNC_DECL T fmax(T a, T b, T C);
90103
93106 /// @tparam T A floating-point scalar type.
94107 ///
95108 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmax">std::fmax documentation</a>
109 /// @see ext_scalar_common
96110 template<typename T>
97111 GLM_FUNC_DECL T fmax(T a, T b, T C, T D);
112
113 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
114 ///
115 /// @tparam genType Floating-point scalar types.
116 ///
117 /// @see ext_scalar_common
118 template<typename genType>
119 GLM_FUNC_DECL genType fclamp(genType x, genType minVal, genType maxVal);
120
121 /// Simulate GL_CLAMP OpenGL wrap mode
122 ///
123 /// @tparam genType Floating-point scalar types.
124 ///
125 /// @see ext_scalar_common extension.
126 template<typename genType>
127 GLM_FUNC_DECL genType clamp(genType const& Texcoord);
128
129 /// Simulate GL_REPEAT OpenGL wrap mode
130 ///
131 /// @tparam genType Floating-point scalar types.
132 ///
133 /// @see ext_scalar_common extension.
134 template<typename genType>
135 GLM_FUNC_DECL genType repeat(genType const& Texcoord);
136
137 /// Simulate GL_MIRRORED_REPEAT OpenGL wrap mode
138 ///
139 /// @tparam genType Floating-point scalar types.
140 ///
141 /// @see ext_scalar_common extension.
142 template<typename genType>
143 GLM_FUNC_DECL genType mirrorClamp(genType const& Texcoord);
144
145 /// Simulate GL_MIRROR_REPEAT OpenGL wrap mode
146 ///
147 /// @tparam genType Floating-point scalar types.
148 ///
149 /// @see ext_scalar_common extension.
150 template<typename genType>
151 GLM_FUNC_DECL genType mirrorRepeat(genType const& Texcoord);
98152
99153 /// @}
100154 }//namespace glm
111111 return max(a, b, c);
112112 return max(a, b, c, d);
113113 }
114
115 // fclamp
116 template<typename genType>
117 GLM_FUNC_QUALIFIER genType fclamp(genType x, genType minVal, genType maxVal)
118 {
119 GLM_STATIC_ASSERT(std::numeric_limits<genType>::is_iec559, "'fclamp' only accept floating-point or integer inputs");
120 return fmin(fmax(x, minVal), maxVal);
121 }
122
123 template<typename genType>
124 GLM_FUNC_QUALIFIER genType clamp(genType const& Texcoord)
125 {
126 return glm::clamp(Texcoord, static_cast<genType>(0), static_cast<genType>(1));
127 }
128
129 template<typename genType>
130 GLM_FUNC_QUALIFIER genType repeat(genType const& Texcoord)
131 {
132 return glm::fract(Texcoord);
133 }
134
135 template<typename genType>
136 GLM_FUNC_QUALIFIER genType mirrorClamp(genType const& Texcoord)
137 {
138 return glm::fract(glm::abs(Texcoord));
139 }
140
141 template<typename genType>
142 GLM_FUNC_QUALIFIER genType mirrorRepeat(genType const& Texcoord)
143 {
144 genType const Abs = glm::abs(Texcoord);
145 genType const Clamp = glm::mod(glm::floor(Abs), static_cast<genType>(2));
146 genType const Floor = glm::floor(Abs);
147 genType const Rest = Abs - Floor;
148 genType const Mirror = Clamp + Rest;
149 return mix(Rest, static_cast<genType>(1) - Rest, Mirror >= static_cast<genType>(1));
150 }
114151 }//namespace glm
0 /// @ref ext_scalar_packing
1 /// @file glm/ext/scalar_packing.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_scalar_packing GLM_EXT_scalar_packing
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/scalar_packing.hpp> to use the features of this extension.
9 ///
10 /// This extension provides a set of function to convert scalar values to packed
11 /// formats.
12
13 #pragma once
14
15 // Dependency:
16 #include "../detail/qualifier.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_scalar_packing extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_scalar_packing
25 /// @{
26
27
28 /// @}
29 }// namespace glm
30
31 #include "scalar_packing.inl"
(New empty file)
137137 template<length_t L, typename T, qualifier Q>
138138 GLM_FUNC_DECL vec<L, T, Q> fmax(vec<L, T, Q> const& a, vec<L, T, Q> const& b, vec<L, T, Q> const& c, vec<L, T, Q> const& d);
139139
140 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
141 ///
142 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
143 /// @tparam T Floating-point scalar types
144 /// @tparam Q Value from qualifier enum
145 ///
146 /// @see ext_vector_common
147 template<length_t L, typename T, qualifier Q>
148 GLM_FUNC_DECL vec<L, T, Q> fclamp(vec<L, T, Q> const& x, T minVal, T maxVal);
149
150 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
151 ///
152 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
153 /// @tparam T Floating-point scalar types
154 /// @tparam Q Value from qualifier enum
155 ///
156 /// @see ext_vector_common
157 template<length_t L, typename T, qualifier Q>
158 GLM_FUNC_DECL vec<L, T, Q> fclamp(vec<L, T, Q> const& x, vec<L, T, Q> const& minVal, vec<L, T, Q> const& maxVal);
159
160 /// Simulate GL_CLAMP OpenGL wrap mode
161 ///
162 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
163 /// @tparam T Floating-point scalar types
164 /// @tparam Q Value from qualifier enum
165 ///
166 /// @see ext_vector_common extension.
167 template<length_t L, typename T, qualifier Q>
168 GLM_FUNC_DECL vec<L, T, Q> clamp(vec<L, T, Q> const& Texcoord);
169
170 /// Simulate GL_REPEAT OpenGL wrap mode
171 ///
172 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
173 /// @tparam T Floating-point scalar types
174 /// @tparam Q Value from qualifier enum
175 ///
176 /// @see ext_vector_common extension.
177 template<length_t L, typename T, qualifier Q>
178 GLM_FUNC_DECL vec<L, T, Q> repeat(vec<L, T, Q> const& Texcoord);
179
180 /// Simulate GL_MIRRORED_REPEAT OpenGL wrap mode
181 ///
182 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
183 /// @tparam T Floating-point scalar types
184 /// @tparam Q Value from qualifier enum
185 ///
186 /// @see ext_vector_common extension.
187 template<length_t L, typename T, qualifier Q>
188 GLM_FUNC_DECL vec<L, T, Q> mirrorClamp(vec<L, T, Q> const& Texcoord);
189
190 /// Simulate GL_MIRROR_REPEAT OpenGL wrap mode
191 ///
192 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
193 /// @tparam T Floating-point scalar types
194 /// @tparam Q Value from qualifier enum
195 ///
196 /// @see ext_vector_common extension.
197 template<length_t L, typename T, qualifier Q>
198 GLM_FUNC_DECL vec<L, T, Q> mirrorRepeat(vec<L, T, Q> const& Texcoord);
199
140200 /// @}
141201 }//namespace glm
142202
8484 GLM_STATIC_ASSERT(std::numeric_limits<T>::is_iec559, "'fmax' only accept floating-point inputs");
8585 return fmax(fmax(a, b), fmax(c, d));
8686 }
87
88 template<length_t L, typename T, qualifier Q>
89 GLM_FUNC_QUALIFIER vec<L, T, Q> fclamp(vec<L, T, Q> const& x, T minVal, T maxVal)
90 {
91 return fmin(fmax(x, vec<L, T, Q>(minVal)), vec<L, T, Q>(maxVal));
92 }
93
94 template<length_t L, typename T, qualifier Q>
95 GLM_FUNC_QUALIFIER vec<L, T, Q> fclamp(vec<L, T, Q> const& x, vec<L, T, Q> const& minVal, vec<L, T, Q> const& maxVal)
96 {
97 return fmin(fmax(x, minVal), maxVal);
98 }
99
100 template<length_t L, typename T, qualifier Q>
101 GLM_FUNC_QUALIFIER vec<L, T, Q> clamp(vec<L, T, Q> const& Texcoord)
102 {
103 return glm::clamp(Texcoord, vec<L, T, Q>(0), vec<L, T, Q>(1));
104 }
105
106 template<length_t L, typename T, qualifier Q>
107 GLM_FUNC_QUALIFIER vec<L, T, Q> repeat(vec<L, T, Q> const& Texcoord)
108 {
109 return glm::fract(Texcoord);
110 }
111
112 template<length_t L, typename T, qualifier Q>
113 GLM_FUNC_QUALIFIER vec<L, T, Q> mirrorClamp(vec<L, T, Q> const& Texcoord)
114 {
115 return glm::fract(glm::abs(Texcoord));
116 }
117
118 template<length_t L, typename T, qualifier Q>
119 GLM_FUNC_QUALIFIER vec<L, T, Q> mirrorRepeat(vec<L, T, Q> const& Texcoord)
120 {
121 vec<L, T, Q> const Abs = glm::abs(Texcoord);
122 vec<L, T, Q> const Clamp = glm::mod(glm::floor(Abs), vec<L, T, Q>(2));
123 vec<L, T, Q> const Floor = glm::floor(Abs);
124 vec<L, T, Q> const Rest = Abs - Floor;
125 vec<L, T, Q> const Mirror = Clamp + Rest;
126 return mix(Rest, vec<L, T, Q>(1) - Rest, glm::greaterThanEqual(Mirror, vec<L, T, Q>(1)));
127 }
87128 }//namespace glm
+0
-34
glm/ext/vector_int1_precision.hpp less more
0 /// @ref ext_vector_int1_precision
1 /// @file glm/ext/vector_int1_precision.hpp
2 ///
3 /// @defgroup ext_vector_int1_precision GLM_EXT_vector_int1_precision
4 /// @ingroup ext
5 ///
6 /// Exposes highp_ivec1, mediump_ivec1 and lowp_ivec1 types.
7 ///
8 /// Include <glm/ext/vector_int1_precision.hpp> to use the features of this extension.
9
10 #pragma once
11
12 #include "../detail/type_vec1.hpp"
13
14 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
15 # pragma message("GLM: GLM_EXT_vector_int1_precision extension included")
16 #endif
17
18 namespace glm
19 {
20 /// @addtogroup ext_vector_int1_precision
21 /// @{
22
23 /// 1 component vector of signed integer values.
24 typedef vec<1, int, highp> highp_ivec1;
25
26 /// 1 component vector of signed integer values.
27 typedef vec<1, int, mediump> mediump_ivec1;
28
29 /// 1 component vector of signed integer values.
30 typedef vec<1, int, lowp> lowp_ivec1;
31
32 /// @}
33 }//namespace glm
0 /// @ref ext_vector_int1_sized
1 /// @file glm/ext/vector_int1_sized.hpp
2 ///
3 /// @defgroup ext_vector_int1_sized GLM_EXT_vector_int1_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized signed integer vector types.
7 ///
8 /// Include <glm/ext/vector_int1_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_int_sized
11 /// @see ext_vector_uint1_sized
12
13 #pragma once
14
15 #include "../ext/vector_int1.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_int1_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_int1_sized
25 /// @{
26
27 /// 8 bit signed integer vector of 1 component type.
28 ///
29 /// @see ext_vector_int1_sized
30 typedef vec<1, int8, defaultp> i8vec1;
31
32 /// 16 bit signed integer vector of 1 component type.
33 ///
34 /// @see ext_vector_int1_sized
35 typedef vec<1, int16, defaultp> i16vec1;
36
37 /// 32 bit signed integer vector of 1 component type.
38 ///
39 /// @see ext_vector_int1_sized
40 typedef vec<1, int32, defaultp> i32vec1;
41
42 /// 64 bit signed integer vector of 1 component type.
43 ///
44 /// @see ext_vector_int1_sized
45 typedef vec<1, int64, defaultp> i64vec1;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_int2_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_int2_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec2.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 2 components vector of high qualifier signed integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<2, int, highp> highp_ivec2;
16
17 /// 2 components vector of medium qualifier signed integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<2, int, mediump> mediump_ivec2;
22
23 /// 2 components vector of low qualifier signed integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<2, int, lowp> lowp_ivec2;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_int2_sized
1 /// @file glm/ext/vector_int2_sized.hpp
2 ///
3 /// @defgroup ext_vector_int2_sized GLM_EXT_vector_int2_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized signed integer vector of 2 components type.
7 ///
8 /// Include <glm/ext/vector_int2_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_int_sized
11 /// @see ext_vector_uint2_sized
12
13 #pragma once
14
15 #include "../ext/vector_int2.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_int2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_int2_sized
25 /// @{
26
27 /// 8 bit signed integer vector of 2 components type.
28 ///
29 /// @see ext_vector_int2_sized
30 typedef vec<2, int8, defaultp> i8vec2;
31
32 /// 16 bit signed integer vector of 2 components type.
33 ///
34 /// @see ext_vector_int2_sized
35 typedef vec<2, int16, defaultp> i16vec2;
36
37 /// 32 bit signed integer vector of 2 components type.
38 ///
39 /// @see ext_vector_int2_sized
40 typedef vec<2, int32, defaultp> i32vec2;
41
42 /// 64 bit signed integer vector of 2 components type.
43 ///
44 /// @see ext_vector_int2_sized
45 typedef vec<2, int64, defaultp> i64vec2;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_int3_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_int3_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec3.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 3 components vector of high qualifier signed integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<3, int, highp> highp_ivec3;
16
17 /// 3 components vector of medium qualifier signed integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<3, int, mediump> mediump_ivec3;
22
23 /// 3 components vector of low qualifier signed integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<3, int, lowp> lowp_ivec3;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_int3_sized
1 /// @file glm/ext/vector_int3_sized.hpp
2 ///
3 /// @defgroup ext_vector_int3_sized GLM_EXT_vector_int3_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized signed integer vector of 3 components type.
7 ///
8 /// Include <glm/ext/vector_int3_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_int_sized
11 /// @see ext_vector_uint3_sized
12
13 #pragma once
14
15 #include "../ext/vector_int3.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_int3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_int3_sized
25 /// @{
26
27 /// 8 bit signed integer vector of 3 components type.
28 ///
29 /// @see ext_vector_int3_sized
30 typedef vec<3, int8, defaultp> i8vec3;
31
32 /// 16 bit signed integer vector of 3 components type.
33 ///
34 /// @see ext_vector_int3_sized
35 typedef vec<3, int16, defaultp> i16vec3;
36
37 /// 32 bit signed integer vector of 3 components type.
38 ///
39 /// @see ext_vector_int3_sized
40 typedef vec<3, int32, defaultp> i32vec3;
41
42 /// 64 bit signed integer vector of 3 components type.
43 ///
44 /// @see ext_vector_int3_sized
45 typedef vec<3, int64, defaultp> i64vec3;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_int4_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_int4_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec4.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 4 components vector of high qualifier signed integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<4, int, highp> highp_ivec4;
16
17 /// 4 components vector of medium qualifier signed integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<4, int, mediump> mediump_ivec4;
22
23 /// 4 components vector of low qualifier signed integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<4, int, lowp> lowp_ivec4;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_int4_sized
1 /// @file glm/ext/vector_int4_sized.hpp
2 ///
3 /// @defgroup ext_vector_int4_sized GLM_EXT_vector_int4_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized signed integer vector of 4 components type.
7 ///
8 /// Include <glm/ext/vector_int4_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_int_sized
11 /// @see ext_vector_uint4_sized
12
13 #pragma once
14
15 #include "../ext/vector_int4.hpp"
16 #include "../ext/scalar_int_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_int4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_int4_sized
25 /// @{
26
27 /// 8 bit signed integer vector of 4 components type.
28 ///
29 /// @see ext_vector_int4_sized
30 typedef vec<4, int8, defaultp> i8vec4;
31
32 /// 16 bit signed integer vector of 4 components type.
33 ///
34 /// @see ext_vector_int4_sized
35 typedef vec<4, int16, defaultp> i16vec4;
36
37 /// 32 bit signed integer vector of 4 components type.
38 ///
39 /// @see ext_vector_int4_sized
40 typedef vec<4, int32, defaultp> i32vec4;
41
42 /// 64 bit signed integer vector of 4 components type.
43 ///
44 /// @see ext_vector_int4_sized
45 typedef vec<4, int64, defaultp> i64vec4;
46
47 /// @}
48 }//namespace glm
0 /// @ref ext_vector_packing
1 /// @file glm/ext/vector_packing.hpp
2 ///
3 /// @see core (dependence)
4 ///
5 /// @defgroup ext_vector_packing GLM_EXT_vector_packing
6 /// @ingroup ext
7 ///
8 /// Include <glm/ext/vector_packing.hpp> to use the features of this extension.
9 ///
10 /// This extension provides a set of function to convert vectors to packed
11 /// formats.
12
13 #pragma once
14
15 // Dependency:
16 #include "../detail/qualifier.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_packing extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_packing
25 /// @{
26
27
28 /// @}
29 }// namespace glm
30
31 #include "vector_packing.inl"
(New empty file)
+0
-40
glm/ext/vector_uint1_precision.hpp less more
0 /// @ref ext_vector_uint1_precision
1 /// @file glm/ext/vector_uint1_precision.hpp
2 ///
3 /// @defgroup ext_vector_uint1_precision GLM_EXT_vector_uint1_precision
4 /// @ingroup ext
5 ///
6 /// Exposes highp_uvec1, mediump_uvec1 and lowp_uvec1 types.
7 ///
8 /// Include <glm/ext/vector_uint1_precision.hpp> to use the features of this extension.
9
10 #pragma once
11
12 #include "../detail/type_vec1.hpp"
13
14 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
15 # pragma message("GLM: GLM_EXT_vector_uint1_precision extension included")
16 #endif
17
18 namespace glm
19 {
20 /// @addtogroup ext_vector_uint1_precision
21 /// @{
22
23 /// 1 component vector of unsigned integer values.
24 ///
25 /// @see ext_vector_uint1_precision
26 typedef vec<1, unsigned int, highp> highp_uvec1;
27
28 /// 1 component vector of unsigned integer values.
29 ///
30 /// @see ext_vector_uint1_precision
31 typedef vec<1, unsigned int, mediump> mediump_uvec1;
32
33 /// 1 component vector of unsigned integer values.
34 ///
35 /// @see ext_vector_uint1_precision
36 typedef vec<1, unsigned int, lowp> lowp_uvec1;
37
38 /// @}
39 }//namespace glm
0 /// @ref ext_vector_uint1_sized
1 /// @file glm/ext/vector_uint1_sized.hpp
2 ///
3 /// @defgroup ext_vector_uint1_sized GLM_EXT_vector_uint1_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized unsigned integer vector types.
7 ///
8 /// Include <glm/ext/vector_uint1_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_uint_sized
11 /// @see ext_vector_int1_sized
12
13 #pragma once
14
15 #include "../ext/vector_uint1.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_uint1_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_uint1_sized
25 /// @{
26
27 /// 8 bit unsigned integer vector of 1 component type.
28 ///
29 /// @see ext_vector_uint1_sized
30 typedef vec<1, uint8, defaultp> u8vec1;
31
32 /// 16 bit unsigned integer vector of 1 component type.
33 ///
34 /// @see ext_vector_uint1_sized
35 typedef vec<1, uint16, defaultp> u16vec1;
36
37 /// 32 bit unsigned integer vector of 1 component type.
38 ///
39 /// @see ext_vector_uint1_sized
40 typedef vec<1, uint32, defaultp> u32vec1;
41
42 /// 64 bit unsigned integer vector of 1 component type.
43 ///
44 /// @see ext_vector_uint1_sized
45 typedef vec<1, uint64, defaultp> u64vec1;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_uint2_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_uint2_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec2.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 2 components vector of high qualifier unsigned integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<2, unsigned int, highp> highp_uvec2;
16
17 /// 2 components vector of medium qualifier unsigned integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<2, unsigned int, mediump> mediump_uvec2;
22
23 /// 2 components vector of low qualifier unsigned integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<2, unsigned int, lowp> lowp_uvec2;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_uint2_sized
1 /// @file glm/ext/vector_uint2_sized.hpp
2 ///
3 /// @defgroup ext_vector_uint2_sized GLM_EXT_vector_uint2_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized unsigned integer vector of 2 components type.
7 ///
8 /// Include <glm/ext/vector_uint2_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_uint_sized
11 /// @see ext_vector_int2_sized
12
13 #pragma once
14
15 #include "../ext/vector_uint2.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_uint2_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_uint2_sized
25 /// @{
26
27 /// 8 bit unsigned integer vector of 2 components type.
28 ///
29 /// @see ext_vector_uint2_sized
30 typedef vec<2, uint8, defaultp> u8vec2;
31
32 /// 16 bit unsigned integer vector of 2 components type.
33 ///
34 /// @see ext_vector_uint2_sized
35 typedef vec<2, uint16, defaultp> u16vec2;
36
37 /// 32 bit unsigned integer vector of 2 components type.
38 ///
39 /// @see ext_vector_uint2_sized
40 typedef vec<2, uint32, defaultp> u32vec2;
41
42 /// 64 bit unsigned integer vector of 2 components type.
43 ///
44 /// @see ext_vector_uint2_sized
45 typedef vec<2, uint64, defaultp> u64vec2;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_uint3_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_uint3_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec3.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 3 components vector of high qualifier unsigned integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<3, unsigned int, highp> highp_uvec3;
16
17 /// 3 components vector of medium qualifier unsigned integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<3, unsigned int, mediump> mediump_uvec3;
22
23 /// 3 components vector of low qualifier unsigned integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<3, unsigned int, lowp> lowp_uvec3;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_uint3_sized
1 /// @file glm/ext/vector_uint3_sized.hpp
2 ///
3 /// @defgroup ext_vector_uint3_sized GLM_EXT_vector_uint3_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized unsigned integer vector of 3 components type.
7 ///
8 /// Include <glm/ext/vector_uint3_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_uint_sized
11 /// @see ext_vector_int3_sized
12
13 #pragma once
14
15 #include "../ext/vector_uint3.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_uint3_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_uint3_sized
25 /// @{
26
27 /// 8 bit unsigned integer vector of 3 components type.
28 ///
29 /// @see ext_vector_uint3_sized
30 typedef vec<3, uint8, defaultp> u8vec3;
31
32 /// 16 bit unsigned integer vector of 3 components type.
33 ///
34 /// @see ext_vector_uint3_sized
35 typedef vec<3, uint16, defaultp> u16vec3;
36
37 /// 32 bit unsigned integer vector of 3 components type.
38 ///
39 /// @see ext_vector_uint3_sized
40 typedef vec<3, uint32, defaultp> u32vec3;
41
42 /// 64 bit unsigned integer vector of 3 components type.
43 ///
44 /// @see ext_vector_uint3_sized
45 typedef vec<3, uint64, defaultp> u64vec3;
46
47 /// @}
48 }//namespace glm
+0
-31
glm/ext/vector_uint4_precision.hpp less more
0 /// @ref core
1 /// @file glm/ext/vector_uint4_precision.hpp
2
3 #pragma once
4 #include "../detail/type_vec4.hpp"
5
6 namespace glm
7 {
8 /// @addtogroup core_vector_precision
9 /// @{
10
11 /// 4 components vector of high qualifier unsigned integer numbers.
12 ///
13 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
14 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
15 typedef vec<4, unsigned int, highp> highp_uvec4;
16
17 /// 4 components vector of medium qualifier unsigned integer numbers.
18 ///
19 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
20 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
21 typedef vec<4, unsigned int, mediump> mediump_uvec4;
22
23 /// 4 components vector of low qualifier unsigned integer numbers.
24 ///
25 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
26 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
27 typedef vec<4, unsigned int, lowp> lowp_uvec4;
28
29 /// @}
30 }//namespace glm
0 /// @ref ext_vector_uint4_sized
1 /// @file glm/ext/vector_uint4_sized.hpp
2 ///
3 /// @defgroup ext_vector_uint4_sized GLM_EXT_vector_uint4_sized
4 /// @ingroup ext
5 ///
6 /// Exposes sized unsigned integer vector of 4 components type.
7 ///
8 /// Include <glm/ext/vector_uint4_sized.hpp> to use the features of this extension.
9 ///
10 /// @see ext_scalar_uint_sized
11 /// @see ext_vector_int4_sized
12
13 #pragma once
14
15 #include "../ext/vector_uint4.hpp"
16 #include "../ext/scalar_uint_sized.hpp"
17
18 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
19 # pragma message("GLM: GLM_EXT_vector_uint4_sized extension included")
20 #endif
21
22 namespace glm
23 {
24 /// @addtogroup ext_vector_uint4_sized
25 /// @{
26
27 /// 8 bit unsigned integer vector of 4 components type.
28 ///
29 /// @see ext_vector_uint4_sized
30 typedef vec<4, uint8, defaultp> u8vec4;
31
32 /// 16 bit unsigned integer vector of 4 components type.
33 ///
34 /// @see ext_vector_uint4_sized
35 typedef vec<4, uint16, defaultp> u16vec4;
36
37 /// 32 bit unsigned integer vector of 4 components type.
38 ///
39 /// @see ext_vector_uint4_sized
40 typedef vec<4, uint32, defaultp> u32vec4;
41
42 /// 64 bit unsigned integer vector of 4 components type.
43 ///
44 /// @see ext_vector_uint4_sized
45 typedef vec<4, uint64, defaultp> u64vec4;
46
47 /// @}
48 }//namespace glm
1111 # define GLM_MESSAGE_EXT_INCLUDED_DISPLAYED
1212 # pragma message("GLM: All extensions included (not recommended)")
1313 #endif//GLM_MESSAGES
14
15 #include "./ext/matrix_clip_space.hpp"
16 #include "./ext/matrix_common.hpp"
1417
1518 #include "./ext/matrix_double2x2.hpp"
1619 #include "./ext/matrix_double2x2_precision.hpp"
5053 #include "./ext/matrix_float4x4.hpp"
5154 #include "./ext/matrix_float4x4_precision.hpp"
5255
56 #include "./ext/matrix_int2x2.hpp"
57 #include "./ext/matrix_int2x2_sized.hpp"
58 #include "./ext/matrix_int2x3.hpp"
59 #include "./ext/matrix_int2x3_sized.hpp"
60 #include "./ext/matrix_int2x4.hpp"
61 #include "./ext/matrix_int2x4_sized.hpp"
62 #include "./ext/matrix_int3x2.hpp"
63 #include "./ext/matrix_int3x2_sized.hpp"
64 #include "./ext/matrix_int3x3.hpp"
65 #include "./ext/matrix_int3x3_sized.hpp"
66 #include "./ext/matrix_int3x4.hpp"
67 #include "./ext/matrix_int3x4_sized.hpp"
68 #include "./ext/matrix_int4x2.hpp"
69 #include "./ext/matrix_int4x2_sized.hpp"
70 #include "./ext/matrix_int4x3.hpp"
71 #include "./ext/matrix_int4x3_sized.hpp"
72 #include "./ext/matrix_int4x4.hpp"
73 #include "./ext/matrix_int4x4_sized.hpp"
74
75 #include "./ext/matrix_uint2x2.hpp"
76 #include "./ext/matrix_uint2x2_sized.hpp"
77 #include "./ext/matrix_uint2x3.hpp"
78 #include "./ext/matrix_uint2x3_sized.hpp"
79 #include "./ext/matrix_uint2x4.hpp"
80 #include "./ext/matrix_uint2x4_sized.hpp"
81 #include "./ext/matrix_uint3x2.hpp"
82 #include "./ext/matrix_uint3x2_sized.hpp"
83 #include "./ext/matrix_uint3x3.hpp"
84 #include "./ext/matrix_uint3x3_sized.hpp"
85 #include "./ext/matrix_uint3x4.hpp"
86 #include "./ext/matrix_uint3x4_sized.hpp"
87 #include "./ext/matrix_uint4x2.hpp"
88 #include "./ext/matrix_uint4x2_sized.hpp"
89 #include "./ext/matrix_uint4x3.hpp"
90 #include "./ext/matrix_uint4x3_sized.hpp"
91 #include "./ext/matrix_uint4x4.hpp"
92 #include "./ext/matrix_uint4x4_sized.hpp"
93
94 #include "./ext/matrix_projection.hpp"
5395 #include "./ext/matrix_relational.hpp"
54
96 #include "./ext/matrix_transform.hpp"
97
98 #include "./ext/quaternion_common.hpp"
5599 #include "./ext/quaternion_double.hpp"
56100 #include "./ext/quaternion_double_precision.hpp"
57101 #include "./ext/quaternion_float.hpp"
58102 #include "./ext/quaternion_float_precision.hpp"
103 #include "./ext/quaternion_exponential.hpp"
59104 #include "./ext/quaternion_geometric.hpp"
60105 #include "./ext/quaternion_relational.hpp"
61
106 #include "./ext/quaternion_transform.hpp"
107 #include "./ext/quaternion_trigonometric.hpp"
108
109 #include "./ext/scalar_common.hpp"
62110 #include "./ext/scalar_constants.hpp"
111 #include "./ext/scalar_integer.hpp"
112 #include "./ext/scalar_packing.hpp"
113 #include "./ext/scalar_relational.hpp"
114 #include "./ext/scalar_ulp.hpp"
115
63116 #include "./ext/scalar_int_sized.hpp"
64 #include "./ext/scalar_relational.hpp"
117 #include "./ext/scalar_uint_sized.hpp"
118
119 #include "./ext/vector_common.hpp"
120 #include "./ext/vector_integer.hpp"
121 #include "./ext/vector_packing.hpp"
122 #include "./ext/vector_relational.hpp"
123 #include "./ext/vector_ulp.hpp"
65124
66125 #include "./ext/vector_bool1.hpp"
67126 #include "./ext/vector_bool1_precision.hpp"
91150 #include "./ext/vector_float4_precision.hpp"
92151
93152 #include "./ext/vector_int1.hpp"
94 #include "./ext/vector_int1_precision.hpp"
153 #include "./ext/vector_int1_sized.hpp"
95154 #include "./ext/vector_int2.hpp"
96 #include "./ext/vector_int2_precision.hpp"
155 #include "./ext/vector_int2_sized.hpp"
97156 #include "./ext/vector_int3.hpp"
98 #include "./ext/vector_int3_precision.hpp"
157 #include "./ext/vector_int3_sized.hpp"
99158 #include "./ext/vector_int4.hpp"
100 #include "./ext/vector_int4_precision.hpp"
101
102 #include "./ext/vector_relational.hpp"
159 #include "./ext/vector_int4_sized.hpp"
103160
104161 #include "./ext/vector_uint1.hpp"
105 #include "./ext/vector_uint1_precision.hpp"
162 #include "./ext/vector_uint1_sized.hpp"
106163 #include "./ext/vector_uint2.hpp"
107 #include "./ext/vector_uint2_precision.hpp"
164 #include "./ext/vector_uint2_sized.hpp"
108165 #include "./ext/vector_uint3.hpp"
109 #include "./ext/vector_uint3_precision.hpp"
166 #include "./ext/vector_uint3_sized.hpp"
110167 #include "./ext/vector_uint4.hpp"
111 #include "./ext/vector_uint4_precision.hpp"
168 #include "./ext/vector_uint4_sized.hpp"
112169
113170 #include "./gtc/bitfield.hpp"
114171 #include "./gtc/color_space.hpp"
8585
8686 // Scalar uint
8787
88 typedef unsigned int uint;
89
8890 typedef uint8 lowp_u8;
8991 typedef uint8 mediump_u8;
9092 typedef uint8 highp_u8;
198200
199201 // Vector int
200202
201 typedef vec<1, i32, lowp> lowp_ivec1;
202 typedef vec<2, i32, lowp> lowp_ivec2;
203 typedef vec<3, i32, lowp> lowp_ivec3;
204 typedef vec<4, i32, lowp> lowp_ivec4;
205
206 typedef vec<1, i32, mediump> mediump_ivec1;
207 typedef vec<2, i32, mediump> mediump_ivec2;
208 typedef vec<3, i32, mediump> mediump_ivec3;
209 typedef vec<4, i32, mediump> mediump_ivec4;
210
211 typedef vec<1, i32, highp> highp_ivec1;
212 typedef vec<2, i32, highp> highp_ivec2;
213 typedef vec<3, i32, highp> highp_ivec3;
214 typedef vec<4, i32, highp> highp_ivec4;
215
216 typedef vec<1, i32, defaultp> ivec1;
217 typedef vec<2, i32, defaultp> ivec2;
218 typedef vec<3, i32, defaultp> ivec3;
219 typedef vec<4, i32, defaultp> ivec4;
203 typedef vec<1, int, lowp> lowp_ivec1;
204 typedef vec<2, int, lowp> lowp_ivec2;
205 typedef vec<3, int, lowp> lowp_ivec3;
206 typedef vec<4, int, lowp> lowp_ivec4;
207
208 typedef vec<1, int, mediump> mediump_ivec1;
209 typedef vec<2, int, mediump> mediump_ivec2;
210 typedef vec<3, int, mediump> mediump_ivec3;
211 typedef vec<4, int, mediump> mediump_ivec4;
212
213 typedef vec<1, int, highp> highp_ivec1;
214 typedef vec<2, int, highp> highp_ivec2;
215 typedef vec<3, int, highp> highp_ivec3;
216 typedef vec<4, int, highp> highp_ivec4;
217
218 typedef vec<1, int, defaultp> ivec1;
219 typedef vec<2, int, defaultp> ivec2;
220 typedef vec<3, int, defaultp> ivec3;
221 typedef vec<4, int, defaultp> ivec4;
220222
221223 typedef vec<1, i8, lowp> lowp_i8vec1;
222224 typedef vec<2, i8, lowp> lowp_i8vec2;
300302
301303 // Vector uint
302304
303 typedef vec<1, u32, lowp> lowp_uvec1;
304 typedef vec<2, u32, lowp> lowp_uvec2;
305 typedef vec<3, u32, lowp> lowp_uvec3;
306 typedef vec<4, u32, lowp> lowp_uvec4;
307
308 typedef vec<1, u32, mediump> mediump_uvec1;
309 typedef vec<2, u32, mediump> mediump_uvec2;
310 typedef vec<3, u32, mediump> mediump_uvec3;
311 typedef vec<4, u32, mediump> mediump_uvec4;
312
313 typedef vec<1, u32, highp> highp_uvec1;
314 typedef vec<2, u32, highp> highp_uvec2;
315 typedef vec<3, u32, highp> highp_uvec3;
316 typedef vec<4, u32, highp> highp_uvec4;
317
318 typedef vec<1, u32, defaultp> uvec1;
319 typedef vec<2, u32, defaultp> uvec2;
320 typedef vec<3, u32, defaultp> uvec3;
321 typedef vec<4, u32, defaultp> uvec4;
305 typedef vec<1, uint, lowp> lowp_uvec1;
306 typedef vec<2, uint, lowp> lowp_uvec2;
307 typedef vec<3, uint, lowp> lowp_uvec3;
308 typedef vec<4, uint, lowp> lowp_uvec4;
309
310 typedef vec<1, uint, mediump> mediump_uvec1;
311 typedef vec<2, uint, mediump> mediump_uvec2;
312 typedef vec<3, uint, mediump> mediump_uvec3;
313 typedef vec<4, uint, mediump> mediump_uvec4;
314
315 typedef vec<1, uint, highp> highp_uvec1;
316 typedef vec<2, uint, highp> highp_uvec2;
317 typedef vec<3, uint, highp> highp_uvec3;
318 typedef vec<4, uint, highp> highp_uvec4;
319
320 typedef vec<1, uint, defaultp> uvec1;
321 typedef vec<2, uint, defaultp> uvec2;
322 typedef vec<3, uint, defaultp> uvec3;
323 typedef vec<4, uint, defaultp> uvec4;
322324
323325 typedef vec<1, u8, lowp> lowp_u8vec1;
324326 typedef vec<2, u8, lowp> lowp_u8vec2;
786788 typedef mat<3, 4, f64, defaultp> f64mat3x4;
787789 typedef mat<4, 4, f64, defaultp> f64mat4x4;
788790
791 // Signed integer matrix MxN
792
793 typedef mat<2, 2, int, lowp> lowp_imat2x2;
794 typedef mat<2, 3, int, lowp> lowp_imat2x3;
795 typedef mat<2, 4, int, lowp> lowp_imat2x4;
796 typedef mat<3, 2, int, lowp> lowp_imat3x2;
797 typedef mat<3, 3, int, lowp> lowp_imat3x3;
798 typedef mat<3, 4, int, lowp> lowp_imat3x4;
799 typedef mat<4, 2, int, lowp> lowp_imat4x2;
800 typedef mat<4, 3, int, lowp> lowp_imat4x3;
801 typedef mat<4, 4, int, lowp> lowp_imat4x4;
802
803 typedef mat<2, 2, int, mediump> mediump_imat2x2;
804 typedef mat<2, 3, int, mediump> mediump_imat2x3;
805 typedef mat<2, 4, int, mediump> mediump_imat2x4;
806 typedef mat<3, 2, int, mediump> mediump_imat3x2;
807 typedef mat<3, 3, int, mediump> mediump_imat3x3;
808 typedef mat<3, 4, int, mediump> mediump_imat3x4;
809 typedef mat<4, 2, int, mediump> mediump_imat4x2;
810 typedef mat<4, 3, int, mediump> mediump_imat4x3;
811 typedef mat<4, 4, int, mediump> mediump_imat4x4;
812
813 typedef mat<2, 2, int, highp> highp_imat2x2;
814 typedef mat<2, 3, int, highp> highp_imat2x3;
815 typedef mat<2, 4, int, highp> highp_imat2x4;
816 typedef mat<3, 2, int, highp> highp_imat3x2;
817 typedef mat<3, 3, int, highp> highp_imat3x3;
818 typedef mat<3, 4, int, highp> highp_imat3x4;
819 typedef mat<4, 2, int, highp> highp_imat4x2;
820 typedef mat<4, 3, int, highp> highp_imat4x3;
821 typedef mat<4, 4, int, highp> highp_imat4x4;
822
823 typedef mat<2, 2, int, defaultp> imat2x2;
824 typedef mat<3, 2, int, defaultp> imat3x2;
825 typedef mat<4, 2, int, defaultp> imat4x2;
826 typedef mat<2, 3, int, defaultp> imat2x3;
827 typedef mat<3, 3, int, defaultp> imat3x3;
828 typedef mat<4, 3, int, defaultp> imat4x3;
829 typedef mat<2, 4, int, defaultp> imat2x4;
830 typedef mat<3, 4, int, defaultp> imat3x4;
831 typedef mat<4, 4, int, defaultp> imat4x4;
832
833
834 typedef mat<2, 2, int8, lowp> lowp_i8mat2x2;
835 typedef mat<2, 3, int8, lowp> lowp_i8mat2x3;
836 typedef mat<2, 4, int8, lowp> lowp_i8mat2x4;
837 typedef mat<3, 2, int8, lowp> lowp_i8mat3x2;
838 typedef mat<3, 3, int8, lowp> lowp_i8mat3x3;
839 typedef mat<3, 4, int8, lowp> lowp_i8mat3x4;
840 typedef mat<4, 2, int8, lowp> lowp_i8mat4x2;
841 typedef mat<4, 3, int8, lowp> lowp_i8mat4x3;
842 typedef mat<4, 4, int8, lowp> lowp_i8mat4x4;
843
844 typedef mat<2, 2, int8, mediump> mediump_i8mat2x2;
845 typedef mat<2, 3, int8, mediump> mediump_i8mat2x3;
846 typedef mat<2, 4, int8, mediump> mediump_i8mat2x4;
847 typedef mat<3, 2, int8, mediump> mediump_i8mat3x2;
848 typedef mat<3, 3, int8, mediump> mediump_i8mat3x3;
849 typedef mat<3, 4, int8, mediump> mediump_i8mat3x4;
850 typedef mat<4, 2, int8, mediump> mediump_i8mat4x2;
851 typedef mat<4, 3, int8, mediump> mediump_i8mat4x3;
852 typedef mat<4, 4, int8, mediump> mediump_i8mat4x4;
853
854 typedef mat<2, 2, int8, highp> highp_i8mat2x2;
855 typedef mat<2, 3, int8, highp> highp_i8mat2x3;
856 typedef mat<2, 4, int8, highp> highp_i8mat2x4;
857 typedef mat<3, 2, int8, highp> highp_i8mat3x2;
858 typedef mat<3, 3, int8, highp> highp_i8mat3x3;
859 typedef mat<3, 4, int8, highp> highp_i8mat3x4;
860 typedef mat<4, 2, int8, highp> highp_i8mat4x2;
861 typedef mat<4, 3, int8, highp> highp_i8mat4x3;
862 typedef mat<4, 4, int8, highp> highp_i8mat4x4;
863
864 typedef mat<2, 2, int8, defaultp> i8mat2x2;
865 typedef mat<3, 2, int8, defaultp> i8mat3x2;
866 typedef mat<4, 2, int8, defaultp> i8mat4x2;
867 typedef mat<2, 3, int8, defaultp> i8mat2x3;
868 typedef mat<3, 3, int8, defaultp> i8mat3x3;
869 typedef mat<4, 3, int8, defaultp> i8mat4x3;
870 typedef mat<2, 4, int8, defaultp> i8mat2x4;
871 typedef mat<3, 4, int8, defaultp> i8mat3x4;
872 typedef mat<4, 4, int8, defaultp> i8mat4x4;
873
874
875 typedef mat<2, 2, int16, lowp> lowp_i16mat2x2;
876 typedef mat<2, 3, int16, lowp> lowp_i16mat2x3;
877 typedef mat<2, 4, int16, lowp> lowp_i16mat2x4;
878 typedef mat<3, 2, int16, lowp> lowp_i16mat3x2;
879 typedef mat<3, 3, int16, lowp> lowp_i16mat3x3;
880 typedef mat<3, 4, int16, lowp> lowp_i16mat3x4;
881 typedef mat<4, 2, int16, lowp> lowp_i16mat4x2;
882 typedef mat<4, 3, int16, lowp> lowp_i16mat4x3;
883 typedef mat<4, 4, int16, lowp> lowp_i16mat4x4;
884
885 typedef mat<2, 2, int16, mediump> mediump_i16mat2x2;
886 typedef mat<2, 3, int16, mediump> mediump_i16mat2x3;
887 typedef mat<2, 4, int16, mediump> mediump_i16mat2x4;
888 typedef mat<3, 2, int16, mediump> mediump_i16mat3x2;
889 typedef mat<3, 3, int16, mediump> mediump_i16mat3x3;
890 typedef mat<3, 4, int16, mediump> mediump_i16mat3x4;
891 typedef mat<4, 2, int16, mediump> mediump_i16mat4x2;
892 typedef mat<4, 3, int16, mediump> mediump_i16mat4x3;
893 typedef mat<4, 4, int16, mediump> mediump_i16mat4x4;
894
895 typedef mat<2, 2, int16, highp> highp_i16mat2x2;
896 typedef mat<2, 3, int16, highp> highp_i16mat2x3;
897 typedef mat<2, 4, int16, highp> highp_i16mat2x4;
898 typedef mat<3, 2, int16, highp> highp_i16mat3x2;
899 typedef mat<3, 3, int16, highp> highp_i16mat3x3;
900 typedef mat<3, 4, int16, highp> highp_i16mat3x4;
901 typedef mat<4, 2, int16, highp> highp_i16mat4x2;
902 typedef mat<4, 3, int16, highp> highp_i16mat4x3;
903 typedef mat<4, 4, int16, highp> highp_i16mat4x4;
904
905 typedef mat<2, 2, int16, defaultp> i16mat2x2;
906 typedef mat<3, 2, int16, defaultp> i16mat3x2;
907 typedef mat<4, 2, int16, defaultp> i16mat4x2;
908 typedef mat<2, 3, int16, defaultp> i16mat2x3;
909 typedef mat<3, 3, int16, defaultp> i16mat3x3;
910 typedef mat<4, 3, int16, defaultp> i16mat4x3;
911 typedef mat<2, 4, int16, defaultp> i16mat2x4;
912 typedef mat<3, 4, int16, defaultp> i16mat3x4;
913 typedef mat<4, 4, int16, defaultp> i16mat4x4;
914
915
916 typedef mat<2, 2, int32, lowp> lowp_i32mat2x2;
917 typedef mat<2, 3, int32, lowp> lowp_i32mat2x3;
918 typedef mat<2, 4, int32, lowp> lowp_i32mat2x4;
919 typedef mat<3, 2, int32, lowp> lowp_i32mat3x2;
920 typedef mat<3, 3, int32, lowp> lowp_i32mat3x3;
921 typedef mat<3, 4, int32, lowp> lowp_i32mat3x4;
922 typedef mat<4, 2, int32, lowp> lowp_i32mat4x2;
923 typedef mat<4, 3, int32, lowp> lowp_i32mat4x3;
924 typedef mat<4, 4, int32, lowp> lowp_i32mat4x4;
925
926 typedef mat<2, 2, int32, mediump> mediump_i32mat2x2;
927 typedef mat<2, 3, int32, mediump> mediump_i32mat2x3;
928 typedef mat<2, 4, int32, mediump> mediump_i32mat2x4;
929 typedef mat<3, 2, int32, mediump> mediump_i32mat3x2;
930 typedef mat<3, 3, int32, mediump> mediump_i32mat3x3;
931 typedef mat<3, 4, int32, mediump> mediump_i32mat3x4;
932 typedef mat<4, 2, int32, mediump> mediump_i32mat4x2;
933 typedef mat<4, 3, int32, mediump> mediump_i32mat4x3;
934 typedef mat<4, 4, int32, mediump> mediump_i32mat4x4;
935
936 typedef mat<2, 2, int32, highp> highp_i32mat2x2;
937 typedef mat<2, 3, int32, highp> highp_i32mat2x3;
938 typedef mat<2, 4, int32, highp> highp_i32mat2x4;
939 typedef mat<3, 2, int32, highp> highp_i32mat3x2;
940 typedef mat<3, 3, int32, highp> highp_i32mat3x3;
941 typedef mat<3, 4, int32, highp> highp_i32mat3x4;
942 typedef mat<4, 2, int32, highp> highp_i32mat4x2;
943 typedef mat<4, 3, int32, highp> highp_i32mat4x3;
944 typedef mat<4, 4, int32, highp> highp_i32mat4x4;
945
946 typedef mat<2, 2, int32, defaultp> i32mat2x2;
947 typedef mat<3, 2, int32, defaultp> i32mat3x2;
948 typedef mat<4, 2, int32, defaultp> i32mat4x2;
949 typedef mat<2, 3, int32, defaultp> i32mat2x3;
950 typedef mat<3, 3, int32, defaultp> i32mat3x3;
951 typedef mat<4, 3, int32, defaultp> i32mat4x3;
952 typedef mat<2, 4, int32, defaultp> i32mat2x4;
953 typedef mat<3, 4, int32, defaultp> i32mat3x4;
954 typedef mat<4, 4, int32, defaultp> i32mat4x4;
955
956
957 typedef mat<2, 2, int64, lowp> lowp_i64mat2x2;
958 typedef mat<2, 3, int64, lowp> lowp_i64mat2x3;
959 typedef mat<2, 4, int64, lowp> lowp_i64mat2x4;
960 typedef mat<3, 2, int64, lowp> lowp_i64mat3x2;
961 typedef mat<3, 3, int64, lowp> lowp_i64mat3x3;
962 typedef mat<3, 4, int64, lowp> lowp_i64mat3x4;
963 typedef mat<4, 2, int64, lowp> lowp_i64mat4x2;
964 typedef mat<4, 3, int64, lowp> lowp_i64mat4x3;
965 typedef mat<4, 4, int64, lowp> lowp_i64mat4x4;
966
967 typedef mat<2, 2, int64, mediump> mediump_i64mat2x2;
968 typedef mat<2, 3, int64, mediump> mediump_i64mat2x3;
969 typedef mat<2, 4, int64, mediump> mediump_i64mat2x4;
970 typedef mat<3, 2, int64, mediump> mediump_i64mat3x2;
971 typedef mat<3, 3, int64, mediump> mediump_i64mat3x3;
972 typedef mat<3, 4, int64, mediump> mediump_i64mat3x4;
973 typedef mat<4, 2, int64, mediump> mediump_i64mat4x2;
974 typedef mat<4, 3, int64, mediump> mediump_i64mat4x3;
975 typedef mat<4, 4, int64, mediump> mediump_i64mat4x4;
976
977 typedef mat<2, 2, int64, highp> highp_i64mat2x2;
978 typedef mat<2, 3, int64, highp> highp_i64mat2x3;
979 typedef mat<2, 4, int64, highp> highp_i64mat2x4;
980 typedef mat<3, 2, int64, highp> highp_i64mat3x2;
981 typedef mat<3, 3, int64, highp> highp_i64mat3x3;
982 typedef mat<3, 4, int64, highp> highp_i64mat3x4;
983 typedef mat<4, 2, int64, highp> highp_i64mat4x2;
984 typedef mat<4, 3, int64, highp> highp_i64mat4x3;
985 typedef mat<4, 4, int64, highp> highp_i64mat4x4;
986
987 typedef mat<2, 2, int64, defaultp> i64mat2x2;
988 typedef mat<3, 2, int64, defaultp> i64mat3x2;
989 typedef mat<4, 2, int64, defaultp> i64mat4x2;
990 typedef mat<2, 3, int64, defaultp> i64mat2x3;
991 typedef mat<3, 3, int64, defaultp> i64mat3x3;
992 typedef mat<4, 3, int64, defaultp> i64mat4x3;
993 typedef mat<2, 4, int64, defaultp> i64mat2x4;
994 typedef mat<3, 4, int64, defaultp> i64mat3x4;
995 typedef mat<4, 4, int64, defaultp> i64mat4x4;
996
997
998 // Unsigned integer matrix MxN
999
1000 typedef mat<2, 2, uint, lowp> lowp_umat2x2;
1001 typedef mat<2, 3, uint, lowp> lowp_umat2x3;
1002 typedef mat<2, 4, uint, lowp> lowp_umat2x4;
1003 typedef mat<3, 2, uint, lowp> lowp_umat3x2;
1004 typedef mat<3, 3, uint, lowp> lowp_umat3x3;
1005 typedef mat<3, 4, uint, lowp> lowp_umat3x4;
1006 typedef mat<4, 2, uint, lowp> lowp_umat4x2;
1007 typedef mat<4, 3, uint, lowp> lowp_umat4x3;
1008 typedef mat<4, 4, uint, lowp> lowp_umat4x4;
1009
1010 typedef mat<2, 2, uint, mediump> mediump_umat2x2;
1011 typedef mat<2, 3, uint, mediump> mediump_umat2x3;
1012 typedef mat<2, 4, uint, mediump> mediump_umat2x4;
1013 typedef mat<3, 2, uint, mediump> mediump_umat3x2;
1014 typedef mat<3, 3, uint, mediump> mediump_umat3x3;
1015 typedef mat<3, 4, uint, mediump> mediump_umat3x4;
1016 typedef mat<4, 2, uint, mediump> mediump_umat4x2;
1017 typedef mat<4, 3, uint, mediump> mediump_umat4x3;
1018 typedef mat<4, 4, uint, mediump> mediump_umat4x4;
1019
1020 typedef mat<2, 2, uint, highp> highp_umat2x2;
1021 typedef mat<2, 3, uint, highp> highp_umat2x3;
1022 typedef mat<2, 4, uint, highp> highp_umat2x4;
1023 typedef mat<3, 2, uint, highp> highp_umat3x2;
1024 typedef mat<3, 3, uint, highp> highp_umat3x3;
1025 typedef mat<3, 4, uint, highp> highp_umat3x4;
1026 typedef mat<4, 2, uint, highp> highp_umat4x2;
1027 typedef mat<4, 3, uint, highp> highp_umat4x3;
1028 typedef mat<4, 4, uint, highp> highp_umat4x4;
1029
1030 typedef mat<2, 2, uint, defaultp> umat2x2;
1031 typedef mat<3, 2, uint, defaultp> umat3x2;
1032 typedef mat<4, 2, uint, defaultp> umat4x2;
1033 typedef mat<2, 3, uint, defaultp> umat2x3;
1034 typedef mat<3, 3, uint, defaultp> umat3x3;
1035 typedef mat<4, 3, uint, defaultp> umat4x3;
1036 typedef mat<2, 4, uint, defaultp> umat2x4;
1037 typedef mat<3, 4, uint, defaultp> umat3x4;
1038 typedef mat<4, 4, uint, defaultp> umat4x4;
1039
1040
1041 typedef mat<2, 2, uint8, lowp> lowp_u8mat2x2;
1042 typedef mat<2, 3, uint8, lowp> lowp_u8mat2x3;
1043 typedef mat<2, 4, uint8, lowp> lowp_u8mat2x4;
1044 typedef mat<3, 2, uint8, lowp> lowp_u8mat3x2;
1045 typedef mat<3, 3, uint8, lowp> lowp_u8mat3x3;
1046 typedef mat<3, 4, uint8, lowp> lowp_u8mat3x4;
1047 typedef mat<4, 2, uint8, lowp> lowp_u8mat4x2;
1048 typedef mat<4, 3, uint8, lowp> lowp_u8mat4x3;
1049 typedef mat<4, 4, uint8, lowp> lowp_u8mat4x4;
1050
1051 typedef mat<2, 2, uint8, mediump> mediump_u8mat2x2;
1052 typedef mat<2, 3, uint8, mediump> mediump_u8mat2x3;
1053 typedef mat<2, 4, uint8, mediump> mediump_u8mat2x4;
1054 typedef mat<3, 2, uint8, mediump> mediump_u8mat3x2;
1055 typedef mat<3, 3, uint8, mediump> mediump_u8mat3x3;
1056 typedef mat<3, 4, uint8, mediump> mediump_u8mat3x4;
1057 typedef mat<4, 2, uint8, mediump> mediump_u8mat4x2;
1058 typedef mat<4, 3, uint8, mediump> mediump_u8mat4x3;
1059 typedef mat<4, 4, uint8, mediump> mediump_u8mat4x4;
1060
1061 typedef mat<2, 2, uint8, highp> highp_u8mat2x2;
1062 typedef mat<2, 3, uint8, highp> highp_u8mat2x3;
1063 typedef mat<2, 4, uint8, highp> highp_u8mat2x4;
1064 typedef mat<3, 2, uint8, highp> highp_u8mat3x2;
1065 typedef mat<3, 3, uint8, highp> highp_u8mat3x3;
1066 typedef mat<3, 4, uint8, highp> highp_u8mat3x4;
1067 typedef mat<4, 2, uint8, highp> highp_u8mat4x2;
1068 typedef mat<4, 3, uint8, highp> highp_u8mat4x3;
1069 typedef mat<4, 4, uint8, highp> highp_u8mat4x4;
1070
1071 typedef mat<2, 2, uint8, defaultp> u8mat2x2;
1072 typedef mat<3, 2, uint8, defaultp> u8mat3x2;
1073 typedef mat<4, 2, uint8, defaultp> u8mat4x2;
1074 typedef mat<2, 3, uint8, defaultp> u8mat2x3;
1075 typedef mat<3, 3, uint8, defaultp> u8mat3x3;
1076 typedef mat<4, 3, uint8, defaultp> u8mat4x3;
1077 typedef mat<2, 4, uint8, defaultp> u8mat2x4;
1078 typedef mat<3, 4, uint8, defaultp> u8mat3x4;
1079 typedef mat<4, 4, uint8, defaultp> u8mat4x4;
1080
1081
1082 typedef mat<2, 2, uint16, lowp> lowp_u16mat2x2;
1083 typedef mat<2, 3, uint16, lowp> lowp_u16mat2x3;
1084 typedef mat<2, 4, uint16, lowp> lowp_u16mat2x4;
1085 typedef mat<3, 2, uint16, lowp> lowp_u16mat3x2;
1086 typedef mat<3, 3, uint16, lowp> lowp_u16mat3x3;
1087 typedef mat<3, 4, uint16, lowp> lowp_u16mat3x4;
1088 typedef mat<4, 2, uint16, lowp> lowp_u16mat4x2;
1089 typedef mat<4, 3, uint16, lowp> lowp_u16mat4x3;
1090 typedef mat<4, 4, uint16, lowp> lowp_u16mat4x4;
1091
1092 typedef mat<2, 2, uint16, mediump> mediump_u16mat2x2;
1093 typedef mat<2, 3, uint16, mediump> mediump_u16mat2x3;
1094 typedef mat<2, 4, uint16, mediump> mediump_u16mat2x4;
1095 typedef mat<3, 2, uint16, mediump> mediump_u16mat3x2;
1096 typedef mat<3, 3, uint16, mediump> mediump_u16mat3x3;
1097 typedef mat<3, 4, uint16, mediump> mediump_u16mat3x4;
1098 typedef mat<4, 2, uint16, mediump> mediump_u16mat4x2;
1099 typedef mat<4, 3, uint16, mediump> mediump_u16mat4x3;
1100 typedef mat<4, 4, uint16, mediump> mediump_u16mat4x4;
1101
1102 typedef mat<2, 2, uint16, highp> highp_u16mat2x2;
1103 typedef mat<2, 3, uint16, highp> highp_u16mat2x3;
1104 typedef mat<2, 4, uint16, highp> highp_u16mat2x4;
1105 typedef mat<3, 2, uint16, highp> highp_u16mat3x2;
1106 typedef mat<3, 3, uint16, highp> highp_u16mat3x3;
1107 typedef mat<3, 4, uint16, highp> highp_u16mat3x4;
1108 typedef mat<4, 2, uint16, highp> highp_u16mat4x2;
1109 typedef mat<4, 3, uint16, highp> highp_u16mat4x3;
1110 typedef mat<4, 4, uint16, highp> highp_u16mat4x4;
1111
1112 typedef mat<2, 2, uint16, defaultp> u16mat2x2;
1113 typedef mat<3, 2, uint16, defaultp> u16mat3x2;
1114 typedef mat<4, 2, uint16, defaultp> u16mat4x2;
1115 typedef mat<2, 3, uint16, defaultp> u16mat2x3;
1116 typedef mat<3, 3, uint16, defaultp> u16mat3x3;
1117 typedef mat<4, 3, uint16, defaultp> u16mat4x3;
1118 typedef mat<2, 4, uint16, defaultp> u16mat2x4;
1119 typedef mat<3, 4, uint16, defaultp> u16mat3x4;
1120 typedef mat<4, 4, uint16, defaultp> u16mat4x4;
1121
1122
1123 typedef mat<2, 2, uint32, lowp> lowp_u32mat2x2;
1124 typedef mat<2, 3, uint32, lowp> lowp_u32mat2x3;
1125 typedef mat<2, 4, uint32, lowp> lowp_u32mat2x4;
1126 typedef mat<3, 2, uint32, lowp> lowp_u32mat3x2;
1127 typedef mat<3, 3, uint32, lowp> lowp_u32mat3x3;
1128 typedef mat<3, 4, uint32, lowp> lowp_u32mat3x4;
1129 typedef mat<4, 2, uint32, lowp> lowp_u32mat4x2;
1130 typedef mat<4, 3, uint32, lowp> lowp_u32mat4x3;
1131 typedef mat<4, 4, uint32, lowp> lowp_u32mat4x4;
1132
1133 typedef mat<2, 2, uint32, mediump> mediump_u32mat2x2;
1134 typedef mat<2, 3, uint32, mediump> mediump_u32mat2x3;
1135 typedef mat<2, 4, uint32, mediump> mediump_u32mat2x4;
1136 typedef mat<3, 2, uint32, mediump> mediump_u32mat3x2;
1137 typedef mat<3, 3, uint32, mediump> mediump_u32mat3x3;
1138 typedef mat<3, 4, uint32, mediump> mediump_u32mat3x4;
1139 typedef mat<4, 2, uint32, mediump> mediump_u32mat4x2;
1140 typedef mat<4, 3, uint32, mediump> mediump_u32mat4x3;
1141 typedef mat<4, 4, uint32, mediump> mediump_u32mat4x4;
1142
1143 typedef mat<2, 2, uint32, highp> highp_u32mat2x2;
1144 typedef mat<2, 3, uint32, highp> highp_u32mat2x3;
1145 typedef mat<2, 4, uint32, highp> highp_u32mat2x4;
1146 typedef mat<3, 2, uint32, highp> highp_u32mat3x2;
1147 typedef mat<3, 3, uint32, highp> highp_u32mat3x3;
1148 typedef mat<3, 4, uint32, highp> highp_u32mat3x4;
1149 typedef mat<4, 2, uint32, highp> highp_u32mat4x2;
1150 typedef mat<4, 3, uint32, highp> highp_u32mat4x3;
1151 typedef mat<4, 4, uint32, highp> highp_u32mat4x4;
1152
1153 typedef mat<2, 2, uint32, defaultp> u32mat2x2;
1154 typedef mat<3, 2, uint32, defaultp> u32mat3x2;
1155 typedef mat<4, 2, uint32, defaultp> u32mat4x2;
1156 typedef mat<2, 3, uint32, defaultp> u32mat2x3;
1157 typedef mat<3, 3, uint32, defaultp> u32mat3x3;
1158 typedef mat<4, 3, uint32, defaultp> u32mat4x3;
1159 typedef mat<2, 4, uint32, defaultp> u32mat2x4;
1160 typedef mat<3, 4, uint32, defaultp> u32mat3x4;
1161 typedef mat<4, 4, uint32, defaultp> u32mat4x4;
1162
1163
1164 typedef mat<2, 2, uint64, lowp> lowp_u64mat2x2;
1165 typedef mat<2, 3, uint64, lowp> lowp_u64mat2x3;
1166 typedef mat<2, 4, uint64, lowp> lowp_u64mat2x4;
1167 typedef mat<3, 2, uint64, lowp> lowp_u64mat3x2;
1168 typedef mat<3, 3, uint64, lowp> lowp_u64mat3x3;
1169 typedef mat<3, 4, uint64, lowp> lowp_u64mat3x4;
1170 typedef mat<4, 2, uint64, lowp> lowp_u64mat4x2;
1171 typedef mat<4, 3, uint64, lowp> lowp_u64mat4x3;
1172 typedef mat<4, 4, uint64, lowp> lowp_u64mat4x4;
1173
1174 typedef mat<2, 2, uint64, mediump> mediump_u64mat2x2;
1175 typedef mat<2, 3, uint64, mediump> mediump_u64mat2x3;
1176 typedef mat<2, 4, uint64, mediump> mediump_u64mat2x4;
1177 typedef mat<3, 2, uint64, mediump> mediump_u64mat3x2;
1178 typedef mat<3, 3, uint64, mediump> mediump_u64mat3x3;
1179 typedef mat<3, 4, uint64, mediump> mediump_u64mat3x4;
1180 typedef mat<4, 2, uint64, mediump> mediump_u64mat4x2;
1181 typedef mat<4, 3, uint64, mediump> mediump_u64mat4x3;
1182 typedef mat<4, 4, uint64, mediump> mediump_u64mat4x4;
1183
1184 typedef mat<2, 2, uint64, highp> highp_u64mat2x2;
1185 typedef mat<2, 3, uint64, highp> highp_u64mat2x3;
1186 typedef mat<2, 4, uint64, highp> highp_u64mat2x4;
1187 typedef mat<3, 2, uint64, highp> highp_u64mat3x2;
1188 typedef mat<3, 3, uint64, highp> highp_u64mat3x3;
1189 typedef mat<3, 4, uint64, highp> highp_u64mat3x4;
1190 typedef mat<4, 2, uint64, highp> highp_u64mat4x2;
1191 typedef mat<4, 3, uint64, highp> highp_u64mat4x3;
1192 typedef mat<4, 4, uint64, highp> highp_u64mat4x4;
1193
1194 typedef mat<2, 2, uint64, defaultp> u64mat2x2;
1195 typedef mat<3, 2, uint64, defaultp> u64mat3x2;
1196 typedef mat<4, 2, uint64, defaultp> u64mat4x2;
1197 typedef mat<2, 3, uint64, defaultp> u64mat2x3;
1198 typedef mat<3, 3, uint64, defaultp> u64mat3x3;
1199 typedef mat<4, 3, uint64, defaultp> u64mat4x3;
1200 typedef mat<2, 4, uint64, defaultp> u64mat2x4;
1201 typedef mat<3, 4, uint64, defaultp> u64mat3x4;
1202 typedef mat<4, 4, uint64, defaultp> u64mat4x4;
1203
7891204 // Quaternion
7901205
7911206 typedef qua<float, lowp> lowp_quat;
328328 /// @see gtc_matrix_integer
329329 typedef mat<4, 4, uint, lowp> lowp_umat4x4;
330330
331 #if(defined(GLM_PRECISION_HIGHP_INT))
332 typedef highp_imat2 imat2;
333 typedef highp_imat3 imat3;
334 typedef highp_imat4 imat4;
335 typedef highp_imat2x2 imat2x2;
336 typedef highp_imat2x3 imat2x3;
337 typedef highp_imat2x4 imat2x4;
338 typedef highp_imat3x2 imat3x2;
339 typedef highp_imat3x3 imat3x3;
340 typedef highp_imat3x4 imat3x4;
341 typedef highp_imat4x2 imat4x2;
342 typedef highp_imat4x3 imat4x3;
343 typedef highp_imat4x4 imat4x4;
344 #elif(defined(GLM_PRECISION_LOWP_INT))
345 typedef lowp_imat2 imat2;
346 typedef lowp_imat3 imat3;
347 typedef lowp_imat4 imat4;
348 typedef lowp_imat2x2 imat2x2;
349 typedef lowp_imat2x3 imat2x3;
350 typedef lowp_imat2x4 imat2x4;
351 typedef lowp_imat3x2 imat3x2;
352 typedef lowp_imat3x3 imat3x3;
353 typedef lowp_imat3x4 imat3x4;
354 typedef lowp_imat4x2 imat4x2;
355 typedef lowp_imat4x3 imat4x3;
356 typedef lowp_imat4x4 imat4x4;
357 #else //if(defined(GLM_PRECISION_MEDIUMP_INT))
331
358332
359333 /// Signed integer 2x2 matrix.
360334 /// @see gtc_matrix_integer
361 typedef mediump_imat2 imat2;
335 typedef mat<2, 2, int, defaultp> imat2;
362336
363337 /// Signed integer 3x3 matrix.
364338 /// @see gtc_matrix_integer
365 typedef mediump_imat3 imat3;
339 typedef mat<3, 3, int, defaultp> imat3;
366340
367341 /// Signed integer 4x4 matrix.
368342 /// @see gtc_matrix_integer
369 typedef mediump_imat4 imat4;
343 typedef mat<4, 4, int, defaultp> imat4;
370344
371345 /// Signed integer 2x2 matrix.
372346 /// @see gtc_matrix_integer
373 typedef mediump_imat2x2 imat2x2;
347 typedef mat<2, 2, int, defaultp> imat2x2;
374348
375349 /// Signed integer 2x3 matrix.
376350 /// @see gtc_matrix_integer
377 typedef mediump_imat2x3 imat2x3;
351 typedef mat<2, 3, int, defaultp> imat2x3;
378352
379353 /// Signed integer 2x4 matrix.
380354 /// @see gtc_matrix_integer
381 typedef mediump_imat2x4 imat2x4;
355 typedef mat<2, 4, int, defaultp> imat2x4;
382356
383357 /// Signed integer 3x2 matrix.
384358 /// @see gtc_matrix_integer
385 typedef mediump_imat3x2 imat3x2;
359 typedef mat<3, 2, int, defaultp> imat3x2;
386360
387361 /// Signed integer 3x3 matrix.
388362 /// @see gtc_matrix_integer
389 typedef mediump_imat3x3 imat3x3;
363 typedef mat<3, 3, int, defaultp> imat3x3;
390364
391365 /// Signed integer 3x4 matrix.
392366 /// @see gtc_matrix_integer
393 typedef mediump_imat3x4 imat3x4;
367 typedef mat<3, 4, int, defaultp> imat3x4;
394368
395369 /// Signed integer 4x2 matrix.
396370 /// @see gtc_matrix_integer
397 typedef mediump_imat4x2 imat4x2;
371 typedef mat<4, 2, int, defaultp> imat4x2;
398372
399373 /// Signed integer 4x3 matrix.
400374 /// @see gtc_matrix_integer
401 typedef mediump_imat4x3 imat4x3;
375 typedef mat<4, 3, int, defaultp> imat4x3;
402376
403377 /// Signed integer 4x4 matrix.
404378 /// @see gtc_matrix_integer
405 typedef mediump_imat4x4 imat4x4;
406 #endif//GLM_PRECISION
407
408 #if(defined(GLM_PRECISION_HIGHP_UINT))
409 typedef highp_umat2 umat2;
410 typedef highp_umat3 umat3;
411 typedef highp_umat4 umat4;
412 typedef highp_umat2x2 umat2x2;
413 typedef highp_umat2x3 umat2x3;
414 typedef highp_umat2x4 umat2x4;
415 typedef highp_umat3x2 umat3x2;
416 typedef highp_umat3x3 umat3x3;
417 typedef highp_umat3x4 umat3x4;
418 typedef highp_umat4x2 umat4x2;
419 typedef highp_umat4x3 umat4x3;
420 typedef highp_umat4x4 umat4x4;
421 #elif(defined(GLM_PRECISION_LOWP_UINT))
422 typedef lowp_umat2 umat2;
423 typedef lowp_umat3 umat3;
424 typedef lowp_umat4 umat4;
425 typedef lowp_umat2x2 umat2x2;
426 typedef lowp_umat2x3 umat2x3;
427 typedef lowp_umat2x4 umat2x4;
428 typedef lowp_umat3x2 umat3x2;
429 typedef lowp_umat3x3 umat3x3;
430 typedef lowp_umat3x4 umat3x4;
431 typedef lowp_umat4x2 umat4x2;
432 typedef lowp_umat4x3 umat4x3;
433 typedef lowp_umat4x4 umat4x4;
434 #else //if(defined(GLM_PRECISION_MEDIUMP_UINT))
379 typedef mat<4, 4, int, defaultp> imat4x4;
380
381
435382
436383 /// Unsigned integer 2x2 matrix.
437384 /// @see gtc_matrix_integer
438 typedef mediump_umat2 umat2;
385 typedef mat<2, 2, uint, defaultp> umat2;
439386
440387 /// Unsigned integer 3x3 matrix.
441388 /// @see gtc_matrix_integer
442 typedef mediump_umat3 umat3;
389 typedef mat<3, 3, uint, defaultp> umat3;
443390
444391 /// Unsigned integer 4x4 matrix.
445392 /// @see gtc_matrix_integer
446 typedef mediump_umat4 umat4;
393 typedef mat<4, 4, uint, defaultp> umat4;
447394
448395 /// Unsigned integer 2x2 matrix.
449396 /// @see gtc_matrix_integer
450 typedef mediump_umat2x2 umat2x2;
397 typedef mat<2, 2, uint, defaultp> umat2x2;
451398
452399 /// Unsigned integer 2x3 matrix.
453400 /// @see gtc_matrix_integer
454 typedef mediump_umat2x3 umat2x3;
401 typedef mat<2, 3, uint, defaultp> umat2x3;
455402
456403 /// Unsigned integer 2x4 matrix.
457404 /// @see gtc_matrix_integer
458 typedef mediump_umat2x4 umat2x4;
405 typedef mat<2, 4, uint, defaultp> umat2x4;
459406
460407 /// Unsigned integer 3x2 matrix.
461408 /// @see gtc_matrix_integer
462 typedef mediump_umat3x2 umat3x2;
409 typedef mat<3, 2, uint, defaultp> umat3x2;
463410
464411 /// Unsigned integer 3x3 matrix.
465412 /// @see gtc_matrix_integer
466 typedef mediump_umat3x3 umat3x3;
413 typedef mat<3, 3, uint, defaultp> umat3x3;
467414
468415 /// Unsigned integer 3x4 matrix.
469416 /// @see gtc_matrix_integer
470 typedef mediump_umat3x4 umat3x4;
417 typedef mat<3, 4, uint, defaultp> umat3x4;
471418
472419 /// Unsigned integer 4x2 matrix.
473420 /// @see gtc_matrix_integer
474 typedef mediump_umat4x2 umat4x2;
421 typedef mat<4, 2, uint, defaultp> umat4x2;
475422
476423 /// Unsigned integer 4x3 matrix.
477424 /// @see gtc_matrix_integer
478 typedef mediump_umat4x3 umat4x3;
425 typedef mat<4, 3, uint, defaultp> umat4x3;
479426
480427 /// Unsigned integer 4x4 matrix.
481428 /// @see gtc_matrix_integer
482 typedef mediump_umat4x4 umat4x4;
483 #endif//GLM_PRECISION
429 typedef mat<4, 4, uint, defaultp> umat4x4;
484430
485431 /// @}
486432 }//namespace glm
1414
1515 // Dependency:
1616 #include "type_precision.hpp"
17 #include "../ext/vector_packing.hpp"
1718
1819 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
1920 # pragma message("GLM: GLM_GTC_packing extension included")
720721 /// @see int packUint2x16(u32vec2 const& v)
721722 GLM_FUNC_DECL u32vec2 unpackUint2x32(uint64 p);
722723
723
724724 /// @}
725725 }// namespace glm
726726
174174 mat<3, 3, T, Q> Result;
175175
176176 Result[2] = -direction;
177 Result[0] = normalize(cross(up, Result[2]));
177 vec<3, T, Q> const& Right = cross(up, Result[2]);
178 Result[0] = Right * inversesqrt(max(static_cast<T>(0.00001), dot(Right, Right)));
178179 Result[1] = cross(Result[2], Result[0]);
179180
180181 return quat_cast(Result);
186187 mat<3, 3, T, Q> Result;
187188
188189 Result[2] = direction;
189 Result[0] = normalize(cross(up, Result[2]));
190 vec<3, T, Q> const& Right = cross(up, Result[2]);
191 Result[0] = Right * inversesqrt(max(static_cast<T>(0.00001), dot(Right, Right)));
190192 Result[1] = cross(Result[2], Result[0]);
191193
192194 return quat_cast(Result);
1515 // Dependency:
1616 #include "../gtc/quaternion.hpp"
1717 #include "../gtc/vec1.hpp"
18 #include "../ext/vector_int1_sized.hpp"
19 #include "../ext/vector_int2_sized.hpp"
20 #include "../ext/vector_int3_sized.hpp"
21 #include "../ext/vector_int4_sized.hpp"
1822 #include "../ext/scalar_int_sized.hpp"
23 #include "../ext/vector_uint1_sized.hpp"
24 #include "../ext/vector_uint2_sized.hpp"
25 #include "../ext/vector_uint3_sized.hpp"
26 #include "../ext/vector_uint4_sized.hpp"
1927 #include "../ext/scalar_uint_sized.hpp"
2028 #include "../detail/type_vec2.hpp"
2129 #include "../detail/type_vec3.hpp"
226234 /// @see gtc_type_precision
227235 typedef detail::int64 i64;
228236
229
230
231 /// Low qualifier 8 bit signed integer scalar type.
232 /// @see gtc_type_precision
233 typedef vec<1, i8, lowp> lowp_i8vec1;
234
235 /// Low qualifier 8 bit signed integer vector of 2 components type.
236 /// @see gtc_type_precision
237 typedef vec<2, i8, lowp> lowp_i8vec2;
238
239 /// Low qualifier 8 bit signed integer vector of 3 components type.
240 /// @see gtc_type_precision
241 typedef vec<3, i8, lowp> lowp_i8vec3;
242
243 /// Low qualifier 8 bit signed integer vector of 4 components type.
244 /// @see gtc_type_precision
245 typedef vec<4, i8, lowp> lowp_i8vec4;
246
247
248 /// Medium qualifier 8 bit signed integer scalar type.
249 /// @see gtc_type_precision
250 typedef vec<1, i8, mediump> mediump_i8vec1;
251
252 /// Medium qualifier 8 bit signed integer vector of 2 components type.
253 /// @see gtc_type_precision
254 typedef vec<2, i8, mediump> mediump_i8vec2;
255
256 /// Medium qualifier 8 bit signed integer vector of 3 components type.
257 /// @see gtc_type_precision
258 typedef vec<3, i8, mediump> mediump_i8vec3;
259
260 /// Medium qualifier 8 bit signed integer vector of 4 components type.
261 /// @see gtc_type_precision
262 typedef vec<4, i8, mediump> mediump_i8vec4;
263
264
265 /// High qualifier 8 bit signed integer scalar type.
266 /// @see gtc_type_precision
267 typedef vec<1, i8, highp> highp_i8vec1;
268
269 /// High qualifier 8 bit signed integer vector of 2 components type.
270 /// @see gtc_type_precision
271 typedef vec<2, i8, highp> highp_i8vec2;
272
273 /// High qualifier 8 bit signed integer vector of 3 components type.
274 /// @see gtc_type_precision
275 typedef vec<3, i8, highp> highp_i8vec3;
276
277 /// High qualifier 8 bit signed integer vector of 4 components type.
278 /// @see gtc_type_precision
279 typedef vec<4, i8, highp> highp_i8vec4;
280
281
282
283 /// 8 bit signed integer scalar type.
284 /// @see gtc_type_precision
285 typedef vec<1, i8, defaultp> i8vec1;
286
287 /// 8 bit signed integer vector of 2 components type.
288 /// @see gtc_type_precision
289 typedef vec<2, i8, defaultp> i8vec2;
290
291 /// 8 bit signed integer vector of 3 components type.
292 /// @see gtc_type_precision
293 typedef vec<3, i8, defaultp> i8vec3;
294
295 /// 8 bit signed integer vector of 4 components type.
296 /// @see gtc_type_precision
297 typedef vec<4, i8, defaultp> i8vec4;
298
299
300
301
302
303 /// Low qualifier 16 bit signed integer scalar type.
304 /// @see gtc_type_precision
305 typedef vec<1, i16, lowp> lowp_i16vec1;
306
307 /// Low qualifier 16 bit signed integer vector of 2 components type.
308 /// @see gtc_type_precision
309 typedef vec<2, i16, lowp> lowp_i16vec2;
310
311 /// Low qualifier 16 bit signed integer vector of 3 components type.
312 /// @see gtc_type_precision
313 typedef vec<3, i16, lowp> lowp_i16vec3;
314
315 /// Low qualifier 16 bit signed integer vector of 4 components type.
316 /// @see gtc_type_precision
317 typedef vec<4, i16, lowp> lowp_i16vec4;
318
319
320 /// Medium qualifier 16 bit signed integer scalar type.
321 /// @see gtc_type_precision
322 typedef vec<1, i16, mediump> mediump_i16vec1;
323
324 /// Medium qualifier 16 bit signed integer vector of 2 components type.
325 /// @see gtc_type_precision
326 typedef vec<2, i16, mediump> mediump_i16vec2;
327
328 /// Medium qualifier 16 bit signed integer vector of 3 components type.
329 /// @see gtc_type_precision
330 typedef vec<3, i16, mediump> mediump_i16vec3;
331
332 /// Medium qualifier 16 bit signed integer vector of 4 components type.
333 /// @see gtc_type_precision
334 typedef vec<4, i16, mediump> mediump_i16vec4;
335
336
337 /// High qualifier 16 bit signed integer scalar type.
338 /// @see gtc_type_precision
339 typedef vec<1, i16, highp> highp_i16vec1;
340
341 /// High qualifier 16 bit signed integer vector of 2 components type.
342 /// @see gtc_type_precision
343 typedef vec<2, i16, highp> highp_i16vec2;
344
345 /// High qualifier 16 bit signed integer vector of 3 components type.
346 /// @see gtc_type_precision
347 typedef vec<3, i16, highp> highp_i16vec3;
348
349 /// High qualifier 16 bit signed integer vector of 4 components type.
350 /// @see gtc_type_precision
351 typedef vec<4, i16, highp> highp_i16vec4;
352
353
354
355
356 /// 16 bit signed integer scalar type.
357 /// @see gtc_type_precision
358 typedef vec<1, i16, defaultp> i16vec1;
359
360 /// 16 bit signed integer vector of 2 components type.
361 /// @see gtc_type_precision
362 typedef vec<2, i16, defaultp> i16vec2;
363
364 /// 16 bit signed integer vector of 3 components type.
365 /// @see gtc_type_precision
366 typedef vec<3, i16, defaultp> i16vec3;
367
368 /// 16 bit signed integer vector of 4 components type.
369 /// @see gtc_type_precision
370 typedef vec<4, i16, defaultp> i16vec4;
371
372
373
374 /// Low qualifier 32 bit signed integer scalar type.
375 /// @see gtc_type_precision
376 typedef vec<1, i32, lowp> lowp_i32vec1;
377
378 /// Low qualifier 32 bit signed integer vector of 2 components type.
379 /// @see gtc_type_precision
380 typedef vec<2, i32, lowp> lowp_i32vec2;
381
382 /// Low qualifier 32 bit signed integer vector of 3 components type.
383 /// @see gtc_type_precision
384 typedef vec<3, i32, lowp> lowp_i32vec3;
385
386 /// Low qualifier 32 bit signed integer vector of 4 components type.
387 /// @see gtc_type_precision
388 typedef vec<4, i32, lowp> lowp_i32vec4;
389
390
391 /// Medium qualifier 32 bit signed integer scalar type.
392 /// @see gtc_type_precision
393 typedef vec<1, i32, mediump> mediump_i32vec1;
394
395 /// Medium qualifier 32 bit signed integer vector of 2 components type.
396 /// @see gtc_type_precision
397 typedef vec<2, i32, mediump> mediump_i32vec2;
398
399 /// Medium qualifier 32 bit signed integer vector of 3 components type.
400 /// @see gtc_type_precision
401 typedef vec<3, i32, mediump> mediump_i32vec3;
402
403 /// Medium qualifier 32 bit signed integer vector of 4 components type.
404 /// @see gtc_type_precision
405 typedef vec<4, i32, mediump> mediump_i32vec4;
406
407
408 /// High qualifier 32 bit signed integer scalar type.
409 /// @see gtc_type_precision
410 typedef vec<1, i32, highp> highp_i32vec1;
411
412 /// High qualifier 32 bit signed integer vector of 2 components type.
413 /// @see gtc_type_precision
414 typedef vec<2, i32, highp> highp_i32vec2;
415
416 /// High qualifier 32 bit signed integer vector of 3 components type.
417 /// @see gtc_type_precision
418 typedef vec<3, i32, highp> highp_i32vec3;
419
420 /// High qualifier 32 bit signed integer vector of 4 components type.
421 /// @see gtc_type_precision
422 typedef vec<4, i32, highp> highp_i32vec4;
423
424
425 /// 32 bit signed integer scalar type.
426 /// @see gtc_type_precision
427 typedef vec<1, i32, defaultp> i32vec1;
428
429 /// 32 bit signed integer vector of 2 components type.
430 /// @see gtc_type_precision
431 typedef vec<2, i32, defaultp> i32vec2;
432
433 /// 32 bit signed integer vector of 3 components type.
434 /// @see gtc_type_precision
435 typedef vec<3, i32, defaultp> i32vec3;
436
437 /// 32 bit signed integer vector of 4 components type.
438 /// @see gtc_type_precision
439 typedef vec<4, i32, defaultp> i32vec4;
440
441
442
443
444 /// Low qualifier 64 bit signed integer scalar type.
445 /// @see gtc_type_precision
446 typedef vec<1, i64, lowp> lowp_i64vec1;
447
448 /// Low qualifier 64 bit signed integer vector of 2 components type.
449 /// @see gtc_type_precision
450 typedef vec<2, i64, lowp> lowp_i64vec2;
451
452 /// Low qualifier 64 bit signed integer vector of 3 components type.
453 /// @see gtc_type_precision
454 typedef vec<3, i64, lowp> lowp_i64vec3;
455
456 /// Low qualifier 64 bit signed integer vector of 4 components type.
457 /// @see gtc_type_precision
458 typedef vec<4, i64, lowp> lowp_i64vec4;
459
460
461 /// Medium qualifier 64 bit signed integer scalar type.
462 /// @see gtc_type_precision
463 typedef vec<1, i64, mediump> mediump_i64vec1;
464
465 /// Medium qualifier 64 bit signed integer vector of 2 components type.
466 /// @see gtc_type_precision
467 typedef vec<2, i64, mediump> mediump_i64vec2;
468
469 /// Medium qualifier 64 bit signed integer vector of 3 components type.
470 /// @see gtc_type_precision
471 typedef vec<3, i64, mediump> mediump_i64vec3;
472
473 /// Medium qualifier 64 bit signed integer vector of 4 components type.
474 /// @see gtc_type_precision
475 typedef vec<4, i64, mediump> mediump_i64vec4;
476
477
478 /// High qualifier 64 bit signed integer scalar type.
479 /// @see gtc_type_precision
480 typedef vec<1, i64, highp> highp_i64vec1;
481
482 /// High qualifier 64 bit signed integer vector of 2 components type.
483 /// @see gtc_type_precision
484 typedef vec<2, i64, highp> highp_i64vec2;
485
486 /// High qualifier 64 bit signed integer vector of 3 components type.
487 /// @see gtc_type_precision
488 typedef vec<3, i64, highp> highp_i64vec3;
489
490 /// High qualifier 64 bit signed integer vector of 4 components type.
491 /// @see gtc_type_precision
492 typedef vec<4, i64, highp> highp_i64vec4;
493
494
495 /// 64 bit signed integer scalar type.
496 /// @see gtc_type_precision
497 typedef vec<1, i64, defaultp> i64vec1;
498
499 /// 64 bit signed integer vector of 2 components type.
500 /// @see gtc_type_precision
501 typedef vec<2, i64, defaultp> i64vec2;
502
503 /// 64 bit signed integer vector of 3 components type.
504 /// @see gtc_type_precision
505 typedef vec<3, i64, defaultp> i64vec3;
506
507 /// 64 bit signed integer vector of 4 components type.
508 /// @see gtc_type_precision
509 typedef vec<4, i64, defaultp> i64vec4;
510
511
512237 /////////////////////////////
513238 // Unsigned int vector types
514239
15531278 typedef highp_f64mat4x4 highp_f64mat4;
15541279
15551280
1281 /////////////////////////////
1282 // Signed int vector types
1283
1284 /// Low qualifier signed integer vector of 1 component type.
1285 /// @see gtc_type_precision
1286 typedef vec<1, int, lowp> lowp_ivec1;
1287
1288 /// Low qualifier signed integer vector of 2 components type.
1289 /// @see gtc_type_precision
1290 typedef vec<2, int, lowp> lowp_ivec2;
1291
1292 /// Low qualifier signed integer vector of 3 components type.
1293 /// @see gtc_type_precision
1294 typedef vec<3, int, lowp> lowp_ivec3;
1295
1296 /// Low qualifier signed integer vector of 4 components type.
1297 /// @see gtc_type_precision
1298 typedef vec<4, int, lowp> lowp_ivec4;
1299
1300
1301 /// Medium qualifier signed integer vector of 1 component type.
1302 /// @see gtc_type_precision
1303 typedef vec<1, int, mediump> mediump_ivec1;
1304
1305 /// Medium qualifier signed integer vector of 2 components type.
1306 /// @see gtc_type_precision
1307 typedef vec<2, int, mediump> mediump_ivec2;
1308
1309 /// Medium qualifier signed integer vector of 3 components type.
1310 /// @see gtc_type_precision
1311 typedef vec<3, int, mediump> mediump_ivec3;
1312
1313 /// Medium qualifier signed integer vector of 4 components type.
1314 /// @see gtc_type_precision
1315 typedef vec<4, int, mediump> mediump_ivec4;
1316
1317
1318 /// High qualifier signed integer vector of 1 component type.
1319 /// @see gtc_type_precision
1320 typedef vec<1, int, highp> highp_ivec1;
1321
1322 /// High qualifier signed integer vector of 2 components type.
1323 /// @see gtc_type_precision
1324 typedef vec<2, int, highp> highp_ivec2;
1325
1326 /// High qualifier signed integer vector of 3 components type.
1327 /// @see gtc_type_precision
1328 typedef vec<3, int, highp> highp_ivec3;
1329
1330 /// High qualifier signed integer vector of 4 components type.
1331 /// @see gtc_type_precision
1332 typedef vec<4, int, highp> highp_ivec4;
1333
1334
1335 /// Low qualifier 8 bit signed integer vector of 1 component type.
1336 /// @see gtc_type_precision
1337 typedef vec<1, i8, lowp> lowp_i8vec1;
1338
1339 /// Low qualifier 8 bit signed integer vector of 2 components type.
1340 /// @see gtc_type_precision
1341 typedef vec<2, i8, lowp> lowp_i8vec2;
1342
1343 /// Low qualifier 8 bit signed integer vector of 3 components type.
1344 /// @see gtc_type_precision
1345 typedef vec<3, i8, lowp> lowp_i8vec3;
1346
1347 /// Low qualifier 8 bit signed integer vector of 4 components type.
1348 /// @see gtc_type_precision
1349 typedef vec<4, i8, lowp> lowp_i8vec4;
1350
1351
1352 /// Medium qualifier 8 bit signed integer scalar type.
1353 /// @see gtc_type_precision
1354 typedef vec<1, i8, mediump> mediump_i8vec1;
1355
1356 /// Medium qualifier 8 bit signed integer vector of 2 components type.
1357 /// @see gtc_type_precision
1358 typedef vec<2, i8, mediump> mediump_i8vec2;
1359
1360 /// Medium qualifier 8 bit signed integer vector of 3 components type.
1361 /// @see gtc_type_precision
1362 typedef vec<3, i8, mediump> mediump_i8vec3;
1363
1364 /// Medium qualifier 8 bit signed integer vector of 4 components type.
1365 /// @see gtc_type_precision
1366 typedef vec<4, i8, mediump> mediump_i8vec4;
1367
1368
1369 /// High qualifier 8 bit signed integer scalar type.
1370 /// @see gtc_type_precision
1371 typedef vec<1, i8, highp> highp_i8vec1;
1372
1373 /// High qualifier 8 bit signed integer vector of 2 components type.
1374 /// @see gtc_type_precision
1375 typedef vec<2, i8, highp> highp_i8vec2;
1376
1377 /// High qualifier 8 bit signed integer vector of 3 components type.
1378 /// @see gtc_type_precision
1379 typedef vec<3, i8, highp> highp_i8vec3;
1380
1381 /// High qualifier 8 bit signed integer vector of 4 components type.
1382 /// @see gtc_type_precision
1383 typedef vec<4, i8, highp> highp_i8vec4;
1384
1385
1386 /// Low qualifier 16 bit signed integer scalar type.
1387 /// @see gtc_type_precision
1388 typedef vec<1, i16, lowp> lowp_i16vec1;
1389
1390 /// Low qualifier 16 bit signed integer vector of 2 components type.
1391 /// @see gtc_type_precision
1392 typedef vec<2, i16, lowp> lowp_i16vec2;
1393
1394 /// Low qualifier 16 bit signed integer vector of 3 components type.
1395 /// @see gtc_type_precision
1396 typedef vec<3, i16, lowp> lowp_i16vec3;
1397
1398 /// Low qualifier 16 bit signed integer vector of 4 components type.
1399 /// @see gtc_type_precision
1400 typedef vec<4, i16, lowp> lowp_i16vec4;
1401
1402
1403 /// Medium qualifier 16 bit signed integer scalar type.
1404 /// @see gtc_type_precision
1405 typedef vec<1, i16, mediump> mediump_i16vec1;
1406
1407 /// Medium qualifier 16 bit signed integer vector of 2 components type.
1408 /// @see gtc_type_precision
1409 typedef vec<2, i16, mediump> mediump_i16vec2;
1410
1411 /// Medium qualifier 16 bit signed integer vector of 3 components type.
1412 /// @see gtc_type_precision
1413 typedef vec<3, i16, mediump> mediump_i16vec3;
1414
1415 /// Medium qualifier 16 bit signed integer vector of 4 components type.
1416 /// @see gtc_type_precision
1417 typedef vec<4, i16, mediump> mediump_i16vec4;
1418
1419
1420 /// High qualifier 16 bit signed integer scalar type.
1421 /// @see gtc_type_precision
1422 typedef vec<1, i16, highp> highp_i16vec1;
1423
1424 /// High qualifier 16 bit signed integer vector of 2 components type.
1425 /// @see gtc_type_precision
1426 typedef vec<2, i16, highp> highp_i16vec2;
1427
1428 /// High qualifier 16 bit signed integer vector of 3 components type.
1429 /// @see gtc_type_precision
1430 typedef vec<3, i16, highp> highp_i16vec3;
1431
1432 /// High qualifier 16 bit signed integer vector of 4 components type.
1433 /// @see gtc_type_precision
1434 typedef vec<4, i16, highp> highp_i16vec4;
1435
1436
1437 /// Low qualifier 32 bit signed integer scalar type.
1438 /// @see gtc_type_precision
1439 typedef vec<1, i32, lowp> lowp_i32vec1;
1440
1441 /// Low qualifier 32 bit signed integer vector of 2 components type.
1442 /// @see gtc_type_precision
1443 typedef vec<2, i32, lowp> lowp_i32vec2;
1444
1445 /// Low qualifier 32 bit signed integer vector of 3 components type.
1446 /// @see gtc_type_precision
1447 typedef vec<3, i32, lowp> lowp_i32vec3;
1448
1449 /// Low qualifier 32 bit signed integer vector of 4 components type.
1450 /// @see gtc_type_precision
1451 typedef vec<4, i32, lowp> lowp_i32vec4;
1452
1453
1454 /// Medium qualifier 32 bit signed integer scalar type.
1455 /// @see gtc_type_precision
1456 typedef vec<1, i32, mediump> mediump_i32vec1;
1457
1458 /// Medium qualifier 32 bit signed integer vector of 2 components type.
1459 /// @see gtc_type_precision
1460 typedef vec<2, i32, mediump> mediump_i32vec2;
1461
1462 /// Medium qualifier 32 bit signed integer vector of 3 components type.
1463 /// @see gtc_type_precision
1464 typedef vec<3, i32, mediump> mediump_i32vec3;
1465
1466 /// Medium qualifier 32 bit signed integer vector of 4 components type.
1467 /// @see gtc_type_precision
1468 typedef vec<4, i32, mediump> mediump_i32vec4;
1469
1470
1471 /// High qualifier 32 bit signed integer scalar type.
1472 /// @see gtc_type_precision
1473 typedef vec<1, i32, highp> highp_i32vec1;
1474
1475 /// High qualifier 32 bit signed integer vector of 2 components type.
1476 /// @see gtc_type_precision
1477 typedef vec<2, i32, highp> highp_i32vec2;
1478
1479 /// High qualifier 32 bit signed integer vector of 3 components type.
1480 /// @see gtc_type_precision
1481 typedef vec<3, i32, highp> highp_i32vec3;
1482
1483 /// High qualifier 32 bit signed integer vector of 4 components type.
1484 /// @see gtc_type_precision
1485 typedef vec<4, i32, highp> highp_i32vec4;
1486
1487
1488 /// Low qualifier 64 bit signed integer scalar type.
1489 /// @see gtc_type_precision
1490 typedef vec<1, i64, lowp> lowp_i64vec1;
1491
1492 /// Low qualifier 64 bit signed integer vector of 2 components type.
1493 /// @see gtc_type_precision
1494 typedef vec<2, i64, lowp> lowp_i64vec2;
1495
1496 /// Low qualifier 64 bit signed integer vector of 3 components type.
1497 /// @see gtc_type_precision
1498 typedef vec<3, i64, lowp> lowp_i64vec3;
1499
1500 /// Low qualifier 64 bit signed integer vector of 4 components type.
1501 /// @see gtc_type_precision
1502 typedef vec<4, i64, lowp> lowp_i64vec4;
1503
1504
1505 /// Medium qualifier 64 bit signed integer scalar type.
1506 /// @see gtc_type_precision
1507 typedef vec<1, i64, mediump> mediump_i64vec1;
1508
1509 /// Medium qualifier 64 bit signed integer vector of 2 components type.
1510 /// @see gtc_type_precision
1511 typedef vec<2, i64, mediump> mediump_i64vec2;
1512
1513 /// Medium qualifier 64 bit signed integer vector of 3 components type.
1514 /// @see gtc_type_precision
1515 typedef vec<3, i64, mediump> mediump_i64vec3;
1516
1517 /// Medium qualifier 64 bit signed integer vector of 4 components type.
1518 /// @see gtc_type_precision
1519 typedef vec<4, i64, mediump> mediump_i64vec4;
1520
1521
1522 /// High qualifier 64 bit signed integer scalar type.
1523 /// @see gtc_type_precision
1524 typedef vec<1, i64, highp> highp_i64vec1;
1525
1526 /// High qualifier 64 bit signed integer vector of 2 components type.
1527 /// @see gtc_type_precision
1528 typedef vec<2, i64, highp> highp_i64vec2;
1529
1530 /// High qualifier 64 bit signed integer vector of 3 components type.
1531 /// @see gtc_type_precision
1532 typedef vec<3, i64, highp> highp_i64vec3;
1533
1534 /// High qualifier 64 bit signed integer vector of 4 components type.
1535 /// @see gtc_type_precision
1536 typedef vec<4, i64, highp> highp_i64vec4;
1537
1538
1539 /////////////////////////////
1540 // Unsigned int vector types
1541
1542 /// Low qualifier unsigned integer vector of 1 component type.
1543 /// @see gtc_type_precision
1544 typedef vec<1, uint, lowp> lowp_uvec1;
1545
1546 /// Low qualifier unsigned integer vector of 2 components type.
1547 /// @see gtc_type_precision
1548 typedef vec<2, uint, lowp> lowp_uvec2;
1549
1550 /// Low qualifier unsigned integer vector of 3 components type.
1551 /// @see gtc_type_precision
1552 typedef vec<3, uint, lowp> lowp_uvec3;
1553
1554 /// Low qualifier unsigned integer vector of 4 components type.
1555 /// @see gtc_type_precision
1556 typedef vec<4, uint, lowp> lowp_uvec4;
1557
1558
1559 /// Medium qualifier unsigned integer vector of 1 component type.
1560 /// @see gtc_type_precision
1561 typedef vec<1, uint, mediump> mediump_uvec1;
1562
1563 /// Medium qualifier unsigned integer vector of 2 components type.
1564 /// @see gtc_type_precision
1565 typedef vec<2, uint, mediump> mediump_uvec2;
1566
1567 /// Medium qualifier unsigned integer vector of 3 components type.
1568 /// @see gtc_type_precision
1569 typedef vec<3, uint, mediump> mediump_uvec3;
1570
1571 /// Medium qualifier unsigned integer vector of 4 components type.
1572 /// @see gtc_type_precision
1573 typedef vec<4, uint, mediump> mediump_uvec4;
1574
1575
1576 /// High qualifier unsigned integer vector of 1 component type.
1577 /// @see gtc_type_precision
1578 typedef vec<1, uint, highp> highp_uvec1;
1579
1580 /// High qualifier unsigned integer vector of 2 components type.
1581 /// @see gtc_type_precision
1582 typedef vec<2, uint, highp> highp_uvec2;
1583
1584 /// High qualifier unsigned integer vector of 3 components type.
1585 /// @see gtc_type_precision
1586 typedef vec<3, uint, highp> highp_uvec3;
1587
1588 /// High qualifier unsigned integer vector of 4 components type.
1589 /// @see gtc_type_precision
1590 typedef vec<4, uint, highp> highp_uvec4;
15561591
15571592
15581593 /// Low qualifier 8 bit unsigned integer scalar type.
15591594 /// @see gtc_type_precision
1560 typedef vec<1, u8, lowp> lowp_u8vec1;
1595 typedef vec<1, u8, lowp> lowp_u8vec1;
15611596
15621597 /// Low qualifier 8 bit unsigned integer vector of 2 components type.
15631598 /// @see gtc_type_precision
1564 typedef vec<2, u8, lowp> lowp_u8vec2;
1599 typedef vec<2, u8, lowp> lowp_u8vec2;
15651600
15661601 /// Low qualifier 8 bit unsigned integer vector of 3 components type.
15671602 /// @see gtc_type_precision
1568 typedef vec<3, u8, lowp> lowp_u8vec3;
1603 typedef vec<3, u8, lowp> lowp_u8vec3;
15691604
15701605 /// Low qualifier 8 bit unsigned integer vector of 4 components type.
15711606 /// @see gtc_type_precision
1572 typedef vec<4, u8, lowp> lowp_u8vec4;
1607 typedef vec<4, u8, lowp> lowp_u8vec4;
15731608
15741609
15751610 /// Medium qualifier 8 bit unsigned integer scalar type.
15761611 /// @see gtc_type_precision
1577 typedef vec<1, u8, mediump> mediump_u8vec1;
1612 typedef vec<1, u8, mediump> mediump_u8vec1;
15781613
15791614 /// Medium qualifier 8 bit unsigned integer vector of 2 components type.
15801615 /// @see gtc_type_precision
1581 typedef vec<2, u8, mediump> mediump_u8vec2;
1616 typedef vec<2, u8, mediump> mediump_u8vec2;
15821617
15831618 /// Medium qualifier 8 bit unsigned integer vector of 3 components type.
15841619 /// @see gtc_type_precision
1585 typedef vec<3, u8, mediump> mediump_u8vec3;
1620 typedef vec<3, u8, mediump> mediump_u8vec3;
15861621
15871622 /// Medium qualifier 8 bit unsigned integer vector of 4 components type.
15881623 /// @see gtc_type_precision
1589 typedef vec<4, u8, mediump> mediump_u8vec4;
1624 typedef vec<4, u8, mediump> mediump_u8vec4;
15901625
15911626
15921627 /// High qualifier 8 bit unsigned integer scalar type.
15931628 /// @see gtc_type_precision
1594 typedef vec<1, u8, highp> highp_u8vec1;
1629 typedef vec<1, u8, highp> highp_u8vec1;
15951630
15961631 /// High qualifier 8 bit unsigned integer vector of 2 components type.
15971632 /// @see gtc_type_precision
1598 typedef vec<2, u8, highp> highp_u8vec2;
1633 typedef vec<2, u8, highp> highp_u8vec2;
15991634
16001635 /// High qualifier 8 bit unsigned integer vector of 3 components type.
16011636 /// @see gtc_type_precision
1602 typedef vec<3, u8, highp> highp_u8vec3;
1637 typedef vec<3, u8, highp> highp_u8vec3;
16031638
16041639 /// High qualifier 8 bit unsigned integer vector of 4 components type.
16051640 /// @see gtc_type_precision
1606 typedef vec<4, u8, highp> highp_u8vec4;
1607
1608
1609
1610 /// Default qualifier 8 bit unsigned integer scalar type.
1611 /// @see gtc_type_precision
1612 typedef vec<1, u8, defaultp> u8vec1;
1613
1614 /// Default qualifier 8 bit unsigned integer vector of 2 components type.
1615 /// @see gtc_type_precision
1616 typedef vec<2, u8, defaultp> u8vec2;
1617
1618 /// Default qualifier 8 bit unsigned integer vector of 3 components type.
1619 /// @see gtc_type_precision
1620 typedef vec<3, u8, defaultp> u8vec3;
1621
1622 /// Default qualifier 8 bit unsigned integer vector of 4 components type.
1623 /// @see gtc_type_precision
1624 typedef vec<4, u8, defaultp> u8vec4;
1625
1626
1641 typedef vec<4, u8, highp> highp_u8vec4;
16271642
16281643
16291644 /// Low qualifier 16 bit unsigned integer scalar type.
16451660
16461661 /// Medium qualifier 16 bit unsigned integer scalar type.
16471662 /// @see gtc_type_precision
1648 typedef vec<1, u16, mediump> mediump_u16vec1;
1663 typedef vec<1, u16, mediump> mediump_u16vec1;
16491664
16501665 /// Medium qualifier 16 bit unsigned integer vector of 2 components type.
16511666 /// @see gtc_type_precision
1652 typedef vec<2, u16, mediump> mediump_u16vec2;
1667 typedef vec<2, u16, mediump> mediump_u16vec2;
16531668
16541669 /// Medium qualifier 16 bit unsigned integer vector of 3 components type.
16551670 /// @see gtc_type_precision
1656 typedef vec<3, u16, mediump> mediump_u16vec3;
1671 typedef vec<3, u16, mediump> mediump_u16vec3;
16571672
16581673 /// Medium qualifier 16 bit unsigned integer vector of 4 components type.
16591674 /// @see gtc_type_precision
1660 typedef vec<4, u16, mediump> mediump_u16vec4;
1675 typedef vec<4, u16, mediump> mediump_u16vec4;
16611676
16621677
16631678 /// High qualifier 16 bit unsigned integer scalar type.
16771692 typedef vec<4, u16, highp> highp_u16vec4;
16781693
16791694
1680
1681
1682 /// Default qualifier 16 bit unsigned integer scalar type.
1683 /// @see gtc_type_precision
1684 typedef vec<1, u16, defaultp> u16vec1;
1685
1686 /// Default qualifier 16 bit unsigned integer vector of 2 components type.
1687 /// @see gtc_type_precision
1688 typedef vec<2, u16, defaultp> u16vec2;
1689
1690 /// Default qualifier 16 bit unsigned integer vector of 3 components type.
1691 /// @see gtc_type_precision
1692 typedef vec<3, u16, defaultp> u16vec3;
1693
1694 /// Default qualifier 16 bit unsigned integer vector of 4 components type.
1695 /// @see gtc_type_precision
1696 typedef vec<4, u16, defaultp> u16vec4;
1697
1698
1699
17001695 /// Low qualifier 32 bit unsigned integer scalar type.
17011696 /// @see gtc_type_precision
17021697 typedef vec<1, u32, lowp> lowp_u32vec1;
17161711
17171712 /// Medium qualifier 32 bit unsigned integer scalar type.
17181713 /// @see gtc_type_precision
1719 typedef vec<1, u32, mediump> mediump_u32vec1;
1714 typedef vec<1, u32, mediump> mediump_u32vec1;
17201715
17211716 /// Medium qualifier 32 bit unsigned integer vector of 2 components type.
17221717 /// @see gtc_type_precision
1723 typedef vec<2, u32, mediump> mediump_u32vec2;
1718 typedef vec<2, u32, mediump> mediump_u32vec2;
17241719
17251720 /// Medium qualifier 32 bit unsigned integer vector of 3 components type.
17261721 /// @see gtc_type_precision
1727 typedef vec<3, u32, mediump> mediump_u32vec3;
1722 typedef vec<3, u32, mediump> mediump_u32vec3;
17281723
17291724 /// Medium qualifier 32 bit unsigned integer vector of 4 components type.
17301725 /// @see gtc_type_precision
1731 typedef vec<4, u32, mediump> mediump_u32vec4;
1726 typedef vec<4, u32, mediump> mediump_u32vec4;
17321727
17331728
17341729 /// High qualifier 32 bit unsigned integer scalar type.
17481743 typedef vec<4, u32, highp> highp_u32vec4;
17491744
17501745
1751
1752 /// Default qualifier 32 bit unsigned integer scalar type.
1753 /// @see gtc_type_precision
1754 typedef vec<1, u32, defaultp> u32vec1;
1755
1756 /// Default qualifier 32 bit unsigned integer vector of 2 components type.
1757 /// @see gtc_type_precision
1758 typedef vec<2, u32, defaultp> u32vec2;
1759
1760 /// Default qualifier 32 bit unsigned integer vector of 3 components type.
1761 /// @see gtc_type_precision
1762 typedef vec<3, u32, defaultp> u32vec3;
1763
1764 /// Default qualifier 32 bit unsigned integer vector of 4 components type.
1765 /// @see gtc_type_precision
1766 typedef vec<4, u32, defaultp> u32vec4;
1767
1768
1769
1770
17711746 /// Low qualifier 64 bit unsigned integer scalar type.
17721747 /// @see gtc_type_precision
17731748 typedef vec<1, u64, lowp> lowp_u64vec1;
17871762
17881763 /// Medium qualifier 64 bit unsigned integer scalar type.
17891764 /// @see gtc_type_precision
1790 typedef vec<1, u64, mediump> mediump_u64vec1;
1765 typedef vec<1, u64, mediump> mediump_u64vec1;
17911766
17921767 /// Medium qualifier 64 bit unsigned integer vector of 2 components type.
17931768 /// @see gtc_type_precision
1794 typedef vec<2, u64, mediump> mediump_u64vec2;
1769 typedef vec<2, u64, mediump> mediump_u64vec2;
17951770
17961771 /// Medium qualifier 64 bit unsigned integer vector of 3 components type.
17971772 /// @see gtc_type_precision
1798 typedef vec<3, u64, mediump> mediump_u64vec3;
1773 typedef vec<3, u64, mediump> mediump_u64vec3;
17991774
18001775 /// Medium qualifier 64 bit unsigned integer vector of 4 components type.
18011776 /// @see gtc_type_precision
1802 typedef vec<4, u64, mediump> mediump_u64vec4;
1777 typedef vec<4, u64, mediump> mediump_u64vec4;
18031778
18041779
18051780 /// High qualifier 64 bit unsigned integer scalar type.
18171792 /// High qualifier 64 bit unsigned integer vector of 4 components type.
18181793 /// @see gtc_type_precision
18191794 typedef vec<4, u64, highp> highp_u64vec4;
1820
1821
1822
1823
1824 /// Default qualifier 64 bit unsigned integer scalar type.
1825 /// @see gtc_type_precision
1826 typedef vec<1, u64, defaultp> u64vec1;
1827
1828 /// Default qualifier 64 bit unsigned integer vector of 2 components type.
1829 /// @see gtc_type_precision
1830 typedef vec<2, u64, defaultp> u64vec2;
1831
1832 /// Default qualifier 64 bit unsigned integer vector of 3 components type.
1833 /// @see gtc_type_precision
1834 typedef vec<3, u64, defaultp> u64vec3;
1835
1836 /// Default qualifier 64 bit unsigned integer vector of 4 components type.
1837 /// @see gtc_type_precision
1838 typedef vec<4, u64, defaultp> u64vec4;
18391795
18401796
18411797 //////////////////////
1919 #include "../ext/vector_double1.hpp"
2020 #include "../ext/vector_double1_precision.hpp"
2121 #include "../ext/vector_int1.hpp"
22 #include "../ext/vector_int1_precision.hpp"
22 #include "../ext/vector_int1_sized.hpp"
2323 #include "../ext/vector_uint1.hpp"
24 #include "../ext/vector_uint1_precision.hpp"
24 #include "../ext/vector_uint1_sized.hpp"
2525
2626 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
2727 # pragma message("GLM: GLM_GTC_vec1 extension included")
1313
1414 // Dependency:
1515 #include "../glm.hpp"
16 #include "../ext/vector_common.hpp"
1617
1718 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
1819 # ifndef GLM_ENABLE_EXPERIMENTAL
129130 C<T> const& z,
130131 C<T> const& w);
131132
132 /// Returns y if y < x; otherwise, it returns x. If one of the two arguments is NaN, the value of the other argument is returned.
133 ///
134 /// @tparam genType Floating-point or integer; scalar or vector types.
135 ///
136 /// @see gtx_extented_min_max
137 template<typename genType>
138 GLM_FUNC_DECL genType fmin(genType x, genType y);
139
140 /// Returns y if x < y; otherwise, it returns x. If one of the two arguments is NaN, the value of the other argument is returned.
141 ///
142 /// @tparam genType Floating-point; scalar or vector types.
143 ///
144 /// @see gtx_extented_min_max
145 /// @see <a href="http://en.cppreference.com/w/cpp/numeric/math/fmax">std::fmax documentation</a>
146 template<typename genType>
147 GLM_FUNC_DECL genType fmax(genType x, genType y);
148
149 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
150 ///
151 /// @tparam genType Floating-point scalar or vector types.
152 ///
153 /// @see gtx_extented_min_max
154 template<typename genType>
155 GLM_FUNC_DECL genType fclamp(genType x, genType minVal, genType maxVal);
156
157 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
158 ///
159 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
160 /// @tparam T Floating-point scalar types
161 /// @tparam Q Value from qualifier enum
162 ///
163 /// @see gtx_extented_min_max
164 template<length_t L, typename T, qualifier Q>
165 GLM_FUNC_DECL vec<L, T, Q> fclamp(vec<L, T, Q> const& x, T minVal, T maxVal);
166
167 /// Returns min(max(x, minVal), maxVal) for each component in x. If one of the two arguments is NaN, the value of the other argument is returned.
168 ///
169 /// @tparam L Integer between 1 and 4 included that qualify the dimension of the vector
170 /// @tparam T Floating-point scalar types
171 /// @tparam Q Value from qualifier enum
172 ///
173 /// @see gtx_extented_min_max
174 template<length_t L, typename T, qualifier Q>
175 GLM_FUNC_DECL vec<L, T, Q> fclamp(vec<L, T, Q> const& x, vec<L, T, Q> const& minVal, vec<L, T, Q> const& maxVal);
176
177
178133 /// @}
179134 }//namespace glm
180135
134134 {
135135 return glm::max(glm::max(x, y), glm::max(z, w));
136136 }
137
138 // fmin
139 # if GLM_HAS_CXX11_STL
140 using std::fmin;
141 # else
142 template<typename genType>
143 GLM_FUNC_QUALIFIER genType fmin(genType x, genType y)
144 {
145 GLM_STATIC_ASSERT(std::numeric_limits<genType>::is_iec559, "'fmin' only accept floating-point input");
146
147 if (isnan(x))
148 return y;
149 if (isnan(y))
150 return x;
151
152 return min(x, y);
153 }
154 # endif
155
156 template<length_t L, typename T, qualifier Q>
157 GLM_FUNC_QUALIFIER vec<L, T, Q> fmin(vec<L, T, Q> const& a, T b)
158 {
159 return detail::functor2<vec, L, T, Q>::call(fmin, a, vec<L, T, Q>(b));
160 }
161
162 template<length_t L, typename T, qualifier Q>
163 GLM_FUNC_QUALIFIER vec<L, T, Q> fmin(vec<L, T, Q> const& a, vec<L, T, Q> const& b)
164 {
165 return detail::functor2<vec, L, T, Q>::call(fmin, a, b);
166 }
167
168 // fmax
169 # if GLM_HAS_CXX11_STL
170 using std::fmax;
171 # else
172 template<typename genType>
173 GLM_FUNC_QUALIFIER genType fmax(genType x, genType y)
174 {
175 GLM_STATIC_ASSERT(std::numeric_limits<genType>::is_iec559, "'fmax' only accept floating-point input");
176
177 if (isnan(x))
178 return y;
179 if (isnan(y))
180 return x;
181
182 return max(x, y);
183 }
184 # endif
185
186 template<length_t L, typename T, qualifier Q>
187 GLM_FUNC_QUALIFIER vec<L, T, Q> fmax(vec<L, T, Q> const& a, T b)
188 {
189 return detail::functor2<vec, L, T, Q>::call(fmax, a, vec<L, T, Q>(b));
190 }
191
192 template<length_t L, typename T, qualifier Q>
193 GLM_FUNC_QUALIFIER vec<L, T, Q> fmax(vec<L, T, Q> const& a, vec<L, T, Q> const& b)
194 {
195 return detail::functor2<vec, L, T, Q>::call(fmax, a, b);
196 }
197
198 // fclamp
199 template<typename genType>
200 GLM_FUNC_QUALIFIER genType fclamp(genType x, genType minVal, genType maxVal)
201 {
202 GLM_STATIC_ASSERT(std::numeric_limits<genType>::is_iec559, "'fclamp' only accept floating-point or integer inputs");
203 return fmin(fmax(x, minVal), maxVal);
204 }
205
206 template<length_t L, typename T, qualifier Q>
207 GLM_FUNC_QUALIFIER vec<L, T, Q> fclamp(vec<L, T, Q> const& x, T minVal, T maxVal)
208 {
209 return fmin(fmax(x, vec<L, T, Q>(minVal)), vec<L, T, Q>(maxVal));
210 }
211
212 template<length_t L, typename T, qualifier Q>
213 GLM_FUNC_QUALIFIER vec<L, T, Q> fclamp(vec<L, T, Q> const& x, vec<L, T, Q> const& minVal, vec<L, T, Q> const& maxVal)
214 {
215 return fmin(fmax(x, minVal), maxVal);
216 }
217137 }//namespace glm
2727 /// @addtogroup gtx_polar_coordinates
2828 /// @{
2929
30 /// Convert Euclidean to Polar coordinates, x is the xz distance, y, the latitude and z the longitude.
30 /// Convert Euclidean to Polar coordinates, x is the latitude, y the longitude and z the xz distance.
3131 ///
3232 /// @see gtx_polar_coordinates
3333 template<typename T, qualifier Q>
1313
1414 // Dependency:
1515 #include "../glm.hpp"
16 #include "../ext/scalar_common.hpp"
17 #include "../ext/vector_common.hpp"
1618 #include "../gtc/vec1.hpp"
1719
1820 #if GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
2830 /// @addtogroup gtx_wrap
2931 /// @{
3032
31 /// Simulate GL_CLAMP OpenGL wrap mode
32 /// @see gtx_wrap extension.
33 template<typename genType>
34 GLM_FUNC_DECL genType clamp(genType const& Texcoord);
35
36 /// Simulate GL_REPEAT OpenGL wrap mode
37 /// @see gtx_wrap extension.
38 template<typename genType>
39 GLM_FUNC_DECL genType repeat(genType const& Texcoord);
40
41 /// Simulate GL_MIRRORED_REPEAT OpenGL wrap mode
42 /// @see gtx_wrap extension.
43 template<typename genType>
44 GLM_FUNC_DECL genType mirrorClamp(genType const& Texcoord);
45
46 /// Simulate GL_MIRROR_REPEAT OpenGL wrap mode
47 /// @see gtx_wrap extension.
48 template<typename genType>
49 GLM_FUNC_DECL genType mirrorRepeat(genType const& Texcoord);
50
5133 /// @}
5234 }// namespace glm
5335
11
22 namespace glm
33 {
4 template<length_t L, typename T, qualifier Q>
5 GLM_FUNC_QUALIFIER vec<L, T, Q> clamp(vec<L, T, Q> const& Texcoord)
6 {
7 return glm::clamp(Texcoord, vec<L, T, Q>(0), vec<L, T, Q>(1));
8 }
94
10 template<typename genType>
11 GLM_FUNC_QUALIFIER genType clamp(genType const& Texcoord)
12 {
13 return clamp(vec<1, genType, defaultp>(Texcoord)).x;
14 }
15
16 template<length_t L, typename T, qualifier Q>
17 GLM_FUNC_QUALIFIER vec<L, T, Q> repeat(vec<L, T, Q> const& Texcoord)
18 {
19 return glm::fract(Texcoord);
20 }
21
22 template<typename genType>
23 GLM_FUNC_QUALIFIER genType repeat(genType const& Texcoord)
24 {
25 return repeat(vec<1, genType, defaultp>(Texcoord)).x;
26 }
27
28 template<length_t L, typename T, qualifier Q>
29 GLM_FUNC_QUALIFIER vec<L, T, Q> mirrorClamp(vec<L, T, Q> const& Texcoord)
30 {
31 return glm::fract(glm::abs(Texcoord));
32 }
33
34 template<typename genType>
35 GLM_FUNC_QUALIFIER genType mirrorClamp(genType const& Texcoord)
36 {
37 return mirrorClamp(vec<1, genType, defaultp>(Texcoord)).x;
38 }
39
40 template<length_t L, typename T, qualifier Q>
41 GLM_FUNC_QUALIFIER vec<L, T, Q> mirrorRepeat(vec<L, T, Q> const& Texcoord)
42 {
43 vec<L, T, Q> const Abs = glm::abs(Texcoord);
44 vec<L, T, Q> const Clamp = glm::mod(glm::floor(Abs), vec<L, T, Q>(2));
45 vec<L, T, Q> const Floor = glm::floor(Abs);
46 vec<L, T, Q> const Rest = Abs - Floor;
47 vec<L, T, Q> const Mirror = Clamp + Rest;
48 return mix(Rest, vec<L, T, Q>(1) - Rest, glm::greaterThanEqual(Mirror, vec<L, T, Q>(1)));
49 }
50
51 template<typename genType>
52 GLM_FUNC_QUALIFIER genType mirrorRepeat(genType const& Texcoord)
53 {
54 return mirrorRepeat(vec<1, genType, defaultp>(Texcoord)).x;
55 }
565 }//namespace glm
88 #include "./ext/vector_double2.hpp"
99 #include "./ext/vector_double2_precision.hpp"
1010 #include "./ext/vector_int2.hpp"
11 #include "./ext/vector_int2_precision.hpp"
11 #include "./ext/vector_int2_sized.hpp"
1212 #include "./ext/vector_uint2.hpp"
13 #include "./ext/vector_uint2_precision.hpp"
13 #include "./ext/vector_uint2_sized.hpp"
88 #include "./ext/vector_double3.hpp"
99 #include "./ext/vector_double3_precision.hpp"
1010 #include "./ext/vector_int3.hpp"
11 #include "./ext/vector_int3_precision.hpp"
11 #include "./ext/vector_int3_sized.hpp"
1212 #include "./ext/vector_uint3.hpp"
13 #include "./ext/vector_uint3_precision.hpp"
13 #include "./ext/vector_uint3_sized.hpp"
88 #include "./ext/vector_double4.hpp"
99 #include "./ext/vector_double4_precision.hpp"
1010 #include "./ext/vector_int4.hpp"
11 #include "./ext/vector_int4_precision.hpp"
11 #include "./ext/vector_int4_sized.hpp"
1212 #include "./ext/vector_uint4.hpp"
13 #include "./ext/vector_uint4_precision.hpp"
13 #include "./ext/vector_uint4_sized.hpp"
1414
1313 + [1.2. Using separated headers](#section1_2)
1414 + [1.3. Using extension headers](#section1_3)
1515 + [1.4. Dependencies](#section1_4)
16 + [1.5. Finding GLM with CMake](#section1_5)
1617 + [2. Preprocessor configurations](#section2)
1718 + [2.1. GLM\_FORCE\_MESSAGES: Platform auto detection and default configuration](#section2_1)
1819 + [2.2. GLM\_FORCE\_PLATFORM\_UNKNOWN: Force GLM to no detect the build platform](#section2_2)
273274
274275 GLM does not depend on external libraries or headers such as `<GL/gl.h>`, [`<GL/glcorearb.h>`](http://www.opengl.org/registry/api/GL/glcorearb.h), `<GLES3/gl3.h>`, `<GL/glu.h>`, or `<windows.h>`.
275276
277 ### <a name="section1_5"></a> 1.5. Finding GLM with CMake
278
279 GLM packages a `glmConfig.cmake` and `glmConfig-version.cmake` in the root of the repository and the release archives. To find GLM with CMake you can pass `-Dglm_DIR=<path to glm root>/cmake/glm/` when running CMake. You can then either add `${GLM_INCLUDE_DIRS}` to your target's include directories, or link against the imported `glm::glm` target.
280
276281 ---
277282 <div style="page-break-after: always;"> </div>
278283
1818 - Any C++11 compiler
1919
2020 For more information about *GLM*, please have a look at the [manual](manual.md) and the [API reference documentation](http://glm.g-truc.net/0.9.8/api/index.html).
21 The source code and the documentation are licensed under both the [Happy Bunny License (Modified MIT) or the MIT License](manual.md#section0).
21 The source code and the documentation are licensed under either the [Happy Bunny License (Modified MIT) or the MIT License](manual.md#section0).
2222
2323 Thanks for contributing to the project by [submitting issues](https://github.com/g-truc/glm/issues) for bug reports and feature requests. Any feedback is welcome at [glm@g-truc.net](mailto://glm@g-truc.net).
2424
5151 | [AppVeyor](https://ci.appveyor.com/project/Groovounet/glm)| Windows 32 and 64 | Visual Studio 2013, Visual Studio 2015, Visual Studio 2017 | [![AppVeyor](https://ci.appveyor.com/api/projects/status/32r7s2skrgm9ubva?svg=true)](https://ci.appveyor.com/project/Groovounet/glm)
5252
5353 ## Release notes
54
55 ### [GLM 0.9.9.8](https://github.com/g-truc/glm/releases/tag/0.9.9.8) - 2020-04-13
56 #### Features:
57 - Added GLM_EXT_vector_intX* and GLM_EXT_vector_uintX* extensions
58 - Added GLM_EXT_matrix_intX* and GLM_EXT_matrix_uintX* extensions
59
60 #### Improvements:
61 - Added clamp, repeat, mirrorClamp and mirrorRepeat function to GLM_EXT_scalar_commond and GLM_EXT_vector_commond extensions with tests
62
63 #### Fixes:
64 - Fixed unnecessary warnings from matrix_projection.inl #995
65 - Fixed quaternion slerp overload which interpolates with extra spins #996
66 - Fixed for glm::length using arch64 #992
67 - Fixed singularity check for quatLookAt #770
5468
5569 ### [GLM 0.9.9.7](https://github.com/g-truc/glm/releases/tag/0.9.9.7) - 2020-01-05
5670 #### Improvements:
0 cmake_minimum_required(VERSION 3.2 FATAL_ERROR)
1 project(test_find_glm)
2
3 find_package(glm REQUIRED)
4
5 add_executable(test_find_glm test_find_glm.cpp)
6 target_link_libraries(test_find_glm glm::glm)
7
0 #include <iostream>
1 #include <glm/glm.hpp>
2 #include <glm/ext.hpp>
3
4 glm::mat4 camera(float Translate, glm::vec2 const& Rotate)
5 {
6 glm::mat4 Projection = glm::perspective(glm::pi<float>() * 0.25f, 4.0f / 3.0f, 0.1f, 100.f);
7 glm::mat4 View = glm::translate(glm::mat4(1.0f), glm::vec3(0.0f, 0.0f, -Translate));
8 View = glm::rotate(View, Rotate.y, glm::vec3(-1.0f, 0.0f, 0.0f));
9 View = glm::rotate(View, Rotate.x, glm::vec3(0.0f, 1.0f, 0.0f));
10 glm::mat4 Model = glm::scale(glm::mat4(1.0f), glm::vec3(0.5f));
11 return Projection * View * Model;
12 }
13
14 int main()
15 {
16 const glm::mat4 m = camera(1.f, glm::vec2(1.f, 0.5f));
17 std::cout << "matrix diagonal: " << m[0][0] << ", "
18 << m[1][1] << ", " << m[2][2] << ", " << m[3][3] << "\n";
19 return 0;
20 }
21
00 glmCreateTestGTC(ext_matrix_relational)
11 glmCreateTestGTC(ext_matrix_transform)
22 glmCreateTestGTC(ext_matrix_common)
3 glmCreateTestGTC(ext_matrix_int2x2_sized)
4 glmCreateTestGTC(ext_matrix_int2x3_sized)
5 glmCreateTestGTC(ext_matrix_int2x4_sized)
6 glmCreateTestGTC(ext_matrix_int3x2_sized)
7 glmCreateTestGTC(ext_matrix_int3x3_sized)
8 glmCreateTestGTC(ext_matrix_int3x4_sized)
9 glmCreateTestGTC(ext_matrix_int4x2_sized)
10 glmCreateTestGTC(ext_matrix_int4x3_sized)
11 glmCreateTestGTC(ext_matrix_int4x4_sized)
12 glmCreateTestGTC(ext_matrix_uint2x2_sized)
13 glmCreateTestGTC(ext_matrix_uint2x3_sized)
14 glmCreateTestGTC(ext_matrix_uint2x4_sized)
15 glmCreateTestGTC(ext_matrix_uint3x2_sized)
16 glmCreateTestGTC(ext_matrix_uint3x3_sized)
17 glmCreateTestGTC(ext_matrix_uint3x4_sized)
18 glmCreateTestGTC(ext_matrix_uint4x2_sized)
19 glmCreateTestGTC(ext_matrix_uint4x3_sized)
20 glmCreateTestGTC(ext_matrix_uint4x4_sized)
321 glmCreateTestGTC(ext_quaternion_common)
422 glmCreateTestGTC(ext_quaternion_exponential)
523 glmCreateTestGTC(ext_quaternion_geometric)
1836 glmCreateTestGTC(ext_vector_bool1)
1937 glmCreateTestGTC(ext_vector_common)
2038 glmCreateTestGTC(ext_vector_iec559)
39 glmCreateTestGTC(ext_vector_int1_sized)
40 glmCreateTestGTC(ext_vector_int2_sized)
41 glmCreateTestGTC(ext_vector_int3_sized)
42 glmCreateTestGTC(ext_vector_int4_sized)
2143 glmCreateTestGTC(ext_vector_integer)
2244 glmCreateTestGTC(ext_vector_integer_sized)
45 glmCreateTestGTC(ext_vector_uint1_sized)
46 glmCreateTestGTC(ext_vector_uint2_sized)
47 glmCreateTestGTC(ext_vector_uint3_sized)
48 glmCreateTestGTC(ext_vector_uint4_sized)
2349 glmCreateTestGTC(ext_vector_relational)
2450 glmCreateTestGTC(ext_vector_ulp)
2551
0 #include <glm/ext/matrix_int2x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat2x2) == 4, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat2x2) == 8, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat2x2) == 16, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat2x2) == 32, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat2x2) < sizeof(glm::i16mat2x2) ? 0 : 1;
14 Error += sizeof(glm::i16mat2x2) < sizeof(glm::i32mat2x2) ? 0 : 1;
15 Error += sizeof(glm::i32mat2x2) < sizeof(glm::i64mat2x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int2x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat2x3) == 6, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat2x3) == 12, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat2x3) == 24, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat2x3) == 48, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat2x3) < sizeof(glm::i16mat2x3) ? 0 : 1;
14 Error += sizeof(glm::i16mat2x3) < sizeof(glm::i32mat2x3) ? 0 : 1;
15 Error += sizeof(glm::i32mat2x3) < sizeof(glm::i64mat2x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int2x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat2x4) == 8, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat2x4) == 16, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat2x4) == 32, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat2x4) == 64, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat2x4) < sizeof(glm::i16mat2x4) ? 0 : 1;
14 Error += sizeof(glm::i16mat2x4) < sizeof(glm::i32mat2x4) ? 0 : 1;
15 Error += sizeof(glm::i32mat2x4) < sizeof(glm::i64mat2x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int3x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat3x2) == 6, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat3x2) == 12, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat3x2) == 24, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat3x2) == 48, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat3x2) < sizeof(glm::i16mat3x2) ? 0 : 1;
14 Error += sizeof(glm::i16mat3x2) < sizeof(glm::i32mat3x2) ? 0 : 1;
15 Error += sizeof(glm::i32mat3x2) < sizeof(glm::i64mat3x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int3x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat3x3) == 9, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat3x3) == 18, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat3x3) == 36, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat3x3) == 72, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat3x3) < sizeof(glm::i16mat3x3) ? 0 : 1;
14 Error += sizeof(glm::i16mat3x3) < sizeof(glm::i32mat3x3) ? 0 : 1;
15 Error += sizeof(glm::i32mat3x3) < sizeof(glm::i64mat3x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int3x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat3x4) == 12, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat3x4) == 24, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat3x4) == 48, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat3x4) == 96, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat3x4) < sizeof(glm::i16mat3x4) ? 0 : 1;
14 Error += sizeof(glm::i16mat3x4) < sizeof(glm::i32mat3x4) ? 0 : 1;
15 Error += sizeof(glm::i32mat3x4) < sizeof(glm::i64mat3x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int4x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat4x2) == 8, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat4x2) == 16, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat4x2) == 32, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat4x2) == 64, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat4x2) < sizeof(glm::i16mat4x2) ? 0 : 1;
14 Error += sizeof(glm::i16mat4x2) < sizeof(glm::i32mat4x2) ? 0 : 1;
15 Error += sizeof(glm::i32mat4x2) < sizeof(glm::i64mat4x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int4x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat4x3) == 12, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat4x3) == 24, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat4x3) == 48, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat4x3) == 96, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat4x3) < sizeof(glm::i16mat4x3) ? 0 : 1;
14 Error += sizeof(glm::i16mat4x3) < sizeof(glm::i32mat4x3) ? 0 : 1;
15 Error += sizeof(glm::i32mat4x3) < sizeof(glm::i64mat4x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_int4x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8mat4x4) == 16, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16mat4x4) == 32, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32mat4x4) == 64, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64mat4x4) == 128, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8mat4x4) < sizeof(glm::i16mat4x4) ? 0 : 1;
14 Error += sizeof(glm::i16mat4x4) < sizeof(glm::i32mat4x4) ? 0 : 1;
15 Error += sizeof(glm::i32mat4x4) < sizeof(glm::i64mat4x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint2x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat2x2) == 4, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat2x2) == 8, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat2x2) == 16, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat2x2) == 32, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat2x2) < sizeof(glm::u16mat2x2) ? 0 : 1;
14 Error += sizeof(glm::u16mat2x2) < sizeof(glm::u32mat2x2) ? 0 : 1;
15 Error += sizeof(glm::u32mat2x2) < sizeof(glm::u64mat2x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint2x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat2x3) == 6, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat2x3) == 12, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat2x3) == 24, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat2x3) == 48, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat2x3) < sizeof(glm::u16mat2x3) ? 0 : 1;
14 Error += sizeof(glm::u16mat2x3) < sizeof(glm::u32mat2x3) ? 0 : 1;
15 Error += sizeof(glm::u32mat2x3) < sizeof(glm::u64mat2x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint2x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat2x4) == 8, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat2x4) == 16, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat2x4) == 32, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat2x4) == 64, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat2x4) < sizeof(glm::u16mat2x4) ? 0 : 1;
14 Error += sizeof(glm::u16mat2x4) < sizeof(glm::u32mat2x4) ? 0 : 1;
15 Error += sizeof(glm::u32mat2x4) < sizeof(glm::u64mat2x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint3x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat3x2) == 6, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat3x2) == 12, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat3x2) == 24, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat3x2) == 48, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat3x2) < sizeof(glm::u16mat3x2) ? 0 : 1;
14 Error += sizeof(glm::u16mat3x2) < sizeof(glm::u32mat3x2) ? 0 : 1;
15 Error += sizeof(glm::u32mat3x2) < sizeof(glm::u64mat3x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint3x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat3x3) == 9, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat3x3) == 18, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat3x3) == 36, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat3x3) == 72, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat3x3) < sizeof(glm::u16mat3x3) ? 0 : 1;
14 Error += sizeof(glm::u16mat3x3) < sizeof(glm::u32mat3x3) ? 0 : 1;
15 Error += sizeof(glm::u32mat3x3) < sizeof(glm::u64mat3x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint3x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat3x4) == 12, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat3x4) == 24, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat3x4) == 48, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat3x4) == 96, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat3x4) < sizeof(glm::u16mat3x4) ? 0 : 1;
14 Error += sizeof(glm::u16mat3x4) < sizeof(glm::u32mat3x4) ? 0 : 1;
15 Error += sizeof(glm::u32mat3x4) < sizeof(glm::u64mat3x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint4x2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat4x2) == 8, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat4x2) == 16, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat4x2) == 32, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat4x2) == 64, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat4x2) < sizeof(glm::u16mat4x2) ? 0 : 1;
14 Error += sizeof(glm::u16mat4x2) < sizeof(glm::u32mat4x2) ? 0 : 1;
15 Error += sizeof(glm::u32mat4x2) < sizeof(glm::u64mat4x2) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint4x3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat4x3) == 12, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat4x3) == 24, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat4x3) == 48, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat4x3) == 96, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat4x3) < sizeof(glm::u16mat4x3) ? 0 : 1;
14 Error += sizeof(glm::u16mat4x3) < sizeof(glm::u32mat4x3) ? 0 : 1;
15 Error += sizeof(glm::u32mat4x3) < sizeof(glm::u64mat4x3) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
0 #include <glm/ext/matrix_uint4x4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8mat4x4) == 16, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16mat4x4) == 32, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32mat4x4) == 64, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64mat4x4) == 128, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_comp()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8mat4x4) < sizeof(glm::u16mat4x4) ? 0 : 1;
14 Error += sizeof(glm::u16mat4x4) < sizeof(glm::u32mat4x4) ? 0 : 1;
15 Error += sizeof(glm::u32mat4x4) < sizeof(glm::u64mat4x4) ? 0 : 1;
16
17 return Error;
18 }
19
20 int main()
21 {
22 int Error = 0;
23
24 Error += test_comp();
25
26 return Error;
27 }
182182 return Error;
183183 }
184184
185 static int test_clamp()
186 {
187 int Error = 0;
188
189 float A = glm::clamp(0.5f);
190 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
191
192 float B = glm::clamp(0.0f);
193 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
194
195 float C = glm::clamp(1.0f);
196 Error += glm::equal(C, 1.0f, 0.00001f) ? 0 : 1;
197
198 float D = glm::clamp(-0.5f);
199 Error += glm::equal(D, 0.0f, 0.00001f) ? 0 : 1;
200
201 float E = glm::clamp(1.5f);
202 Error += glm::equal(E, 1.0f, 0.00001f) ? 0 : 1;
203
204 return Error;
205 }
206
207 static int test_repeat()
208 {
209 int Error = 0;
210
211 float A = glm::repeat(0.5f);
212 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
213
214 float B = glm::repeat(0.0f);
215 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
216
217 float C = glm::repeat(1.0f);
218 Error += glm::equal(C, 0.0f, 0.00001f) ? 0 : 1;
219
220 float D = glm::repeat(-0.5f);
221 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
222
223 float E = glm::repeat(1.5f);
224 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
225
226 float F = glm::repeat(0.9f);
227 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
228
229 return Error;
230 }
231
232 static int test_mirrorClamp()
233 {
234 int Error = 0;
235
236 float A = glm::mirrorClamp(0.5f);
237 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
238
239 float B = glm::mirrorClamp(0.0f);
240 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
241
242 float C = glm::mirrorClamp(1.1f);
243 Error += glm::equal(C, 0.1f, 0.00001f) ? 0 : 1;
244
245 float D = glm::mirrorClamp(-0.5f);
246 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
247
248 float E = glm::mirrorClamp(1.5f);
249 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
250
251 float F = glm::mirrorClamp(0.9f);
252 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
253
254 float G = glm::mirrorClamp(3.1f);
255 Error += glm::equal(G, 0.1f, 0.00001f) ? 0 : 1;
256
257 float H = glm::mirrorClamp(-3.1f);
258 Error += glm::equal(H, 0.1f, 0.00001f) ? 0 : 1;
259
260 float I = glm::mirrorClamp(-0.9f);
261 Error += glm::equal(I, 0.9f, 0.00001f) ? 0 : 1;
262
263 return Error;
264 }
265
266 static int test_mirrorRepeat()
267 {
268 int Error = 0;
269
270 float A = glm::mirrorRepeat(0.5f);
271 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
272
273 float B = glm::mirrorRepeat(0.0f);
274 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
275
276 float C = glm::mirrorRepeat(1.0f);
277 Error += glm::equal(C, 1.0f, 0.00001f) ? 0 : 1;
278
279 float D = glm::mirrorRepeat(-0.5f);
280 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
281
282 float E = glm::mirrorRepeat(1.5f);
283 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
284
285 float F = glm::mirrorRepeat(0.9f);
286 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
287
288 float G = glm::mirrorRepeat(3.0f);
289 Error += glm::equal(G, 1.0f, 0.00001f) ? 0 : 1;
290
291 float H = glm::mirrorRepeat(-3.0f);
292 Error += glm::equal(H, 1.0f, 0.00001f) ? 0 : 1;
293
294 float I = glm::mirrorRepeat(-1.0f);
295 Error += glm::equal(I, 1.0f, 0.00001f) ? 0 : 1;
296
297 return Error;
298 }
299
185300 int main()
186301 {
187302 int Error = 0;
202317 Error += test_fmax<float>();
203318 Error += test_fmax<double>();
204319
205 return Error;
206 }
320 Error += test_clamp();
321 Error += test_repeat();
322 Error += test_mirrorClamp();
323 Error += test_mirrorRepeat();
324
325 return Error;
326 }
0 #include <glm/ext/scalar_packing.hpp>
1 #include <glm/ext/scalar_relational.hpp>
2
3 int test_packUnorm()
4 {
5 int Error = 0;
6
7
8 return Error;
9 }
10
11 int test_packSnorm()
12 {
13 int Error = 0;
14
15
16 return Error;
17 }
18
19 int main()
20 {
21 int Error = 0;
22
23 Error += test_packUnorm();
24 Error += test_packSnorm();
25
26 return Error;
27 }
00 #include <glm/ext/vector_common.hpp>
1
12 #include <glm/ext/vector_bool1.hpp>
23 #include <glm/ext/vector_bool1_precision.hpp>
34 #include <glm/ext/vector_bool2.hpp>
225226 return Error;
226227 }
227228
229 static int test_clamp()
230 {
231 int Error = 0;
232
233 glm::vec2 K = glm::clamp(glm::vec2(0.5f));
234 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
235
236 glm::vec3 L = glm::clamp(glm::vec3(0.5f));
237 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
238
239 glm::vec4 M = glm::clamp(glm::vec4(0.5f));
240 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
241
242 glm::vec1 N = glm::clamp(glm::vec1(0.5f));
243 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
244
245 return Error;
246 }
247
248 static int test_repeat()
249 {
250 int Error = 0;
251
252 glm::vec2 K = glm::repeat(glm::vec2(0.5f));
253 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
254
255 glm::vec3 L = glm::repeat(glm::vec3(0.5f));
256 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
257
258 glm::vec4 M = glm::repeat(glm::vec4(0.5f));
259 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
260
261 glm::vec1 N = glm::repeat(glm::vec1(0.5f));
262 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
263
264 return Error;
265 }
266
267 static int test_mirrorClamp()
268 {
269 int Error = 0;
270
271 glm::vec2 K = glm::mirrorClamp(glm::vec2(0.5f));
272 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
273
274 glm::vec3 L = glm::mirrorClamp(glm::vec3(0.5f));
275 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
276
277 glm::vec4 M = glm::mirrorClamp(glm::vec4(0.5f));
278 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
279
280 glm::vec1 N = glm::mirrorClamp(glm::vec1(0.5f));
281 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
282
283 return Error;
284 }
285
286 static int test_mirrorRepeat()
287 {
288 int Error = 0;
289
290 glm::vec2 K = glm::mirrorRepeat(glm::vec2(0.5f));
291 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
292
293 glm::vec3 L = glm::mirrorRepeat(glm::vec3(0.5f));
294 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
295
296 glm::vec4 M = glm::mirrorRepeat(glm::vec4(0.5f));
297 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
298
299 glm::vec1 N = glm::mirrorRepeat(glm::vec1(0.5f));
300 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
301
302 return Error;
303 }
304
228305 int main()
229306 {
230307 int Error = 0;
245322 Error += test_fmax<glm::vec3>();
246323 Error += test_fmax<glm::vec2>();
247324
248 return Error;
249 }
325 Error += test_clamp();
326 Error += test_repeat();
327 Error += test_mirrorClamp();
328 Error += test_mirrorRepeat();
329
330 return Error;
331 }
0 #include <glm/ext/vector_int1_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8vec1) == 1, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16vec1) == 2, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32vec1) == 4, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64vec1) == 8, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8vec1) == 1 ? 0 : 1;
14 Error += sizeof(glm::i16vec1) == 2 ? 0 : 1;
15 Error += sizeof(glm::i32vec1) == 4 ? 0 : 1;
16 Error += sizeof(glm::i64vec1) == 8 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::i8vec1) < sizeof(glm::i16vec1) ? 0 : 1;
26 Error += sizeof(glm::i16vec1) < sizeof(glm::i32vec1) ? 0 : 1;
27 Error += sizeof(glm::i32vec1) < sizeof(glm::i64vec1) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_int2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8vec2) == 2, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16vec2) == 4, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32vec2) == 8, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64vec2) == 16, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8vec2) == 2 ? 0 : 1;
14 Error += sizeof(glm::i16vec2) == 4 ? 0 : 1;
15 Error += sizeof(glm::i32vec2) == 8 ? 0 : 1;
16 Error += sizeof(glm::i64vec2) == 16 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::i8vec2) < sizeof(glm::i16vec2) ? 0 : 1;
26 Error += sizeof(glm::i16vec2) < sizeof(glm::i32vec2) ? 0 : 1;
27 Error += sizeof(glm::i32vec2) < sizeof(glm::i64vec2) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_int3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8vec3) == 3, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16vec3) == 6, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32vec3) == 12, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64vec3) == 24, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8vec3) == 3 ? 0 : 1;
14 Error += sizeof(glm::i16vec3) == 6 ? 0 : 1;
15 Error += sizeof(glm::i32vec3) == 12 ? 0 : 1;
16 Error += sizeof(glm::i64vec3) == 24 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::i8vec3) < sizeof(glm::i16vec3) ? 0 : 1;
26 Error += sizeof(glm::i16vec3) < sizeof(glm::i32vec3) ? 0 : 1;
27 Error += sizeof(glm::i32vec3) < sizeof(glm::i64vec3) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_int4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::i8vec4) == 4, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::i16vec4) == 8, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::i32vec4) == 16, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::i64vec4) == 32, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::i8vec4) == 4 ? 0 : 1;
14 Error += sizeof(glm::i16vec4) == 8 ? 0 : 1;
15 Error += sizeof(glm::i32vec4) == 16 ? 0 : 1;
16 Error += sizeof(glm::i64vec4) == 32 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::i8vec4) < sizeof(glm::i16vec4) ? 0 : 1;
26 Error += sizeof(glm::i16vec4) < sizeof(glm::i32vec4) ? 0 : 1;
27 Error += sizeof(glm::i32vec4) < sizeof(glm::i64vec4) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
00 #include <glm/ext/vector_integer.hpp>
11 #include <glm/ext/vector_int1.hpp>
2 #include <glm/ext/vector_int1_precision.hpp>
2 #include <glm/ext/vector_int1_sized.hpp>
33 #include <glm/ext/vector_uint1.hpp>
4 #include <glm/ext/vector_uint1_precision.hpp>
4 #include <glm/ext/vector_uint1_sized.hpp>
55
66 template <typename genType>
77 static int test_operators()
152152 int Error = 0;
153153
154154 Error += test_operators<glm::ivec1>();
155 Error += test_operators<glm::lowp_ivec1>();
156 Error += test_operators<glm::mediump_ivec1>();
157 Error += test_operators<glm::highp_ivec1>();
155 Error += test_operators<glm::i8vec1>();
156 Error += test_operators<glm::i16vec1>();
157 Error += test_operators<glm::i32vec1>();
158 Error += test_operators<glm::i64vec1>();
158159
159160 Error += test_ctor<glm::ivec1>();
160 Error += test_ctor<glm::lowp_ivec1>();
161 Error += test_ctor<glm::mediump_ivec1>();
162 Error += test_ctor<glm::highp_ivec1>();
161 Error += test_ctor<glm::i8vec1>();
162 Error += test_ctor<glm::i16vec1>();
163 Error += test_ctor<glm::i32vec1>();
164 Error += test_ctor<glm::i64vec1>();
163165
164166 Error += test_size<glm::ivec1>();
165 Error += test_size<glm::lowp_ivec1>();
166 Error += test_size<glm::mediump_ivec1>();
167 Error += test_size<glm::highp_ivec1>();
167 Error += test_size<glm::i8vec1>();
168 Error += test_size<glm::i16vec1>();
169 Error += test_size<glm::i32vec1>();
170 Error += test_size<glm::i64vec1>();
168171
169172 Error += test_relational<glm::ivec1>();
170 Error += test_relational<glm::lowp_ivec1>();
171 Error += test_relational<glm::mediump_ivec1>();
172 Error += test_relational<glm::highp_ivec1>();
173 Error += test_relational<glm::i8vec1>();
174 Error += test_relational<glm::i16vec1>();
175 Error += test_relational<glm::i32vec1>();
176 Error += test_relational<glm::i64vec1>();
173177
174178 Error += test_constexpr<glm::ivec1>();
175 Error += test_constexpr<glm::lowp_ivec1>();
176 Error += test_constexpr<glm::mediump_ivec1>();
177 Error += test_constexpr<glm::highp_ivec1>();
179 Error += test_constexpr<glm::i8vec1>();
180 Error += test_constexpr<glm::i16vec1>();
181 Error += test_constexpr<glm::i32vec1>();
182 Error += test_constexpr<glm::i64vec1>();
178183
179184 Error += test_operators<glm::uvec1>();
180 Error += test_operators<glm::lowp_uvec1>();
181 Error += test_operators<glm::mediump_uvec1>();
182 Error += test_operators<glm::highp_uvec1>();
185 Error += test_operators<glm::u8vec1>();
186 Error += test_operators<glm::u16vec1>();
187 Error += test_operators<glm::u32vec1>();
188 Error += test_operators<glm::u64vec1>();
183189
184190 Error += test_ctor<glm::uvec1>();
185 Error += test_ctor<glm::lowp_uvec1>();
186 Error += test_ctor<glm::mediump_uvec1>();
187 Error += test_ctor<glm::highp_uvec1>();
191 Error += test_ctor<glm::u8vec1>();
192 Error += test_ctor<glm::u16vec1>();
193 Error += test_ctor<glm::u32vec1>();
194 Error += test_ctor<glm::u64vec1>();
188195
189196 Error += test_size<glm::uvec1>();
190 Error += test_size<glm::lowp_uvec1>();
191 Error += test_size<glm::mediump_uvec1>();
192 Error += test_size<glm::highp_uvec1>();
197 Error += test_size<glm::u8vec1>();
198 Error += test_size<glm::u16vec1>();
199 Error += test_size<glm::u32vec1>();
200 Error += test_size<glm::u64vec1>();
193201
194202 Error += test_relational<glm::uvec1>();
195 Error += test_relational<glm::lowp_uvec1>();
196 Error += test_relational<glm::mediump_uvec1>();
197 Error += test_relational<glm::highp_uvec1>();
203 Error += test_relational<glm::u8vec1>();
204 Error += test_relational<glm::u16vec1>();
205 Error += test_relational<glm::u32vec1>();
206 Error += test_relational<glm::u64vec1>();
198207
199208 Error += test_constexpr<glm::uvec1>();
200 Error += test_constexpr<glm::lowp_uvec1>();
201 Error += test_constexpr<glm::mediump_uvec1>();
202 Error += test_constexpr<glm::highp_uvec1>();
203
204 return Error;
205 }
209 Error += test_constexpr<glm::u8vec1>();
210 Error += test_constexpr<glm::u16vec1>();
211 Error += test_constexpr<glm::u32vec1>();
212 Error += test_constexpr<glm::u64vec1>();
213
214 return Error;
215 }
0 #include <glm/ext/vector_packing.hpp>
1 #include <glm/ext/vector_relational.hpp>
2 #include <glm/ext/vector_uint2_sized.hpp>
3 #include <glm/ext/vector_int2_sized.hpp>
4 #include <glm/gtc/packing.hpp>
5 #include <glm/vec2.hpp>
6 #include <vector>
7
8 int test_packUnorm()
9 {
10 int Error = 0;
11
12 std::vector<glm::vec2> A;
13 A.push_back(glm::vec2(1.0f, 0.7f));
14 A.push_back(glm::vec2(0.5f, 0.1f));
15
16 for (std::size_t i = 0; i < A.size(); ++i)
17 {
18 glm::vec2 B(A[i]);
19 glm::u16vec2 C = glm::packUnorm<glm::uint16>(B);
20 glm::vec2 D = glm::unpackUnorm<float>(C);
21 Error += glm::all(glm::equal(B, D, 1.0f / 255.f)) ? 0 : 1;
22 assert(!Error);
23 }
24
25 return Error;
26 }
27
28 int test_packSnorm()
29 {
30 int Error = 0;
31
32 std::vector<glm::vec2> A;
33 A.push_back(glm::vec2(1.0f, 0.0f));
34 A.push_back(glm::vec2(-0.5f, -0.7f));
35 A.push_back(glm::vec2(-0.1f, 0.1f));
36
37 for (std::size_t i = 0; i < A.size(); ++i)
38 {
39 glm::vec2 B(A[i]);
40 glm::i16vec2 C = glm::packSnorm<glm::int16>(B);
41 glm::vec2 D = glm::unpackSnorm<float>(C);
42 Error += glm::all(glm::equal(B, D, 1.0f / 32767.0f * 2.0f)) ? 0 : 1;
43 assert(!Error);
44 }
45
46 return Error;
47 }
48
49 int main()
50 {
51 int Error = 0;
52
53 Error += test_packUnorm();
54 Error += test_packSnorm();
55
56 return Error;
57 }
0 #include <glm/ext/vector_uint1_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8vec1) == 1 ? 0 : 1;
14 Error += sizeof(glm::u16vec1) == 2 ? 0 : 1;
15 Error += sizeof(glm::u32vec1) == 4 ? 0 : 1;
16 Error += sizeof(glm::u64vec1) == 8 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::u8vec1) < sizeof(glm::u16vec1) ? 0 : 1;
26 Error += sizeof(glm::u16vec1) < sizeof(glm::u32vec1) ? 0 : 1;
27 Error += sizeof(glm::u32vec1) < sizeof(glm::u64vec1) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_uint2_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8vec2) == 2, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16vec2) == 4, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32vec2) == 8, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64vec2) == 16, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8vec2) == 2 ? 0 : 1;
14 Error += sizeof(glm::u16vec2) == 4 ? 0 : 1;
15 Error += sizeof(glm::u32vec2) == 8 ? 0 : 1;
16 Error += sizeof(glm::u64vec2) == 16 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::u8vec2) < sizeof(glm::u16vec2) ? 0 : 1;
26 Error += sizeof(glm::u16vec2) < sizeof(glm::u32vec2) ? 0 : 1;
27 Error += sizeof(glm::u32vec2) < sizeof(glm::u64vec2) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_uint3_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8vec3) == 3, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16vec3) == 6, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32vec3) == 12, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64vec3) == 24, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8vec3) == 3 ? 0 : 1;
14 Error += sizeof(glm::u16vec3) == 6 ? 0 : 1;
15 Error += sizeof(glm::u32vec3) == 12 ? 0 : 1;
16 Error += sizeof(glm::u64vec3) == 24 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::u8vec3) < sizeof(glm::u16vec3) ? 0 : 1;
26 Error += sizeof(glm::u16vec3) < sizeof(glm::u32vec3) ? 0 : 1;
27 Error += sizeof(glm::u32vec3) < sizeof(glm::u64vec3) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
0 #include <glm/ext/vector_uint4_sized.hpp>
1
2 #if GLM_HAS_STATIC_ASSERT
3 static_assert(sizeof(glm::u8vec4) == 4, "int8 size isn't 1 byte on this platform");
4 static_assert(sizeof(glm::u16vec4) == 8, "int16 size isn't 2 bytes on this platform");
5 static_assert(sizeof(glm::u32vec4) == 16, "int32 size isn't 4 bytes on this platform");
6 static_assert(sizeof(glm::u64vec4) == 32, "int64 size isn't 8 bytes on this platform");
7 #endif
8
9 static int test_size()
10 {
11 int Error = 0;
12
13 Error += sizeof(glm::u8vec4) == 4 ? 0 : 1;
14 Error += sizeof(glm::u16vec4) == 8 ? 0 : 1;
15 Error += sizeof(glm::u32vec4) == 16 ? 0 : 1;
16 Error += sizeof(glm::u64vec4) == 32 ? 0 : 1;
17
18 return Error;
19 }
20
21 static int test_comp()
22 {
23 int Error = 0;
24
25 Error += sizeof(glm::u8vec4) < sizeof(glm::u16vec4) ? 0 : 1;
26 Error += sizeof(glm::u16vec4) < sizeof(glm::u32vec4) ? 0 : 1;
27 Error += sizeof(glm::u32vec4) < sizeof(glm::u64vec4) ? 0 : 1;
28
29 return Error;
30 }
31
32 int main()
33 {
34 int Error = 0;
35
36 Error += test_size();
37 Error += test_comp();
38
39 return Error;
40 }
193193 return Error;
194194 }
195195
196 int test_quat_slerp_spins()
197 {
198 int Error = 0;
199
200 float const Epsilon = 0.0001f;//glm::epsilon<float>();
201
202 float sqrt2 = std::sqrt(2.0f) / 2.0f;
203 glm::quat id(static_cast<float>(1), static_cast<float>(0), static_cast<float>(0), static_cast<float>(0));
204 glm::quat Y90rot(sqrt2, 0.0f, sqrt2, 0.0f);
205 glm::quat Y180rot(0.0f, 0.0f, 1.0f, 0.0f);
206
207 // Testing a == 0, k == 1
208 // Must be id
209 glm::quat id2 = glm::slerp(id, id, 1.0f, 1);
210 Error += glm::all(glm::equal(id, id2, Epsilon)) ? 0 : 1;
211
212 // Testing a == 1, k == 2
213 // Must be id
214 glm::quat id3 = glm::slerp(id, id, 1.0f, 2);
215 Error += glm::all(glm::equal(id, id3, Epsilon)) ? 0 : 1;
216
217 // Testing a == 1, k == 1
218 // Must be 90° rotation on Y : 0 0.7 0 0.7
219 // Negative quaternion is representing same orientation
220 glm::quat Y90rot2 = glm::slerp(id, Y90rot, 1.0f, 1);
221 Error += glm::all(glm::equal(Y90rot, -Y90rot2, Epsilon)) ? 0 : 1;
222
223 // Testing a == 1, k == 2
224 // Must be id
225 glm::quat Y90rot3 = glm::slerp(id, Y90rot, 8.0f / 9.0f, 2);
226 Error += glm::all(glm::equal(id, Y90rot3, Epsilon)) ? 0 : 1;
227
228 // Testing a == 1, k == 1
229 // Must be 90° rotation on Y : 0 0.7 0 0.7
230 glm::quat Y90rot4 = glm::slerp(id, Y90rot, 0.2f, 1);
231 Error += glm::all(glm::equal(Y90rot, Y90rot4, Epsilon)) ? 0 : 1;
232
233 // Testing reverse case
234 // Must be 45° rotation on Y : 0 0.38 0 0.92
235 // Negative quaternion is representing same orientation
236 glm::quat Ym45rot2 = glm::slerp(Y90rot, id, 0.9f, 1);
237 glm::quat Ym45rot3 = glm::slerp(Y90rot, id, 0.5f);
238 Error += glm::all(glm::equal(-Ym45rot2, Ym45rot3, Epsilon)) ? 0 : 1;
239
240 // Testing against full circle around the sphere instead of shortest path
241 // Must be 45° rotation on Y
242 // certainly not a 135° rotation
243 glm::quat Y45rot3 = glm::slerp(id, -Y90rot, 0.5f, 0);
244 float Y45angle3 = glm::angle(Y45rot3);
245 Error += glm::equal(Y45angle3, glm::pi<float>() * 0.25f, Epsilon) ? 0 : 1;
246 Error += glm::all(glm::equal(Ym45rot3, Y45rot3, Epsilon)) ? 0 : 1;
247
248 // Same, but inverted
249 // Must also be 45° rotation on Y : 0 0.38 0 0.92
250 // -0 -0.38 -0 -0.92 is ok too
251 glm::quat Y45rot4 = glm::slerp(-Y90rot, id, 0.5f, 0);
252 Error += glm::all(glm::equal(Ym45rot2, Y45rot4, Epsilon)) ? 0 : 1;
253
254 // Testing q1 = q2 k == 2
255 // Must be 90° rotation on Y : 0 0.7 0 0.7
256 glm::quat Y90rot5 = glm::slerp(Y90rot, Y90rot, 0.5f, 2);
257 Error += glm::all(glm::equal(Y90rot, Y90rot5, Epsilon)) ? 0 : 1;
258
259 // Testing 180° rotation
260 // Must be 90° rotation on almost any axis that is on the XZ plane
261 glm::quat XZ90rot = glm::slerp(id, -Y90rot, 0.5f, 1);
262 float XZ90angle = glm::angle(XZ90rot); // Must be PI/4 = 0.78;
263 Error += glm::equal(XZ90angle, glm::pi<float>() * 1.25f, Epsilon) ? 0 : 1;
264
265 // Testing rotation over long arc
266 // Distance from id to 90° is 270°, so 2/3 of it should be 180°
267 // Negative quaternion is representing same orientation
268 glm::quat Neg90rot = glm::slerp(id, Y90rot, 2.0f / 3.0f, -1);
269 Error += glm::all(glm::equal(Y180rot, -Neg90rot, Epsilon)) ? 0 : 1;
270
271 return Error;
272 }
273
196274 static int test_quat_mul_vec()
197275 {
198276 int Error(0);
259337 Error += test_quat_normalize();
260338 Error += test_quat_euler();
261339 Error += test_quat_slerp();
340 Error += test_quat_slerp_spins();
262341 Error += test_identity();
263342
264343 return Error;
44 #include <vector>
55 #if GLM_HAS_OPENMP
66 # include <omp.h>
7 #endif
8
9 #if GLM_HAS_STATIC_ASSERT
10 static_assert(sizeof(glm::lowp_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
11 static_assert(sizeof(glm::mediump_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
12 static_assert(sizeof(glm::highp_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
13
14 static_assert(sizeof(glm::lowp_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
15 static_assert(sizeof(glm::mediump_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
16 static_assert(sizeof(glm::highp_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
17
18 static_assert(sizeof(glm::lowp_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
19 static_assert(sizeof(glm::mediump_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
20 static_assert(sizeof(glm::highp_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
21
22 static_assert(sizeof(glm::lowp_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
23 static_assert(sizeof(glm::mediump_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
24 static_assert(sizeof(glm::highp_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
25
26
27 static_assert(sizeof(glm::lowp_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
28 static_assert(sizeof(glm::mediump_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
29 static_assert(sizeof(glm::highp_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
30
31 static_assert(sizeof(glm::lowp_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
32 static_assert(sizeof(glm::mediump_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
33 static_assert(sizeof(glm::highp_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
34
35 static_assert(sizeof(glm::lowp_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
36 static_assert(sizeof(glm::mediump_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
37 static_assert(sizeof(glm::highp_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
38
39 static_assert(sizeof(glm::lowp_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
40 static_assert(sizeof(glm::mediump_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
41 static_assert(sizeof(glm::highp_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
42
43
44 static_assert(sizeof(glm::lowp_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
45 static_assert(sizeof(glm::mediump_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
46 static_assert(sizeof(glm::highp_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
47
48 static_assert(sizeof(glm::lowp_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
49 static_assert(sizeof(glm::mediump_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
50 static_assert(sizeof(glm::highp_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
51
52 static_assert(sizeof(glm::lowp_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
53 static_assert(sizeof(glm::mediump_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
54 static_assert(sizeof(glm::highp_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
55
56 static_assert(sizeof(glm::lowp_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
57 static_assert(sizeof(glm::mediump_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
58 static_assert(sizeof(glm::highp_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
59
60
61 static_assert(sizeof(glm::lowp_u8vec4) == 4, "int8 size isn't 1 byte on this platform");
62 static_assert(sizeof(glm::mediump_u8vec4) == 4, "int8 size isn't 1 byte on this platform");
63 static_assert(sizeof(glm::highp_u8vec4) == 4, "int8 size isn't 1 byte on this platform");
64
65 static_assert(sizeof(glm::lowp_u16vec4) == 8, "int16 size isn't 2 bytes on this platform");
66 static_assert(sizeof(glm::mediump_u16vec4) == 8, "int16 size isn't 2 bytes on this platform");
67 static_assert(sizeof(glm::highp_u16vec4) == 8, "int16 size isn't 2 bytes on this platform");
68
69 static_assert(sizeof(glm::lowp_u32vec4) == 16, "int32 size isn't 4 bytes on this platform");
70 static_assert(sizeof(glm::mediump_u32vec4) == 16, "int32 size isn't 4 bytes on this platform");
71 static_assert(sizeof(glm::highp_u32vec4) == 16, "int32 size isn't 4 bytes on this platform");
72
73 static_assert(sizeof(glm::lowp_u64vec4) == 32, "int64 size isn't 8 bytes on this platform");
74 static_assert(sizeof(glm::mediump_u64vec4) == 32, "int64 size isn't 8 bytes on this platform");
75 static_assert(sizeof(glm::highp_u64vec4) == 32, "int64 size isn't 8 bytes on this platform");
76
77
78 static_assert(sizeof(glm::lowp_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
79 static_assert(sizeof(glm::mediump_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
80 static_assert(sizeof(glm::highp_u8vec1) == 1, "uint8 size isn't 1 byte on this platform");
81
82 static_assert(sizeof(glm::lowp_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
83 static_assert(sizeof(glm::mediump_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
84 static_assert(sizeof(glm::highp_u16vec1) == 2, "uint16 size isn't 2 bytes on this platform");
85
86 static_assert(sizeof(glm::lowp_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
87 static_assert(sizeof(glm::mediump_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
88 static_assert(sizeof(glm::highp_u32vec1) == 4, "uint32 size isn't 4 bytes on this platform");
89
90 static_assert(sizeof(glm::lowp_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
91 static_assert(sizeof(glm::mediump_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
92 static_assert(sizeof(glm::highp_u64vec1) == 8, "uint64 size isn't 8 bytes on this platform");
93
94
95 static_assert(sizeof(glm::lowp_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
96 static_assert(sizeof(glm::mediump_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
97 static_assert(sizeof(glm::highp_u8vec2) == 2, "uint8 size isn't 1 byte on this platform");
98
99 static_assert(sizeof(glm::lowp_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
100 static_assert(sizeof(glm::mediump_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
101 static_assert(sizeof(glm::highp_u16vec2) == 4, "uint16 size isn't 2 bytes on this platform");
102
103 static_assert(sizeof(glm::lowp_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
104 static_assert(sizeof(glm::mediump_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
105 static_assert(sizeof(glm::highp_u32vec2) == 8, "uint32 size isn't 4 bytes on this platform");
106
107 static_assert(sizeof(glm::lowp_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
108 static_assert(sizeof(glm::mediump_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
109 static_assert(sizeof(glm::highp_u64vec2) == 16, "uint64 size isn't 8 bytes on this platform");
110
111
112 static_assert(sizeof(glm::lowp_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
113 static_assert(sizeof(glm::mediump_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
114 static_assert(sizeof(glm::highp_u8vec3) == 3, "uint8 size isn't 1 byte on this platform");
115
116 static_assert(sizeof(glm::lowp_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
117 static_assert(sizeof(glm::mediump_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
118 static_assert(sizeof(glm::highp_u16vec3) == 6, "uint16 size isn't 2 bytes on this platform");
119
120 static_assert(sizeof(glm::lowp_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
121 static_assert(sizeof(glm::mediump_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
122 static_assert(sizeof(glm::highp_u32vec3) == 12, "uint32 size isn't 4 bytes on this platform");
123
124 static_assert(sizeof(glm::lowp_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
125 static_assert(sizeof(glm::mediump_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
126 static_assert(sizeof(glm::highp_u64vec3) == 24, "uint64 size isn't 8 bytes on this platform");
127
128
129 static_assert(sizeof(glm::lowp_u8vec4) == 4, "uint8 size isn't 1 byte on this platform");
130 static_assert(sizeof(glm::mediump_u8vec4) == 4, "uint8 size isn't 1 byte on this platform");
131 static_assert(sizeof(glm::highp_u8vec4) == 4, "uint8 size isn't 1 byte on this platform");
132
133 static_assert(sizeof(glm::lowp_u16vec4) == 8, "uint16 size isn't 2 bytes on this platform");
134 static_assert(sizeof(glm::mediump_u16vec4) == 8, "uint16 size isn't 2 bytes on this platform");
135 static_assert(sizeof(glm::highp_u16vec4) == 8, "uint16 size isn't 2 bytes on this platform");
136
137 static_assert(sizeof(glm::lowp_u32vec4) == 16, "uint32 size isn't 4 bytes on this platform");
138 static_assert(sizeof(glm::mediump_u32vec4) == 16, "uint32 size isn't 4 bytes on this platform");
139 static_assert(sizeof(glm::highp_u32vec4) == 16, "uint32 size isn't 4 bytes on this platform");
140
141 static_assert(sizeof(glm::lowp_u64vec4) == 32, "uint64 size isn't 8 bytes on this platform");
142 static_assert(sizeof(glm::mediump_u64vec4) == 32, "uint64 size isn't 8 bytes on this platform");
143 static_assert(sizeof(glm::highp_u64vec4) == 32, "uint64 size isn't 8 bytes on this platform");
144
7145 #endif
8146
9147 static int test_scalar_size()
00 #define GLM_ENABLE_EXPERIMENTAL
11 #include <glm/gtx/wrap.hpp>
2 #include <glm/gtc/epsilon.hpp>
2 #include <glm/ext/scalar_relational.hpp>
3 #include <glm/ext/vector_relational.hpp>
34
45 namespace clamp
56 {
89 int Error(0);
910
1011 float A = glm::clamp(0.5f);
11 Error += glm::epsilonEqual(A, 0.5f, 0.00001f) ? 0 : 1;
12 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
1213
1314 float B = glm::clamp(0.0f);
14 Error += glm::epsilonEqual(B, 0.0f, 0.00001f) ? 0 : 1;
15 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
1516
1617 float C = glm::clamp(1.0f);
17 Error += glm::epsilonEqual(C, 1.0f, 0.00001f) ? 0 : 1;
18 Error += glm::equal(C, 1.0f, 0.00001f) ? 0 : 1;
1819
1920 float D = glm::clamp(-0.5f);
20 Error += glm::epsilonEqual(D, 0.0f, 0.00001f) ? 0 : 1;
21 Error += glm::equal(D, 0.0f, 0.00001f) ? 0 : 1;
2122
2223 float E = glm::clamp(1.5f);
23 Error += glm::epsilonEqual(E, 1.0f, 0.00001f) ? 0 : 1;
24 Error += glm::equal(E, 1.0f, 0.00001f) ? 0 : 1;
2425
2526 glm::vec2 K = glm::clamp(glm::vec2(0.5f));
26 Error += glm::all(glm::epsilonEqual(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
27 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
2728
2829 glm::vec3 L = glm::clamp(glm::vec3(0.5f));
29 Error += glm::all(glm::epsilonEqual(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
30 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
3031
3132 glm::vec4 M = glm::clamp(glm::vec4(0.5f));
32 Error += glm::all(glm::epsilonEqual(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
33 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
3334
3435 glm::vec1 N = glm::clamp(glm::vec1(0.5f));
35 Error += glm::all(glm::epsilonEqual(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
36 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
3637
3738 return Error;
3839 }
4546 int Error(0);
4647
4748 float A = glm::repeat(0.5f);
48 Error += glm::epsilonEqual(A, 0.5f, 0.00001f) ? 0 : 1;
49 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
4950
5051 float B = glm::repeat(0.0f);
51 Error += glm::epsilonEqual(B, 0.0f, 0.00001f) ? 0 : 1;
52 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
5253
5354 float C = glm::repeat(1.0f);
54 Error += glm::epsilonEqual(C, 0.0f, 0.00001f) ? 0 : 1;
55 Error += glm::equal(C, 0.0f, 0.00001f) ? 0 : 1;
5556
5657 float D = glm::repeat(-0.5f);
57 Error += glm::epsilonEqual(D, 0.5f, 0.00001f) ? 0 : 1;
58 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
5859
5960 float E = glm::repeat(1.5f);
60 Error += glm::epsilonEqual(E, 0.5f, 0.00001f) ? 0 : 1;
61 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
6162
6263 float F = glm::repeat(0.9f);
63 Error += glm::epsilonEqual(F, 0.9f, 0.00001f) ? 0 : 1;
64 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
6465
6566 glm::vec2 K = glm::repeat(glm::vec2(0.5f));
66 Error += glm::all(glm::epsilonEqual(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
67 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
6768
6869 glm::vec3 L = glm::repeat(glm::vec3(0.5f));
69 Error += glm::all(glm::epsilonEqual(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
70 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
7071
7172 glm::vec4 M = glm::repeat(glm::vec4(0.5f));
72 Error += glm::all(glm::epsilonEqual(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
73 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
7374
7475 glm::vec1 N = glm::repeat(glm::vec1(0.5f));
75 Error += glm::all(glm::epsilonEqual(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
76 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
7677
7778 return Error;
7879 }
8586 int Error(0);
8687
8788 float A = glm::mirrorClamp(0.5f);
88 Error += glm::epsilonEqual(A, 0.5f, 0.00001f) ? 0 : 1;
89 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
8990
9091 float B = glm::mirrorClamp(0.0f);
91 Error += glm::epsilonEqual(B, 0.0f, 0.00001f) ? 0 : 1;
92 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
9293
9394 float C = glm::mirrorClamp(1.1f);
94 Error += glm::epsilonEqual(C, 0.1f, 0.00001f) ? 0 : 1;
95 Error += glm::equal(C, 0.1f, 0.00001f) ? 0 : 1;
9596
9697 float D = glm::mirrorClamp(-0.5f);
97 Error += glm::epsilonEqual(D, 0.5f, 0.00001f) ? 0 : 1;
98 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
9899
99100 float E = glm::mirrorClamp(1.5f);
100 Error += glm::epsilonEqual(E, 0.5f, 0.00001f) ? 0 : 1;
101 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
101102
102103 float F = glm::mirrorClamp(0.9f);
103 Error += glm::epsilonEqual(F, 0.9f, 0.00001f) ? 0 : 1;
104 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
104105
105106 float G = glm::mirrorClamp(3.1f);
106 Error += glm::epsilonEqual(G, 0.1f, 0.00001f) ? 0 : 1;
107 Error += glm::equal(G, 0.1f, 0.00001f) ? 0 : 1;
107108
108109 float H = glm::mirrorClamp(-3.1f);
109 Error += glm::epsilonEqual(H, 0.1f, 0.00001f) ? 0 : 1;
110 Error += glm::equal(H, 0.1f, 0.00001f) ? 0 : 1;
110111
111112 float I = glm::mirrorClamp(-0.9f);
112 Error += glm::epsilonEqual(I, 0.9f, 0.00001f) ? 0 : 1;
113 Error += glm::equal(I, 0.9f, 0.00001f) ? 0 : 1;
113114
114115 glm::vec2 K = glm::mirrorClamp(glm::vec2(0.5f));
115 Error += glm::all(glm::epsilonEqual(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
116 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
116117
117118 glm::vec3 L = glm::mirrorClamp(glm::vec3(0.5f));
118 Error += glm::all(glm::epsilonEqual(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
119 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
119120
120121 glm::vec4 M = glm::mirrorClamp(glm::vec4(0.5f));
121 Error += glm::all(glm::epsilonEqual(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
122 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
122123
123124 glm::vec1 N = glm::mirrorClamp(glm::vec1(0.5f));
124 Error += glm::all(glm::epsilonEqual(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
125 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
125126
126127 return Error;
127128 }
134135 int Error(0);
135136
136137 float A = glm::mirrorRepeat(0.5f);
137 Error += glm::epsilonEqual(A, 0.5f, 0.00001f) ? 0 : 1;
138 Error += glm::equal(A, 0.5f, 0.00001f) ? 0 : 1;
138139
139140 float B = glm::mirrorRepeat(0.0f);
140 Error += glm::epsilonEqual(B, 0.0f, 0.00001f) ? 0 : 1;
141 Error += glm::equal(B, 0.0f, 0.00001f) ? 0 : 1;
141142
142143 float C = glm::mirrorRepeat(1.0f);
143 Error += glm::epsilonEqual(C, 1.0f, 0.00001f) ? 0 : 1;
144 Error += glm::equal(C, 1.0f, 0.00001f) ? 0 : 1;
144145
145146 float D = glm::mirrorRepeat(-0.5f);
146 Error += glm::epsilonEqual(D, 0.5f, 0.00001f) ? 0 : 1;
147 Error += glm::equal(D, 0.5f, 0.00001f) ? 0 : 1;
147148
148149 float E = glm::mirrorRepeat(1.5f);
149 Error += glm::epsilonEqual(E, 0.5f, 0.00001f) ? 0 : 1;
150 Error += glm::equal(E, 0.5f, 0.00001f) ? 0 : 1;
150151
151152 float F = glm::mirrorRepeat(0.9f);
152 Error += glm::epsilonEqual(F, 0.9f, 0.00001f) ? 0 : 1;
153 Error += glm::equal(F, 0.9f, 0.00001f) ? 0 : 1;
153154
154155 float G = glm::mirrorRepeat(3.0f);
155 Error += glm::epsilonEqual(G, 1.0f, 0.00001f) ? 0 : 1;
156 Error += glm::equal(G, 1.0f, 0.00001f) ? 0 : 1;
156157
157158 float H = glm::mirrorRepeat(-3.0f);
158 Error += glm::epsilonEqual(H, 1.0f, 0.00001f) ? 0 : 1;
159 Error += glm::equal(H, 1.0f, 0.00001f) ? 0 : 1;
159160
160161 float I = glm::mirrorRepeat(-1.0f);
161 Error += glm::epsilonEqual(I, 1.0f, 0.00001f) ? 0 : 1;
162 Error += glm::equal(I, 1.0f, 0.00001f) ? 0 : 1;
162163
163164 glm::vec2 K = glm::mirrorRepeat(glm::vec2(0.5f));
164 Error += glm::all(glm::epsilonEqual(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
165 Error += glm::all(glm::equal(K, glm::vec2(0.5f), glm::vec2(0.00001f))) ? 0 : 1;
165166
166167 glm::vec3 L = glm::mirrorRepeat(glm::vec3(0.5f));
167 Error += glm::all(glm::epsilonEqual(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
168 Error += glm::all(glm::equal(L, glm::vec3(0.5f), glm::vec3(0.00001f))) ? 0 : 1;
168169
169170 glm::vec4 M = glm::mirrorRepeat(glm::vec4(0.5f));
170 Error += glm::all(glm::epsilonEqual(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
171 Error += glm::all(glm::equal(M, glm::vec4(0.5f), glm::vec4(0.00001f))) ? 0 : 1;
171172
172173 glm::vec1 N = glm::mirrorRepeat(glm::vec1(0.5f));
173 Error += glm::all(glm::epsilonEqual(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
174 Error += glm::all(glm::equal(N, glm::vec1(0.5f), glm::vec1(0.00001f))) ? 0 : 1;
174175
175176 return Error;
176177 }