[vlc-commits] avcodec: fix black screen with hdtv-fixed videos

Thomas Guillem git at videolan.org
Thu Mar 29 15:20:30 CEST 2018


vlc/vlc-3.0 | branch: master | Thomas Guillem <thomas at gllm.fr> | Thu Mar 29 15:08:13 2018 +0200| [6c54abb7472548f55a0f87bf98a61d729ccc6d32] | committer: Thomas Guillem

avcodec: fix black screen with hdtv-fixed videos

In case of indirect rendering.

This fixes a regression from dfb767189073493336df0cf43f7d0b6bf51f63e3

Fixes #20175

(cherry picked from commit c988b8d58b01ef6d628e3051774a2032dd7f6b7d)
Signed-off-by: Thomas Guillem <thomas at gllm.fr>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=6c54abb7472548f55a0f87bf98a61d729ccc6d32
---

 modules/codec/avcodec/video.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/codec/avcodec/video.c b/modules/codec/avcodec/video.c
index 9df2c413f8..a25f6ca461 100644
--- a/modules/codec/avcodec/video.c
+++ b/modules/codec/avcodec/video.c
@@ -351,8 +351,8 @@ static int lavc_CopyPicture(decoder_t *dec, picture_t *pic, AVFrame *frame)
                 sys->p_context->pix_fmt, (name != NULL) ? name : "unknown");
         return VLC_EGENERIC;
     } else if (fourcc != pic->format.i_chroma
-     || frame->width != (int) pic->format.i_visible_width
-     || frame->height != (int) pic->format.i_visible_height)
+     || frame->width > (int) pic->format.i_width
+     || frame->height > (int) pic->format.i_height)
     {
         msg_Warn(dec, "dropping frame because the vout changed");
         return VLC_EGENERIC;



More information about the vlc-commits mailing list