va: Delete the useless align expand in va_pool_set_config().

The base va decoder's video_align is just used for calculation the
real decoded buffer's width and height. While the gst_video_info_align
just calculate the offset and stride based on the video_align. But
all the offsets and strides are overwritten in gst_va_dmabuf_allocator_try
or gst_va_allocator_try, which make that calculation useless.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2298>
This commit is contained in:
He Junyan 2021-06-03 00:07:05 +08:00 committed by GStreamer Marge Bot
parent 03d3e0fe73
commit 98cf9ce6f5

View file

@ -119,10 +119,6 @@ gst_va_pool_set_config (GstBufferPool * pool, GstStructure * config)
width += video_align.padding_left + video_align.padding_right; width += video_align.padding_left + video_align.padding_right;
height += video_align.padding_bottom + video_align.padding_top; height += video_align.padding_bottom + video_align.padding_top;
/* apply the alignment to the info */
if (!gst_video_info_align (&caps_info, &video_align))
goto failed_to_align;
} }
/* update allocation info with aligned size */ /* update allocation info with aligned size */
@ -202,11 +198,6 @@ wrong_caps:
"failed getting geometry from caps %" GST_PTR_FORMAT, caps); "failed getting geometry from caps %" GST_PTR_FORMAT, caps);
return FALSE; return FALSE;
} }
failed_to_align:
{
GST_WARNING_OBJECT (vpool, "Failed to align");
return FALSE;
}
failed_allocator: failed_allocator:
{ {
GST_WARNING_OBJECT (vpool, "Failed to set format to allocator"); GST_WARNING_OBJECT (vpool, "Failed to set format to allocator");