diff options
author | Laszlo Agocs <laszlo.agocs@digia.com> | 2014-02-04 13:04:38 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-02-05 13:46:41 +0100 |
commit | 2d67bf07fee5e0ad65b89030a440a3b73cb1d3d3 (patch) | |
tree | 0c0641b7db67253431898414751fd6f80edb5e98 /src/gui/opengl/qopenglframebufferobject.cpp | |
parent | 760ad40700ee5c6db969c376e053f9c4806e90a6 (diff) |
Do not query max samples on gles
Querying GL_MAX_SAMPLES is not supported in GLES2.
Avoiding the call also makes us play nice with Mesa in debug
mode since it gets rid of the warnings about the failing
glGetIntegerv call.
Change-Id: I05e501cc11af41a54fefc34ab919c5191e4f3f0a
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Diffstat (limited to 'src/gui/opengl/qopenglframebufferobject.cpp')
-rw-r--r-- | src/gui/opengl/qopenglframebufferobject.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/opengl/qopenglframebufferobject.cpp b/src/gui/opengl/qopenglframebufferobject.cpp index c06ba40b47..14d7fac9f7 100644 --- a/src/gui/opengl/qopenglframebufferobject.cpp +++ b/src/gui/opengl/qopenglframebufferobject.cpp @@ -432,9 +432,11 @@ void QOpenGLFramebufferObjectPrivate::init(QOpenGLFramebufferObject *, const QSi samples = 0; } +#ifndef QT_OPENGL_ES_2 GLint maxSamples; glGetIntegerv(GL_MAX_SAMPLES, &maxSamples); samples = qBound(0, int(samples), int(maxSamples)); +#endif size = sz; target = texture_target; |