+#include <globaldefs.h>
#include "bsploader.h"
#include "dialogs/dialogs-gtk.h"
#include "cmdlib.h"
dbrushside_t *dbrushsides = NULL;
int *dleafbrushes = NULL;
-#define BSP_IDENT ( ( 'P' << 24 ) + ( 'S' << 16 ) + ( 'B' << 8 ) + 'I' )
-#define Q3_BSP_VERSION 46
-#define WOLF_BSP_VERSION 47
+const int BSP_IDENT = ( ( 'P' << 24 ) + ( 'S' << 16 ) + ( 'B' << 8 ) + 'I' );
+const int Q3_BSP_VERSION = 46;
+const int WOLF_BSP_VERSION = 47;
/*
================
}
int LittleLong( int l ){
-#if defined( __BIG_ENDIAN__ )
- std::reverse( reinterpret_cast<unsigned char*>( &l ), reinterpret_cast<unsigned char*>( &l ) + sizeof( int ) );
-#endif
+ if (GDEF_ARCH_ENDIAN_BIG) {
+ std::reverse(reinterpret_cast<unsigned char *>( &l ), reinterpret_cast<unsigned char *>( &l ) + sizeof(int));
+ }
return l;
}
float LittleFloat( float l ){
-#if defined( __BIG_ENDIAN__ )
- std::reverse( reinterpret_cast<unsigned char*>( &l ), reinterpret_cast<unsigned char*>( &l ) + sizeof( float ) );
-#endif
+ if (GDEF_ARCH_ENDIAN_BIG) {
+ std::reverse( reinterpret_cast<unsigned char*>( &l ), reinterpret_cast<unsigned char*>( &l ) + sizeof( float ) );
+ }
return l;
}