[FFmpeg-cvslog] Do not overwrite VDPAU structures in ff_MPV_frame_start().

Carl Eugen Hoyos git at videolan.org
Fri Apr 18 06:46:51 CEST 2014


ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Fri Apr 18 04:56:34 2014 +0200| [941b2240f2ce59c41f4a9ffec88c512f64c75613] | committer: Carl Eugen Hoyos

Do not overwrite VDPAU structures in ff_MPV_frame_start().

Fixes crashes with VDR and MPlayer as reported by irc user crow.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=941b2240f2ce59c41f4a9ffec88c512f64c75613
---

 libavcodec/mpegvideo.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c
index 45fedcb..8b4e6ed 100644
--- a/libavcodec/mpegvideo.c
+++ b/libavcodec/mpegvideo.c
@@ -1789,7 +1789,7 @@ int ff_MPV_frame_start(MpegEncContext *s, AVCodecContext *avctx)
             return -1;
         }
 
-        if (!avctx->hwaccel) {
+        if (!avctx->hwaccel && !(avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU)) {
             for(i=0; i<avctx->height; i++)
                 memset(s->last_picture_ptr->f->data[0] + s->last_picture_ptr->f->linesize[0]*i,
                        0x80, avctx->width);



More information about the ffmpeg-cvslog mailing list