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: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7849>
This commit is contained in:
Nicolas Dufresne 2024-11-14 15:56:50 -05:00 committed by GStreamer Marge Bot
parent e9b2e98ef7
commit 9f707f6c64

View file

@ -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 * the tile dimension. This is because the shader needs to know the padded
* size in order to correctly sample into these special buffer. * 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->width = meta->width;
out_info->height = meta->height; out_info->height = meta->height;