Fixed android compilation

This commit is contained in:
Deve 2017-04-05 21:46:37 +02:00
parent 1d39030f51
commit 240041f520
3 changed files with 10 additions and 1 deletions

View File

@ -10,6 +10,10 @@
#include "os.h" #include "os.h"
#include "fast_atof.h" #include "fast_atof.h"
#if defined(_IRR_COMPILE_WITH_ANDROID_DEVICE_)
#include "android_native_app_glue.h"
#endif
#if defined(_IRR_COMPILE_WITH_EGL_) #if defined(_IRR_COMPILE_WITH_EGL_)
namespace irr namespace irr

View File

@ -10,6 +10,7 @@
#include <assert.h> #include <assert.h>
#include "os.h" #include "os.h"
#include "CContextEGL.h"
#include "CFileSystem.h" #include "CFileSystem.h"
#include "COGLES2Driver.h" #include "COGLES2Driver.h"
@ -306,7 +307,7 @@ void CIrrDeviceAndroid::handleAndroidCommand(android_app* app, int32_t cmd)
device->CreationParams.DriverType == video::EDT_OGLES2) device->CreationParams.DriverType == video::EDT_OGLES2)
{ {
video::COGLES2Driver* driver = (video::COGLES2Driver*)(device->VideoDriver); video::COGLES2Driver* driver = (video::COGLES2Driver*)(device->VideoDriver);
driver->reloadEGLSurface(app->window); driver->getEGLContext()->reloadEGLSurface(app->window);
} }
} }

View File

@ -369,6 +369,10 @@ namespace video
//! Get bridge calls. //! Get bridge calls.
COGLES2CallBridge* getBridgeCalls() const; COGLES2CallBridge* getBridgeCalls() const;
#if defined(_IRR_COMPILE_WITH_EGL_)
ContextEGL* getEGLContext() {return EglContext;}
#endif
private: private:
// Bridge calls. // Bridge calls.