aboutsummaryrefslogtreecommitdiffstats
path: root/src/particles
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-11-23 10:49:37 +0100
committerLiang Qi <liang.qi@qt.io>2016-11-23 10:49:37 +0100
commit5d4cbf4094c9b290626aab89e4bd92edd29ce49f (patch)
treeeac893652c724f057fba493688b16e212fd844dd /src/particles
parent13cf5f02ce788f19a73e5d5c3da76e57291761a5 (diff)
parent07cde200e55ee03bf9e2f9af89c20f91072deccc (diff)
Merge remote-tracking branch 'origin/5.8' into dev
Conflicts: src/qml/jsruntime/qv4object_p.h Change-Id: Iff4d3aba7710a999b8befdc493cbe959e1ce02f9
Diffstat (limited to 'src/particles')
-rw-r--r--src/particles/qquickimageparticle.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/particles/qquickimageparticle.cpp b/src/particles/qquickimageparticle.cpp
index c68153aca8..e6b921792f 100644
--- a/src/particles/qquickimageparticle.cpp
+++ b/src/particles/qquickimageparticle.cpp
@@ -1292,14 +1292,16 @@ void QQuickImageParticle::finishBuildParticleNodes(QSGNode** node)
// OS X 10.8.3 introduced a bug in the AMD drivers, for at least the 2011 macbook pros,
// causing point sprites who read gl_PointCoord in the frag shader to come out as
// green-red blobs.
- if (perfLevel < Deformable && strstr((char *) glGetString(GL_VENDOR), "ATI")) {
+ const GLubyte *glVendor = QOpenGLContext::currentContext()->functions()->glGetString(GL_VENDOR);
+ if (perfLevel < Deformable && glVendor && strstr((char *) glVendor, "ATI")) {
perfLevel = Deformable;
}
#endif
#ifdef Q_OS_LINUX
// Nouveau drivers can potentially freeze a machine entirely when taking the point-sprite path.
- if (perfLevel < Deformable && strstr((const char *) glGetString(GL_VENDOR), "nouveau"))
+ const GLubyte *glVendor = QOpenGLContext::currentContext()->functions()->glGetString(GL_VENDOR);
+ if (perfLevel < Deformable && glVendor && strstr((const char *) glVendor, "nouveau"))
perfLevel = Deformable;
#endif