From d34c9a609c1bb9a0d1225a250e90bc43ba277c9b Mon Sep 17 00:00:00 2001 From: Olivier Blin <olivier.blin@softathome.com> Date: Tue, 17 Feb 2015 20:21:56 +0100 Subject: [PATCH] qwindow-compositor: fix rendering shm NPOT textures with OpenGL ES2 Always use GL_CLAMP_TO_EDGE instead of GL_REPEAT, since OpenGL ES2 doesn't support NPOT textures in combination with GL_REPEAT by default, and repeat is not needed anyway. See also qtbase commits: 8dfeb1c374972f06759a92b4edc5d6a18b96ccec 8ab1323842433fb6b45e7d6f381b4b9710a81da9 72558e810d9b3493dabfc936fa6c8bf3c3f3b49c Change-Id: I01770fe3352da05baf6898d63c091bfae95e7a98 Reviewed-by: Gunnar Sletta <gunnar@sletta.org> --- examples/wayland/qwindow-compositor/qwindowcompositor.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/wayland/qwindow-compositor/qwindowcompositor.cpp b/examples/wayland/qwindow-compositor/qwindowcompositor.cpp index c933152d8..ab6722a0b 100644 --- a/examples/wayland/qwindow-compositor/qwindowcompositor.cpp +++ b/examples/wayland/qwindow-compositor/qwindowcompositor.cpp @@ -88,6 +88,7 @@ public: if (bufferRef) { if (bufferRef.isShm()) { shmTex = new QOpenGLTexture(bufferRef.image(), QOpenGLTexture::DontGenerateMipMaps); + shmTex->setWrapMode(QOpenGLTexture::ClampToEdge); texture = shmTex->textureId(); } else { texture = bufferRef.createTexture(); -- GitLab