Android update and small improvements

-fixed code do cross compiling to android
-fixed build with GCC (workaround)
-added little benchmark
-several small fixes
-updated meson build (demos building, working with GCC, LDC and DMD)
-added some meson options
-added ImGUI bind for OpenGL3
This commit is contained in:
Mergul 2020-06-01 11:24:50 +02:00
parent 86edfa4a57
commit 66860b9042
30 changed files with 1358 additions and 173 deletions

View file

@ -14,8 +14,8 @@ import bindbc.sdl.config,
bindbc.sdl.bind;
private {
SharedLib lib;
SDLSupport loadedVersion;
__gshared SharedLib lib;
__gshared SDLSupport loadedVersion;
}
void unloadSDL()
@ -664,14 +664,14 @@ SDLSupport loadSDL(const(char)* libName)
lib.bindSymbol(cast(void**)&SDL_HasColorKey, "SDL_HasColorKey");
lib.bindSymbol(cast(void**)&SDL_GetDisplayOrientation, "SDL_GetDisplayOrientation");
version(linux) {
lib.bindSymbol(cast(void**)&SDL_LinuxSetThreadPriority, "SDL_LinuxSetThreadPriority");
}
else version(Android) {
version(Android) {
lib.bindSymbol(cast(void**)&SDL_IsChromebook, "SDL_IsChromebook");
lib.bindSymbol(cast(void**)&SDL_IsDeXMode, "SDL_IsDeXMode");
lib.bindSymbol(cast(void**)&SDL_AndroidBackButton, "SDL_AndroidBackButton");
}
else version(linux) {
lib.bindSymbol(cast(void**)&SDL_LinuxSetThreadPriority, "SDL_LinuxSetThreadPriority");
}
if(errorCount() != errCount) return SDLSupport.badLibrary;
else loadedVersion = SDLSupport.sdl209;

View file

@ -229,8 +229,8 @@ else {
}
private {
SharedLib lib;
SDLImageSupport loadedVersion;
__gshared SharedLib lib;
__gshared SDLImageSupport loadedVersion;
}
void unloadSDLImage()