Merge remote-tracking branch 'upstream/master'

This commit is contained in:
myfreeer
2023-04-08 13:41:53 +08:00
2 changed files with 28 additions and 2 deletions

View File

@@ -101,7 +101,7 @@ Functions documentation
Parameters:
| *[in]* **box** AABB
| *[in]* **padding** padding
| *[out]* **d** result matrix
| *[out]* **dest** result matrix
.. c:function:: void glm_ortho_aabb_pz(vec3 box[2], float padding, mat4 dest)
@@ -113,7 +113,7 @@ Functions documentation
Parameters:
| *[in]* **box** AABB
| *[in]* **padding** padding for near and far
| *[out]* **d** result matrix
| *[out]* **dest** result matrix
Returns:
square of norm / magnitude

View File

@@ -60,6 +60,32 @@
# define CGLM_PRINT_COLOR_RESET "\033[0m"
#endif
/*!
* @brief prints current SIMD path in general
*
* @param[in] ostream stream to print e.g. stdout, stderr, FILE ...
*/
CGLM_INLINE
void
glm_arch_print_name(FILE* __restrict ostream) {
#ifdef CGLM_SIMD_x86
fprintf(ostream, CGLM_PRINT_COLOR "\ncglm arch: x86 SSE*"
#ifdef __AVX__
" AVX"
#endif
"\n\n" CGLM_PRINT_COLOR_RESET);
#elif defined(CGLM_SIMD_ARM)
fprintf(ostream, CGLM_PRINT_COLOR "\ncglm arch: arm"
#ifndef __ARM_NEON_FP
" NEON_FP"
#endif
#ifdef CGLM_ARM64
" ARM64"
#endif
"\n\n" CGLM_PRINT_COLOR_RESET);
#endif
}
CGLM_INLINE
void
glm_mat4_print(mat4 matrix,