diff --git a/android/build.gradle b/android/build.gradle index 903c3831bc..c7eefd051b 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -454,6 +454,8 @@ task cleanDependencies(type: Delete) { delete 'app/src/main/res/values/libs.xml' } +// FIXME this code is prototyping the desired functionality for doing build time binary dependency resolution. +// See the comment on the qtBundle task above /* // FIXME derive the path from the gradle environment def toolchain = [ diff --git a/libraries/entities-renderer/CMakeLists.txt b/libraries/entities-renderer/CMakeLists.txt index cf94ecc37c..19987197b8 100644 --- a/libraries/entities-renderer/CMakeLists.txt +++ b/libraries/entities-renderer/CMakeLists.txt @@ -15,4 +15,4 @@ include_hifi_library_headers(avatars) include_hifi_library_headers(controllers) target_bullet() -target_polyvox() \ No newline at end of file +target_polyvox() diff --git a/libraries/gl/src/gl/Config.h b/libraries/gl/src/gl/Config.h index b1bafe1ba6..cdf86675c6 100644 --- a/libraries/gl/src/gl/Config.h +++ b/libraries/gl/src/gl/Config.h @@ -15,6 +15,11 @@ #include #if defined(Q_OS_ANDROID) +#define HIFI_GLES +#define HIFI_EGL +#endif + +#if defined(HIFI_GLES) // Minimum GL ES version required is 3.2 #define GL_MIN_VERSION_MAJOR 0x03 #define GL_MIN_VERSION_MINOR 0x02 @@ -30,9 +35,11 @@ #define MINIMUM_GL_VERSION ((GL_MIN_VERSION_MAJOR << 8) | GL_MIN_VERSION_MINOR) -#if defined(Q_OS_ANDROID) - +#if defined(HIFI_GLES) #include +#endif + +#if defined(HIFI_GLES) #include #define GL_DEPTH_COMPONENT32_OES 0x81A7 @@ -55,7 +62,7 @@ extern "C" { extern PFNGLFRAMEBUFFERTEXTUREEXTPROC glFramebufferTextureEXT; } -#else // !defined(Q_OS_ANDROID) +#else // !defined(HIFI_GLES) #define GL_GLEXT_PROTOTYPES 1 #include diff --git a/libraries/gl/src/gl/GLHelpers.cpp b/libraries/gl/src/gl/GLHelpers.cpp index 0e3321d99d..722253c26f 100644 --- a/libraries/gl/src/gl/GLHelpers.cpp +++ b/libraries/gl/src/gl/GLHelpers.cpp @@ -28,7 +28,7 @@ const QSurfaceFormat& getDefaultOpenGLSurfaceFormat() { static QSurfaceFormat format; static std::once_flag once; std::call_once(once, [] { -#if defined(Q_OS_ANDROID) +#if defined(HIFI_GLES) format.setRenderableType(QSurfaceFormat::OpenGLES); format.setRedBufferSize(8); format.setGreenBufferSize(8); diff --git a/libraries/gl/src/gl/OffscreenGLCanvas.cpp b/libraries/gl/src/gl/OffscreenGLCanvas.cpp index d5d104098f..67eb3520c9 100644 --- a/libraries/gl/src/gl/OffscreenGLCanvas.cpp +++ b/libraries/gl/src/gl/OffscreenGLCanvas.cpp @@ -52,16 +52,15 @@ bool OffscreenGLCanvas::create(QOpenGLContext* sharedContext) { _offscreenSurface->setFormat(_context->format()); _offscreenSurface->create(); + + // Due to a https://bugreports.qt.io/browse/QTBUG-65125 we can't rely on `isValid` + // to determine if the offscreen surface was successfully created, so we use + // makeCurrent as a proxy test. Bug is fixed in Qt 5.9.4 #if defined(Q_OS_ANDROID) if (!_context->makeCurrent(_offscreenSurface)) { qFatal("Unable to make offscreen surface current"); } #else - // For some reason, the offscreen surface is considered invalid on android - // possibly because of a bad format? Would need to add some logging to the - // eglpbuffer implementation used from the android platform plugin. - // Alternatively investigate the use of an invisible surface view to do - // a 'native' offscreen surface if (!_offscreenSurface->isValid()) { qFatal("Offscreen surface is invalid"); } diff --git a/libraries/script-engine/src/FileScriptingInterface.cpp b/libraries/script-engine/src/FileScriptingInterface.cpp index e475a2e445..1472e53045 100644 --- a/libraries/script-engine/src/FileScriptingInterface.cpp +++ b/libraries/script-engine/src/FileScriptingInterface.cpp @@ -23,6 +23,7 @@ #include #include +// FIXME quazip hasn't been built on the android toolchain #if !defined(Q_OS_ANDROID) #include #include @@ -73,6 +74,7 @@ void FileScriptingInterface::runUnzip(QString path, QUrl url, bool autoAdd, bool QStringList FileScriptingInterface::unzipFile(QString path, QString tempDir) { #if defined(Q_OS_ANDROID) + // FIXME quazip hasn't been built on the android toolchain return QStringList(); #else QDir dir(path); @@ -137,6 +139,7 @@ void FileScriptingInterface::recursiveFileScan(QFileInfo file, QString* dirName) return; }*/ QFileInfoList files; + // FIXME quazip hasn't been built on the android toolchain #if !defined(Q_OS_ANDROID) if (file.fileName().contains(".zip")) { qCDebug(scriptengine) << "Extracting archive: " + file.fileName();