Instead of returning nothing when we detect the xvid skipped frame, we could return the last decoded frame, if we do have one. --- libavcodec/h263dec.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c index bcb2b08bb0..e1667bcbc1 100644 --- a/libavcodec/h263dec.c +++ b/libavcodec/h263dec.c @@ -507,8 +507,15 @@ retry: s->height= avctx->coded_height; } } - if (ret == FRAME_SKIPPED) + if (ret == FRAME_SKIPPED) { + if (s->next_picture_ptr) { + if ((ret = av_frame_ref(pict, s->next_picture_ptr->f)) < 0) { + return ret; + } + *got_frame = 1; + } return get_consumed_bytes(s, buf_size); + } /* skip if the header was thrashed */ if (ret < 0) { -- 2.15.0.rc1.287.g2b38de12cc-goog _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel