Isle
Loading...
Searching...
No Matches
mxtypes.h File Reference

Go to the source code of this file.

Classes

union  FlagBitfield
 [AI] Union that provides a convenient bit field view of a byte for flag manipulation. More...
 

Macros

#define SUCCESS   0
 [AI] Macro for function success return value, always 0. More...
 
#define FAILURE   -1
 [AI] Macro for function failure return value, always -1. More...
 
#define TRUE   1
 [AI] Macro for boolean true value, always 1. More...
 
#define FALSE   0
 [AI] Macro for boolean false value, always 0. More...
 
#define NULL   0
 [AI] Macro for null pointer, always 0. More...
 
#define TWOCC(a, b)   (((a) << 0) | ((b) << 8))
 [AI] Macro to compose a 16-bit code from two 8-bit characters (e.g., for type IDs). More...
 
#define FOURCC(a, b, c, d)   (((a) << 0) | ((b) << 8) | ((c) << 16) | ((d) << 24))
 [AI] Macro to compose a 32-bit code from four 8-bit characters (e.g., for resource and chunk IDs). More...
 

Typedefs

typedef unsigned char MxU8
 [AI] More...
 
typedef signed char MxS8
 [AI] More...
 
typedef unsigned short MxU16
 [AI] More...
 
typedef signed short MxS16
 [AI] More...
 
typedef unsigned int MxU32
 [AI] More...
 
typedef signed int MxS32
 [AI] More...
 
typedef unsigned long long int MxU64
 [AI] More...
 
typedef signed long long int MxS64
 [AI] More...
 
typedef float MxFloat
 [AI] More...
 
typedef double MxDouble
 [AI] More...
 
typedef int MxLong
 [AI] More...
 
typedef unsigned int MxULong
 [AI] More...
 
typedef MxS32 MxTime
 [AI] More...
 
typedef MxLong MxResult
 [AI] More...
 
typedef MxU8 MxBool
 [AI] More...
 

Macro Definition Documentation

◆ FAILURE

#define FAILURE   -1

[AI] Macro for function failure return value, always -1.

Definition at line 117 of file mxtypes.h.

◆ FALSE

#define FALSE   0

[AI] Macro for boolean false value, always 0.

Definition at line 135 of file mxtypes.h.

◆ FOURCC

#define FOURCC (   a,
  b,
  c,
 
)    (((a) << 0) | ((b) << 8) | ((c) << 16) | ((d) << 24))

[AI] Macro to compose a 32-bit code from four 8-bit characters (e.g., for resource and chunk IDs).

[AI]

Parameters
aFirst character (lowest byte) [AI]
bSecond character [AI]
cThird character [AI]
dFourth character (highest byte) [AI]

[AI] Used for things like identifying file/resource chunk types in SI files.

Definition at line 162 of file mxtypes.h.

◆ NULL

#define NULL   0

[AI] Macro for null pointer, always 0.

Definition at line 141 of file mxtypes.h.

◆ SUCCESS

#define SUCCESS   0

[AI] Macro for function success return value, always 0.

Definition at line 111 of file mxtypes.h.

◆ TRUE

#define TRUE   1

[AI] Macro for boolean true value, always 1.

Definition at line 129 of file mxtypes.h.

◆ TWOCC

#define TWOCC (   a,
 
)    (((a) << 0) | ((b) << 8))

[AI] Macro to compose a 16-bit code from two 8-bit characters (e.g., for type IDs).

[AI]

Parameters
aFirst character (low byte) [AI]
bSecond character (high byte) [AI]

[AI] Returns an integer where the low byte is 'a' and the high byte is 'b'.

Definition at line 151 of file mxtypes.h.

Typedef Documentation

◆ MxBool

[AI]

[AI] Boolean type, 1 byte in size, with TRUE (1) and FALSE (0) macros for clarity.

Definition at line 124 of file mxtypes.h.

◆ MxDouble

[AI]

[AI] 64-bit floating point type, used for precise calculations or storage of high-precision data.

Definition at line 74 of file mxtypes.h.

◆ MxFloat

[AI]

[AI] 32-bit floating point type, main float type for 3D coordinates, matrices, and general calculations.

Definition at line 68 of file mxtypes.h.

◆ MxLong

[AI]

[AI] Signed integer with 32-bit width on all platforms, guaranteed to match 'long' on MSVC.

Used for compatibility with Windows DLL linkage.

Definition at line 83 of file mxtypes.h.

◆ MxResult

[AI]

[AI] Result type for functions, usually uses SUCCESS (0) or FAILURE (-1) as return value, can supply extended result codes.

Definition at line 106 of file mxtypes.h.

◆ MxS16

[AI]

[AI] 16-bit signed integer type.

Definition at line 26 of file mxtypes.h.

◆ MxS32

[AI]

[AI] 32-bit signed integer type, principal signed integer for main calculations, indexes, etc.

Definition at line 38 of file mxtypes.h.

◆ MxS64

[AI]

[AI] 64-bit signed integer type for large signed values, version for non-MSVC compilers.

Definition at line 61 of file mxtypes.h.

◆ MxS8

[AI]

[AI] 8-bit signed integer type used for small signed values and data.

Definition at line 14 of file mxtypes.h.

◆ MxTime

[AI]

[AI] Signed 32-bit integer used for time values (e.g., ticks, time offsets).

Definition at line 100 of file mxtypes.h.

◆ MxU16

[AI]

[AI] 16-bit unsigned integer type.

Definition at line 20 of file mxtypes.h.

◆ MxU32

[AI]

[AI] 32-bit unsigned integer type, main unsigned integer for many resource IDs, counters, etc.

Definition at line 32 of file mxtypes.h.

◆ MxU64

[AI]

[AI] 64-bit unsigned integer type for file positions and large data, version for non-MSVC compilers.

Definition at line 56 of file mxtypes.h.

◆ MxU8

[AI]

[AI] 8-bit unsigned integer type used throughout the engine for small values and binary data.

Definition at line 8 of file mxtypes.h.

◆ MxULong

[AI]

[AI] Unsigned integer with 32-bit width on all platforms, guaranteed to match 'unsigned long' on MSVC.

Used for Windows DLL compatibility.

Definition at line 93 of file mxtypes.h.