diff options
author | bjarni <bjarni@openttd.org> | 2006-02-12 14:31:33 +0000 |
---|---|---|
committer | bjarni <bjarni@openttd.org> | 2006-02-12 14:31:33 +0000 |
commit | 8744075a6cb64578f7e255220d76b77b26eb1a45 (patch) | |
tree | 69d0102238a85f5bd3d34ca4d93e1973a70ab771 /music | |
parent | 0dfc0ea76b079af9e84846848f348f0f717ab4a7 (diff) | |
download | openttd-8744075a6cb64578f7e255220d76b77b26eb1a45.tar.xz |
(svn r3596) -Codechange: [OSX] changed to use Apple's macros instead of OTTD macros for endian conversion
This increases the execution speed a lot since GCC can't detect the OTTD macro as an endian conversion
while Apple's code uses the instruction to convert endian instead of a series of instructions to produce the same result
Since we don't have that many endian conversions in the game, overall performance should not increase noteworthy
Diffstat (limited to 'music')
-rw-r--r-- | music/qtmidi.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/music/qtmidi.c b/music/qtmidi.c index dc668c8b0..f6b2bed6e 100644 --- a/music/qtmidi.c +++ b/music/qtmidi.c @@ -24,6 +24,10 @@ /* * OpenTTD includes. */ +#define WindowClass OSX_WindowClass +#include <QuickTime/QuickTime.h> +#undef WindowClass + #include "../stdafx.h" #include "../openttd.h" #include "qtmidi.h" @@ -32,19 +36,10 @@ * System includes. We need to workaround with some defines because there's * stuff already defined in QuickTime headers. */ -#define bool OSX_bool -#define Rect OSX_Rect -#define Point OSX_Point -#define SL_ERROR OSX_SL_ERROR -#define WindowClass OSX_WindowClass #define OTTD_Random OSX_OTTD_Random -#include <CoreServices/CoreServices.h> -#include <QuickTime/QuickTime.h> #undef OTTD_Random #undef WindowClass #undef SL_ERROR -#undef Point -#undef Rect #undef bool #include <assert.h> |