00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef LO_OSC_TYPES_H
00018 #define LO_OSC_TYPES_H
00019
00025 #ifdef _MSC_VER
00026 #define int32_t __int32
00027 #define int64_t __int64
00028 #define uint32_t unsigned __int32
00029 #define uint64_t unsigned __int64
00030 #define uint8_t unsigned __int8
00031 #else
00032 #include <stdint.h>
00033 #endif
00034
00043 typedef struct {
00045 uint32_t sec;
00048 uint32_t frac;
00049 } lo_timetag;
00050
00057 typedef enum {
00058
00060 LO_INT32 = 'i',
00062 LO_FLOAT = 'f',
00064 LO_STRING = 's',
00066 LO_BLOB = 'b',
00067
00068
00070 LO_INT64 = 'h',
00072 LO_TIMETAG = 't',
00074 LO_DOUBLE = 'd',
00077 LO_SYMBOL = 'S',
00079 LO_CHAR = 'c',
00081 LO_MIDI = 'm',
00083 LO_TRUE = 'T',
00085 LO_FALSE = 'F',
00087 LO_NIL = 'N',
00089 LO_INFINITUM = 'I'
00090 } lo_type;
00091
00092
00100 typedef union {
00102 int32_t i;
00104 int32_t i32;
00106 int64_t h;
00108 int64_t i64;
00110 float f;
00112 float f32;
00114 double d;
00116 double f64;
00118 char s;
00121 char S;
00123 unsigned char c;
00125 uint8_t m[4];
00127 lo_timetag t;
00128 } lo_arg;
00129
00131
00132 #ifdef _MSC_VER
00133 lo_timetag lo_get_tt_immediate();
00134 #define LO_TT_IMMEDIATE lo_get_tt_immediate()
00135 #else
00136 #define LO_TT_IMMEDIATE ((lo_timetag){0U,1U})
00137 #endif
00138
00141 #endif