st/vdpau: don't re-allocate interlaced buffer with packed YUV format

It caused corruption, when vlVdpVideoSurfacePutBitsYCbCr putting YUV to the fields

Cc: mesa-stable@lists.freedesktop.org
Cc: Andy Furniss <adf.lists@gmail.com>
Tested-by: Andy Furniss <adf.lists@gmail.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
This commit is contained in:
Leo Liu
2017-09-30 22:19:49 -04:00
parent ae61fe4982
commit 327480d10f
@@ -350,6 +350,8 @@ vlVdpVideoSurfacePutBitsYCbCr(VdpVideoSurface surface,
/* adjust the template parameters */
p_surf->templat.buffer_format = nformat;
if (nformat == PIPE_FORMAT_YUYV || nformat == PIPE_FORMAT_UYVY)
p_surf->templat.interlaced = false;
/* and try to create the video buffer with the new format */
p_surf->video_buffer = pipe->create_video_buffer(pipe, &p_surf->templat);