 |
Kochol Game Engine
0.1.0
|
Go to the documentation of this file.
11 #define kgedecref(s) if (s) {s->DecRef(); s = NULL;}
16 #define KGE_VERSION_NUM 0.0.11
17 #define KGE_VERSION_MAJOR 0
18 #define KGE_VERSION_MINOR 0
19 #define KGE_VERSION_RELEASE 11
20 #define KGE_VERSION_SUFFIX ""
21 #define KGE_VERSION_NAME "Kochol Game Engine 0.0.11"
23 #define KGE_VERSION ((KGE_VERSION_MAJOR << 16) | (KGE_VERSION_MINOR << 8) | KGE_VERSION_RELEASE)
29 #define KGE_PLATFORM_UNKNOWN 0 // Unknown platform
30 #define KGE_PLATFORM_WINDOWS 1 // Microsoft Windows
31 #define KGE_PLATFORM_LINUX 2 // Linux OS
32 #define KGE_PLATFORM_APPLE 3 // Apple MAC-OS
33 #define KGE_PLATFORM_ANDROID 4 // Android platform
35 #define KGE_COMPILER_UNKNOWN 0 // Unknown compiler
36 #define KGE_COMPILER_MSVC 1 // Microsoft Visual C++
37 #define KGE_COMPILER_GNUC 2 // GNU C/C++ compilers
38 #define KGE_COMPILER_BORL 3 // Borland C/C++ compiler
39 #define KGE_COMPILER_NDK 4 // NDK build system
41 #define KGE_ARCHITECTURE_UNKNOWN 0 // Unknown architecture
42 #define KGE_ARCHITECTURE_32 1 // 32-bit architecture CPU
43 #define KGE_ARCHITECTURE_64 2 // 64-bit architecture CPU
46 #if defined( _MSC_VER )
47 #define KGE_COMPILER KGE_COMPILER_MSVC
48 #define KGE_COMP_VER _MSC_VER
50 #elif defined( __GNUC__ )
51 #define KGE_COMPILER KGE_COMPILER_GNUC
52 #define KGE_COMP_VER (((__GNUC__)*100) + \
53 (__GNUC_MINOR__*10) + \
56 #elif defined( __BORLANDC__ )
57 #define KGE_COMPILER KGE_COMPILER_BORL
58 #define KGE_COMP_VER __BCPLUSPLUS__
61 #define KGE_COMPILER KGE_PLATFORM_ANDROID
62 #define KGE_COMP_VER 7
65 #define KGE_COMPILER KGE_COMPILER_UNKNOWN
66 #pragma error "No known compiler. Compiling Abrot!"
70 #if defined( __WIN32__ ) || defined( _WIN32 ) || defined(_WIN64)
71 #define KGE_PLATFORM KGE_PLATFORM_WINDOWS
72 #elif defined( __APPLE_CC__)
73 #define KGE_PLATFORM KGE_PLATFORM_APPLE
74 #elif defined(ANDROID)
75 #define KGE_PLATFORM KGE_PLATFORM_ANDROID
76 #elif defined(__unix__)
77 #define KGE_PLATFORM KGE_PLATFORM_LINUX
79 #define KGE_PLATFORM KGE_PLATFORM_UNKNOWN
83 #if defined(__x86_x64__) || defined(_M_X64) || defined(__powerpc64__) || defined(__alpha__) || defined(__ia64__) || defined(__s390__) || defined(__s390x__)
84 #define KGE_ARCHITECTURE_TYPE KGE_ARCHITECTURE_64
86 #define KGE_ARCHITECTURE_TYPE KGE_ARCHITECTURE_32
92 #if defined(DEBUG) || defined(_DEBUG)
93 #define KGE_DEBUG_MODE 1
95 #define KGE_DEBUG_MODE 0
101 #if defined(_UNICODE) && (KGE_USE_UNICODE == 1)
102 #define KGE_SUPPORT_UNICODE 1
104 #define KGE_SUPPORT_UNICODE 0
111 #if KGE_COMPILER == KGE_COMPILER_MSVC
113 #define KGE_USE_MSVC_ASM 1
115 #define KGE_API __declspec(dllexport)
117 #define KGE_API __declspec(dllimport)
119 #ifdef KGELIB_EXPORTS
120 # define KGELIB_API __declspec( dllexport )
122 # define KGELIB_API __declspec( dllimport )
124 #define KGE_IMPORT __declspec( dllimport )
125 #define NAKED_FUNC void _declspec (naked)
129 #pragma warning(disable : 4244) // conversion to float, possible loss of data
130 #pragma warning(disable : 4699) // creating precompiled header
131 #pragma warning(disable : 4200) // Zero-length array item at end of structure, a VC-specific extension
132 #pragma warning(disable : 4100) // unreferenced formal parameter
133 #pragma warning(disable : 4514) // unreferenced inline function has been removed
134 #pragma warning(disable : 4201) // nonstandard extension used : nameless struct/union
135 #pragma warning(disable : 4710) // inline function not expanded
136 #pragma warning(disable : 4714) // __forceinline function not expanded
137 #pragma warning(disable : 4702) // unreachable code in inline expanded function
138 #pragma warning(disable : 4711) // function selected for autmatic inlining
139 #pragma warning(disable : 4127) // Conditional expression is constant
140 #pragma warning(disable : 4512) // assignment operator could not be generated
141 #pragma warning(disable : 4245) // conversion from 'enum ' to 'unsigned long', signed/unsigned mismatch
142 #pragma warning(disable : 4389) // signed/unsigned mismatch
143 #pragma warning(disable : 4251) // needs to have dll-interface to be used by clients of class
144 #pragma warning(disable : 4275) // non dll-interface class used as base for dll-interface class
145 #pragma warning(disable : 4511) // copy constructor could not be generated
146 #pragma warning(disable : 4284) // return type is not a UDT or reference to a UDT
147 #pragma warning(disable : 4355) // this used in base initializer list
148 #pragma warning(disable : 4291) // typedef-name '' used as synonym for class-name ''
149 #pragma warning(disable : 4324) // structure was padded due to __declspec(align())
152 #pragma warning(disable : 4996) // 'function': was declared deprecated
157 #pragma warning(disable : 4189) // local variable is initialized but not referenced
158 #pragma warning(disable : 4505) // unreferenced local function has been removed
165 #define NAKED_FUNC void
172 #define MAXID 65535 // MAXID = NULL for u32 IDs
173 #define KGE_BB_SPHERE
174 #define KGE_DEVICE_LOST 0x8001
175 #define KGE_DEVICE_RESET 0x8002
188 #if defined(__x86_x64__) || defined(_M_X64) || defined(__powerpc64__) || defined(__alpha__) || defined(__ia64__) || defined(__s390__) || defined(__s390x__)
189 # error "kge dosen't support 64-bit compilition yet"
190 #else // 32-bit CPU architecture
199 typedef unsigned long long u64;
202 typedef signed long long s64;
208 typedef unsigned short u16;
214 typedef unsigned char u8;