diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2019-08-19 21:12:09 +0200 |
---|---|---|
committer | paolo <paolo.angelelli@qt.io> | 2019-08-20 10:48:09 +0200 |
commit | aa8bb4d64864e0c3cfb9374a367e783602b75eba (patch) | |
tree | d87d57099e03156246b3aaa9452cde5075cf45e8 /src/plugins/geoservices | |
parent | 63cd689a400ee57f7e898e81290366c266537982 (diff) | |
download | qtlocation-aa8bb4d64864e0c3cfb9374a367e783602b75eba.tar.gz |
Improve debugging in mapboxgl plugin when running without opengl backend
Change-Id: I252c163ad9296b52f14b83710fda0a469f882d73
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Diffstat (limited to 'src/plugins/geoservices')
-rw-r--r-- | src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp b/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp index ed36cd5f..b0967499 100644 --- a/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp +++ b/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp @@ -54,6 +54,7 @@ #include <QtQuick/QQuickWindow> #include <QtQuick/QSGImageNode> #include <QtQuick/private/qsgtexture_p.h> +#include <QtQuick/private/qsgcontext_p.h> // for debugging the context name #include <QMapboxGL> @@ -101,6 +102,11 @@ QSGNode *QGeoMapMapboxGLPrivate::updateSceneGraph(QSGNode *node, QQuickWindow *w QOpenGLContext *currentCtx = QOpenGLContext::currentContext(); if (!currentCtx) { qWarning("QOpenGLContext is NULL!"); + qWarning() << "You are running on QSG backend " << QSGContext::backend(); + qWarning("The MapboxGL plugin works with both Desktop and ES 2.0+ OpenGL versions."); + qWarning("Verify that your Qt is built with OpenGL, and what kind of OpenGL."); + qWarning("To force using a specific OpenGL version, check QSurfaceFormat::setRenderableType and QSurfaceFormat::setDefaultFormat"); + return node; } if (m_useFBO) { |