mirror of
https://github.com/recp/cglm.git
synced 2025-10-04 01:00:46 +00:00
add MIN and MAX macros
because we could use min/max for intergers too. it may not guarantee that MIN and MAX macros will always be defined by compiler
This commit is contained in:
@@ -21,6 +21,9 @@
|
||||
#include "common.h"
|
||||
#include <stdbool.h>
|
||||
|
||||
#define GLM_MIN(X, Y) (((X) < (Y)) ? (X) : (Y))
|
||||
#define GLM_MAX(X, Y) (((X) > (Y)) ? (X) : (Y))
|
||||
|
||||
/*!
|
||||
* @brief get sign of 32 bit integer as +1, -1, 0
|
||||
*
|
||||
|
Reference in New Issue
Block a user