From 9f707f6c64c80e2299698c6461406de5e59783eb Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Thu, 14 Nov 2024 15:56:50 -0500 Subject: [PATCH] glupload: dmabuf: Only pass padded size for indirect tiled handling We only require out_info to hold on padded width/height when using our internal detiling shaders. Doing so for direct upload leads to the image being scaled down in a way that the padding is displayed. Part-of: --- subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c b/subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c index 78b9731869..0d05abeadc 100644 --- a/subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c +++ b/subprojects/gst-plugins-base/gst-libs/gst/gl/gstglupload.c @@ -1551,7 +1551,8 @@ _dma_buf_upload_accept (gpointer impl, GstBuffer * buffer, GstCaps * in_caps, * the tile dimension. This is because the shader needs to know the padded * size in order to correctly sample into these special buffer. */ - if (meta && GST_VIDEO_FORMAT_INFO_IS_TILED (out_info->finfo)) { + if (!dmabuf->direct && meta && + GST_VIDEO_FORMAT_INFO_IS_TILED (out_info->finfo)) { out_info->width = meta->width; out_info->height = meta->height;