summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/eglfs
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@theqtcompany.com>2016-01-26 14:35:50 +0100
committerLiang Qi <liang.qi@theqtcompany.com>2016-01-26 16:27:28 +0100
commita15c3d086dafea83e4760f0b447be43d26b80697 (patch)
treefd224a3f83942ff4c432e1e3a3f8583d14d6a11c /src/plugins/platforms/eglfs
parent87abfd351af6309691d921ca0aef077d74df4732 (diff)
parent397061a6a92db9f962360d5db96f69b315f93074 (diff)
Merge remote-tracking branch 'origin/5.6' into dev
Conflicts: src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java src/dbus/qdbusconnection_p.h src/dbus/qdbusintegrator.cpp src/dbus/qdbusintegrator_p.h tests/auto/corelib/io/qdir/qdir.pro tests/auto/corelib/io/qiodevice/tst_qiodevice.cpp Change-Id: I3d3fd07aed015c74b1f545f1327aa73d5f365fcc
Diffstat (limited to 'src/plugins/platforms/eglfs')
-rw-r--r--src/plugins/platforms/eglfs/qeglfscontext.cpp10
-rw-r--r--src/plugins/platforms/eglfs/qeglfscontext.h1
2 files changed, 11 insertions, 0 deletions
diff --git a/src/plugins/platforms/eglfs/qeglfscontext.cpp b/src/plugins/platforms/eglfs/qeglfscontext.cpp
index 1bb4918948..229ac6bbd9 100644
--- a/src/plugins/platforms/eglfs/qeglfscontext.cpp
+++ b/src/plugins/platforms/eglfs/qeglfscontext.cpp
@@ -91,6 +91,16 @@ void QEglFSContext::destroyTemporaryOffscreenSurface(EGLSurface surface)
}
}
+void QEglFSContext::runGLChecks()
+{
+ // Note that even though there is an EGL context current here,
+ // QOpenGLContext and QOpenGLFunctions are not yet usable at this stage.
+ const char *renderer = reinterpret_cast<const char *>(glGetString(GL_RENDERER));
+ // Be nice and warn about a common source of confusion.
+ if (renderer && strstr(renderer, "llvmpipe"))
+ qWarning("Running on a software rasterizer (LLVMpipe), expect limited performance.");
+}
+
void QEglFSContext::swapBuffers(QPlatformSurface *surface)
{
// draw the cursor
diff --git a/src/plugins/platforms/eglfs/qeglfscontext.h b/src/plugins/platforms/eglfs/qeglfscontext.h
index ffe105cdac..b861ae5329 100644
--- a/src/plugins/platforms/eglfs/qeglfscontext.h
+++ b/src/plugins/platforms/eglfs/qeglfscontext.h
@@ -54,6 +54,7 @@ public:
EGLSurface eglSurfaceForPlatformSurface(QPlatformSurface *surface) Q_DECL_OVERRIDE;
EGLSurface createTemporaryOffscreenSurface() Q_DECL_OVERRIDE;
void destroyTemporaryOffscreenSurface(EGLSurface surface) Q_DECL_OVERRIDE;
+ void runGLChecks() Q_DECL_OVERRIDE;
void swapBuffers(QPlatformSurface *surface) Q_DECL_OVERRIDE;
private: