misc/openalbridge/globals.h
changeset 3362 8d3b4d19ce27
parent 3360 717b4e46e855
child 3364 e5403e2bf02c
--- a/misc/openalbridge/globals.h	Wed Apr 21 01:57:23 2010 +0000
+++ b/misc/openalbridge/globals.h	Wed Apr 21 10:22:06 2010 +0000
@@ -40,14 +40,14 @@
 #include "errlib.h"
 
 
-/*control debug verbosity*/
+// control debug verbosity
 #ifdef TRACE
 #ifndef DEBUG
 #define DEBUG
 #endif
 #endif
 
-/** 1.0 02/03/10 - Defines cross-platform sleep, usleep, etc. [Wu Yongwei] **/
+// 1.0 02/03/10 - Defines cross-platform sleep, usleep, etc. [Wu Yongwei]
 #ifndef _SLEEP_H
 #define _SLEEP_H
 #ifdef _WIN32
@@ -69,21 +69,20 @@
 #  define msleep(t) usleep((t) * 1000)
 # endif
 #endif
-#endif /* _SLEEP_H */
+#endif // _SLEEP_H
 
 
-/* check compiler requirements */    /*FIXME*/
+// check compiler requirements
 #if !defined(__BIG_ENDIAN__) && !defined(__LITTLE_ENDIAN__)
 #warning __BIG_ENDIAN__ or __LITTLE_ENDIAN__ not found, going to set __LITTLE_ENDIAN__ as default
 #define __LITTLE_ENDIAN__ 1
-//#error Do not know the endianess of this architecture
 #endif
 
-/* use byteswap macros from the host system, hopefully optimized ones ;-) 
+/* use byteswap macros from the host system, hopefully optimized ones ;-)
  * or define our own version, simple, stupid, straight-forward... */
 #ifdef HAVE_BYTESWAP_H
 #include <byteswap.h>
-#else        
+#else
 #define bswap_16(x)	((((x) & 0xFF00) >> 8) | (((x) & 0x00FF) << 8))
 #define bswap_32(x)	((((x) & 0xFF000000) >> 24) | (((x) & 0x00FF0000) >> 8)  | \
 (((x) & 0x0000FF00) << 8)  | (((x) & 0x000000FF) << 24) )
@@ -99,51 +98,14 @@
 #define ENDIAN_LITTLE_32(x) bswap_32(x)
 #define ENDIAN_BIG_32(x)    x
 #define ENDIAN_LITTLE_16(x) bswap_16(x)
-#define ENDIAN_BIG_16(x)    x    
+#define ENDIAN_BIG_16(x)    x
 #endif
 
-
-#ifdef __CPLUSPLUS
-extern "C" {
-#endif 
-    
-    /*data type for WAV header*/
-#pragma pack(1)
-    typedef struct _WAV_header_t {
-        uint32_t ChunkID;
-        uint32_t ChunkSize;
-        uint32_t Format;
-        uint32_t Subchunk1ID;
-        uint32_t Subchunk1Size;
-        uint16_t AudioFormat;
-        uint16_t NumChannels;
-        uint32_t SampleRate;
-        uint32_t ByteRate;
-        uint16_t BlockAlign;
-        uint16_t BitsPerSample;
-        uint32_t Subchunk2ID;
-        uint32_t Subchunk2Size;
-    } WAV_header_t;
-#pragma pack()
-    
-    /*data type for passing data between threads*/
-#pragma pack(1)
-    typedef struct _fade_t {
-        uint32_t index;
-        uint16_t quantity;
-    } fade_t;
-#pragma pack()
-    
-    
-    /*file format defines*/
+/*file format defines*/
 #define OGG_FILE_FORMAT 0x4F676753
 #define WAV_FILE_FORMAT 0x52494646
 #define WAV_HEADER_SUBCHUNK2ID 0x64617461
-    
-    char *prog;
-    
-#ifdef __CPLUSPLUS
-}
-#endif
+
+char *prog = "OpenAL subsystem";
 
 #endif /*_OALB_GLOBALS_H*/