summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDominik Holland <dominik.holland@pelagicore.com>2016-06-02 13:16:07 +0200
committerJani Heikkinen <jani.heikkinen@qt.io>2016-06-02 14:13:15 +0000
commit0918ffa9f32a6ff59f101ffd80c2325f2fbd0e6d (patch)
tree7fe0fb20b5dfd96afbeb676b854ff48a8e0ef4bd
parent2a593a98fd2d58f942e9171f3d5b0c851fefe4aa (diff)
eglstream: Fixed problem when resizing a window
It seems we are not allowed to delete the texture when the buffer is destroyed as this breaks the following eglstream and shows a empty texture. We need to check with NVIDIA, but the deletion of the texture might be handled by wayland Change-Id: Icd20594498d83c57458f77b9e91f0980f8c2d173 Reviewed-by: Robert Griebl <robert.griebl@pelagicore.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
-rw-r--r--src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp
index 1c009d342..4416d103c 100644
--- a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp
+++ b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp
@@ -360,10 +360,8 @@ void WaylandEglClientBufferIntegrationPrivate::handle_buffer_destroy(wl_listener
BufferState state = self->buffers.take(buffer);
- /* TODO This texture shouldn't get deleted here as the compositor might want to show an transition. But at the same time we need to make sure
- that the texture is deleted properly although if the compositor didn't use it (e.g. by creating a quick item)*/
- if (state.eglstream_texture)
- glDeleteTextures(1, &state.eglstream_texture);
+ // We would need to delete the texture of the egl_stream here, but we can't as this breaks the
+ // texture of the new stream when the window is resized. It seems wayland takes care to delete the texture for us.
for (int i = 0; i < state.egl_images.size(); i++)
self->egl_destroy_image(self->egl_display, state.egl_images[i]);