diff options
author | Ander Conselvan de Oliveira <ander.deoliveira@mapbox.com> | 2018-08-28 14:32:30 +0300 |
---|---|---|
committer | Ander Conselvan de Oliveira <ander.deoliveira@mapbox.com> | 2018-08-30 12:28:00 +0300 |
commit | 520849f5811389c4cee8cf3d5117ecdca9af045b (patch) | |
tree | 4182c2f063597ea1544d8b65dcd5a62fb3c28d55 | |
parent | a22f1f34097b7c5335362b3faf98c1c8391d6d4e (diff) | |
download | qtlocation-mapboxgl-upstream/anderco-angle-no-debug.tar.gz |
[core] Disable debugging extension when running on ANGLE over Direct3Dupstream/anderco-angle-no-debug
The ANGLE implementation of GL_KHR_debug on Direct3D seems to be broken
leading to a bad_alloc being thrown when running with a debug build, so
disable it in that platform.
-rw-r--r-- | src/mbgl/gl/context.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mbgl/gl/context.cpp b/src/mbgl/gl/context.cpp index 0b40cef613..5fb249c802 100644 --- a/src/mbgl/gl/context.cpp +++ b/src/mbgl/gl/context.cpp @@ -127,7 +127,11 @@ void Context::initializeExtensions(const std::function<gl::ProcAddress(const cha const std::string renderer = reinterpret_cast<const char*>(MBGL_CHECK_ERROR(glGetString(GL_RENDERER))); Log::Info(Event::General, "GPU Identifier: %s", renderer.c_str()); - debugging = std::make_unique<extension::Debugging>(fn); + // Block ANGLE on Direct3D since the debugging extension is causing crashes + if (renderer.find("ANGLE") == std::string::npos + || renderer.find("Direct3D") == std::string::npos) { + debugging = std::make_unique<extension::Debugging>(fn); + } // Block Adreno 2xx, 3xx as it crashes on glBuffer(Sub)Data // Block ARM Mali-T720 (in some MT8163 chipsets) as it crashes on glBindVertexArray |