Browse Source

flv: Initialize initial frame to 16

Fixes Ticket563

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n0.9
Michael Niedermayer 14 years ago
parent
commit
284aa07932
1 changed files with 6 additions and 0 deletions
  1. +6
    -0
      libavcodec/mpegvideo.c

+ 6
- 0
libavcodec/mpegvideo.c View File

@@ -1132,6 +1132,12 @@ int MPV_frame_start(MpegEncContext *s, AVCodecContext *avctx)
s->last_picture_ptr->f.key_frame = 0;
if(ff_alloc_picture(s, s->last_picture_ptr, 0) < 0)
return -1;

if(s->codec_id == CODEC_ID_FLV1){
for(i=0; i<s->height; i++)
memset(s->last_picture_ptr->f.data[0] + s->last_picture_ptr->f.linesize[0]*i, 16, s->width);
}

ff_thread_report_progress((AVFrame*)s->last_picture_ptr, INT_MAX, 0);
ff_thread_report_progress((AVFrame*)s->last_picture_ptr, INT_MAX, 1);
}


Loading…
Cancel
Save