diff options
author | kwolekr <kwolekr@minetest.net> | 2015-10-04 02:50:04 -0400 |
---|---|---|
committer | kwolekr <kwolekr@minetest.net> | 2015-10-04 04:00:16 -0400 |
commit | f0cd5da687ca216b4bdd9abe7bc8038a679d3763 (patch) | |
tree | 329909b22c4494a2df2249c5697acb961b0fc527 /src/irrlichttypes.h | |
parent | b12bdcce348323247811b9a0299e2e9294991d13 (diff) | |
download | minetest-f0cd5da687ca216b4bdd9abe7bc8038a679d3763.tar.gz minetest-f0cd5da687ca216b4bdd9abe7bc8038a679d3763.tar.bz2 minetest-f0cd5da687ca216b4bdd9abe7bc8038a679d3763.zip |
Define and use limit constants for Irrlicht fixed-width types
Diffstat (limited to 'src/irrlichttypes.h')
-rw-r--r-- | src/irrlichttypes.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/irrlichttypes.h b/src/irrlichttypes.h index bead64407..dedebd45b 100644 --- a/src/irrlichttypes.h +++ b/src/irrlichttypes.h @@ -48,4 +48,19 @@ using namespace irr; #endif #endif +#define S8_MIN (-0x7F - 1) +#define S16_MIN (-0x7FFF - 1) +#define S32_MIN (-0x7FFFFFFF - 1) +#define S64_MIN (-0x7FFFFFFFFFFFFFFF - 1) + +#define S8_MAX 0x7F +#define S16_MAX 0x7FFF +#define S32_MAX 0x7FFFFFFF +#define S64_MAX 0x7FFFFFFFFFFFFFFF + +#define U8_MAX 0xFF +#define U16_MAX 0xFFFF +#define U32_MAX 0xFFFFFFFF +#define U64_MAX 0xFFFFFFFFFFFFFFFF + #endif |