aboutsummaryrefslogtreecommitdiff
path: root/render
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2023-11-29 12:16:45 +0100
committerAlexander Orzechowski <alex@ozal.ski>2023-11-29 15:28:50 +0000
commit62b6c492d59e956e30cb409c730b4f84d33f8f6e (patch)
treecb93a37322a90cfc11d0f82b13321e0e3300e1ec /render
parent91182266342587cf01b2e625dbf0682df149f3db (diff)
render/gles2: check external-only flag in get_or_create_buffer()
If the external-only flag is set, then the EGLImage is only supported for use with GL_TEXTURE_EXTERNAL_OES texture targets. In particular, the EGLImage cannot be bound to a RBO.
Diffstat (limited to 'render')
-rw-r--r--render/gles2/renderer.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/render/gles2/renderer.c b/render/gles2/renderer.c
index e61c276c..0797adc8 100644
--- a/render/gles2/renderer.c
+++ b/render/gles2/renderer.c
@@ -122,6 +122,11 @@ static struct wlr_gles2_buffer *get_or_create_buffer(struct wlr_gles2_renderer *
goto error_buffer;
}
+ if (external_only) {
+ wlr_log(WLR_ERROR, "DMA-BUF format is external-only");
+ goto error_image;
+ }
+
push_gles2_debug(renderer);
glGenRenderbuffers(1, &buffer->rbo);