#ifndef EMULATOR_PLATFORM_SETUP_H #define EMULATOR_PLATFORM_SETUP_H #ifndef _CRT_SECURE_NO_WARNINGS #define _CRT_SECURE_NO_WARNINGS #endif /* * Platform specific emulator setup */ #if (defined(_WINDOWS) || defined(__APPLE__) || defined(__linux__) || defined(__MINGW32__)) && !defined(__ANDROID__) //Open Graphics Library (Embedded Systems) //#define OGLES //#define OGLES_VERSION 2 //Open Graphics Library #define OGL //Direct3D9 //#define D3D9 #if defined(OGL) #define SDL2 #define GLEW #endif #elif defined(__EMSCRIPTEN__) #define OGLES #define OGLES_VERSION (2) #elif defined(__ANDROID__) #define OGLES #define OGLES_VERSION (3) #if OGLES_VERSION == 2 #define ES2_SHADERS #elif OGLES_VERSION == 3 #define ES3_SHADERS #endif #define SDL2 #endif #if defined(GLEW) #define GL_GLEXT_PROTOTYPES 1 #include #endif /* * Emulator render options. */ #define RO_DOUBLE_BUFFERED #if defined(__APPLE__) || defined(__EMSCRIPTEN__) //#include #endif /* * SDL.H inclusion. */ #if defined(__APPLE__) #include #include #elif defined(__EMSCRIPTEN__) #include #elif (defined(_WINDOWS) || defined(__MINGW32__) || defined(__linux__)) && !defined(__ANDROID__) #include #elif defined (__ANDROID__) #include #endif #if defined (OGL) #include ///@FIXME see mac! #elif defined (OGLES) #include #if OGLES_VERSION == 2 #define GL_GLEXT_PROTOTYPES #include #include #elif OGLES_VERSION == 3 #include #endif #include #elif defined(D3D9) #include #include #endif #if !defined (__EMSCRIPTEN__) //#include #endif #if defined(OGL) #define TEXTURE_FORMAT GL_UNSIGNED_SHORT_1_5_5_5_REV #elif defined(OGLES) #define TEXTURE_FORMAT GL_UNSIGNED_SHORT_5_5_5_1 #endif #endif