]> git.proxmox.com Git - mirror_qemu.git/blobdiff - ui/console-gl.c
Merge tag 'pull-maintainer-may24-160524-2' of https://gitlab.com/stsquad/qemu into...
[mirror_qemu.git] / ui / console-gl.c
index 7c9894a51d99aae7421f5a4abfd212ed4ceab81d..103b954017fe8d603001dc1b948344bfb4aad022 100644 (file)
@@ -49,7 +49,11 @@ void surface_gl_create_texture(QemuGLShader *gls,
     assert(gls);
     assert(QEMU_IS_ALIGNED(surface_stride(surface), surface_bytes_per_pixel(surface)));
 
-    switch (surface->format) {
+    if (surface->texture) {
+        return;
+    }
+
+    switch (surface_format(surface)) {
     case PIXMAN_BE_b8g8r8x8:
     case PIXMAN_BE_b8g8r8a8:
         surface->glformat = GL_BGRA_EXT;