PlatformDefinitions.h

Go to the documentation of this file.
00001 #ifndef TYPE_DEFINITIONS_H
00002 #define TYPE_DEFINITIONS_H
00003 
00005 
00006 #ifdef _WIN32
00007 
00008 typedef union
00009 {
00010   unsigned int u;
00011   void *p;
00012 } addr64;
00013 
00014 #define USE_WIN32_THREADING 1
00015 
00016                 #if defined(__MINGW32__) || defined(__CYGWIN__) || (defined (_MSC_VER) && _MSC_VER < 1300)
00017                 #else
00018                 #endif //__MINGW32__
00019 
00020                 typedef unsigned char     uint8_t;
00021 #ifndef __PHYSICS_COMMON_H__
00022 #ifndef __BT_SKIP_UINT64_H
00023                 typedef unsigned long int uint64_t;
00024 #endif //__BT_SKIP_UINT64_H
00025                 typedef unsigned int      uint32_t;
00026 #endif //__PHYSICS_COMMON_H__
00027                 typedef unsigned short    uint16_t;
00028 
00029                 #include <malloc.h>
00030                 #define memalign(alignment, size) malloc(size);
00031                         
00032 #include <string.h> //memcpy
00033 
00034                 
00035 
00036                 #include <stdio.h>              
00037                 #define spu_printf printf
00038                 
00039 #else
00040                 #include <stdint.h>
00041                 #include <stdlib.h>
00042                 #include <string.h> //for memcpy
00043 
00044 #if defined     (__CELLOS_LV2__)
00045         // Playstation 3 Cell SDK
00046 #include <spu_printf.h>
00047                 
00048 #else
00049         // posix system
00050 
00051 #define USE_PTHREADS    (1)
00052 
00053 #ifdef USE_LIBSPE2
00054 #include <stdio.h>              
00055 #define spu_printf printf       
00056 #define DWORD unsigned int
00057                 
00058                         typedef union
00059                         {
00060                           unsigned long long ull;
00061                           unsigned int ui[2];
00062                           void *p;
00063                         } addr64;
00064                 
00065                 
00066 #else
00067 
00068 #include <stdio.h>              
00069 #define spu_printf printf       
00070 
00071 #endif // USE_LIBSPE2
00072         
00073 #endif  //__CELLOS_LV2__
00074         
00075 #endif
00076 
00077 
00078 /* Included here because we need uint*_t typedefs */
00079 #include "PpuAddressSpace.h"
00080 
00081 #endif //TYPE_DEFINITIONS_H
00082 
00083 
00084 

Generated on Mon Feb 15 22:17:08 2010 for Bullet Collision Detection & Physics Library by  doxygen 1.6.1