mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-11 09:35:22 +00:00
h264: don't initialize missing pictures when using a hwaccel
Writing into uninitialized hw surfaces is not supported and triggers an assert inside avpriv_color_frame Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
a56fd9edab
commit
1d6f6ff4d9
@ -1704,7 +1704,7 @@ int ff_h264_frame_start(H264Context *h)
|
|||||||
|
|
||||||
if ((ret = alloc_picture(h, pic)) < 0)
|
if ((ret = alloc_picture(h, pic)) < 0)
|
||||||
return ret;
|
return ret;
|
||||||
if(!h->sync)
|
if(!h->sync && !h->avctx->hwaccel)
|
||||||
avpriv_color_frame(&pic->f, c);
|
avpriv_color_frame(&pic->f, c);
|
||||||
|
|
||||||
h->cur_pic_ptr = pic;
|
h->cur_pic_ptr = pic;
|
||||||
|
Loading…
Reference in New Issue
Block a user