Skip to content

Commit 2fe4cde

Browse files
comments and polish
1 parent 1cedf80 commit 2fe4cde

3 files changed

Lines changed: 431 additions & 227 deletions

File tree

include/maths.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ static inline uint8_t stdc_count_ones(uint32_t x) {
174174

175175
#define MIN(a,b) (((a) < (b)) ? (a) : (b))
176176
#define MAX(a,b) (((a) > (b)) ? (a) : (b))
177-
#define CLAMP(v, lo, hi) (((v) < (lo)) ? (lo) : (((v) > (hi)) ? (hi) : (v)))
177+
#define CLAMP(v, lo, hi) (((v) <= (lo)) ? (lo) : (((v) >= (hi)) ? (hi) : (v)))
178178

179179
/* === Constants: INFINITY, NAN =========================================== */
180180

0 commit comments

Comments
 (0)