Make tst_QOpenGLWindow pass on platforms where the default FBO != 0
The test would fail on Wayland with window decorations enabled because there window content is drawn to an FBO before it's blended with the window decorations (also drawn by the client). Task-number: QTBUG-51741 Change-Id: I7c74ad235c6a2d50231a9f863da1810675dd4eae Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>bb10
parent
9e99dba4a2
commit
13f09acb66
|
|
@ -252,7 +252,7 @@ public:
|
|||
|
||||
GLuint fbo = 0xFFFF;
|
||||
QOpenGLContext::currentContext()->functions()->glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint *) &fbo);
|
||||
QCOMPARE(fbo, GLuint(0));
|
||||
QCOMPARE(fbo, QOpenGLContext::currentContext()->defaultFramebufferObject());
|
||||
}
|
||||
|
||||
void paintGL() override {
|
||||
|
|
@ -264,7 +264,7 @@ public:
|
|||
// Using PartialUpdateBlend so paintGL() targets a user fbo, not the default.
|
||||
GLuint fbo = 0xFFFF;
|
||||
QOpenGLContext::currentContext()->functions()->glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint *) &fbo);
|
||||
QVERIFY(fbo != 0);
|
||||
QVERIFY(fbo != QOpenGLContext::currentContext()->defaultFramebufferObject());
|
||||
QCOMPARE(fbo, defaultFramebufferObject());
|
||||
}
|
||||
|
||||
|
|
@ -276,7 +276,7 @@ public:
|
|||
|
||||
GLuint fbo = 0xFFFF;
|
||||
QOpenGLContext::currentContext()->functions()->glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint *) &fbo);
|
||||
QCOMPARE(fbo, GLuint(0));
|
||||
QCOMPARE(fbo, QOpenGLContext::currentContext()->defaultFramebufferObject());
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue