Searched defs:CLAMP8 (Results 1 – 10 of 10) sorted by relevance
12 #define CLAMP8(i) if ((int8_t)(i) != i) i = 0x7F ^ (i >> 15) macro
67 #define CLAMP8(i) if ((int8_t)(i) != i) i = 0x7F ^ (i >> 31) macro
34 #define CLAMP8(x) do { if (x > 0xff) x = 0xff; if (x < 0) x = 0; } while (0) macro
322 #define CLAMP8(c) ( ((c) < -128) ? 0 : (((c) > (255 - 128)) ? 255 : ((c) + 128)) ) macro
1081 #define CLAMP8(x) do { if (x > 0xff) x = 0xff; if (x < 0) x = 0; } while (0) macro
1083 #define CLAMP8(x) do { if (x > 0xff) x = 0xff; if (x < 0) x = 0; } while (0) macro
43 #define CLAMP8(x) ((x) < 0 ? 0 : (x) > 255 ? 255 : (x)) macro