From 235e72829e55cbb1e7632fe1b2d1429f6f3be054 Mon Sep 17 00:00:00 2001 From: bjarni Date: Sun, 12 Feb 2006 14:31:33 +0000 Subject: (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 --- os/macosx/osx_stdafx.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 os/macosx/osx_stdafx.h (limited to 'os') diff --git a/os/macosx/osx_stdafx.h b/os/macosx/osx_stdafx.h new file mode 100644 index 000000000..9567d70ba --- /dev/null +++ b/os/macosx/osx_stdafx.h @@ -0,0 +1,19 @@ +/* $Id$ */ + +#ifndef MACOS_STDAFX_H +#define MACOS_STDAFX_H + +#include +// remove the variables that CoreServices defines, but we define ourselves too +#undef bool +#undef false +#undef true + +/* Name conflict */ +#define Rect OTTDRect +#define Point OTTDPoint +#define GetTime OTTDGetTime + +#define SL_ERROR OSX_SL_ERROR + +#endif /* MACOS_STDAFX_H */ -- cgit v1.2.3-70-g09d2