Commit 83bf9fb6 authored by Michael Niedermayer's avatar Michael Niedermayer

ffv1: move clear_state() to clear_slice_state() in encoding threads

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 68a9194b
......@@ -1196,6 +1196,8 @@ static int encode_slice(AVCodecContext *c, void *arg){
AVFrame * const p= &f->picture;
const int ps= (f->bits_per_raw_sample>8)+1;
if(p->key_frame)
clear_slice_state(f, fs);
if(f->version > 2){
encode_slice_header(f, fs);
}
......@@ -1252,7 +1254,6 @@ static int encode_frame(AVCodecContext *avctx, AVPacket *pkt,
p->key_frame= 1;
f->gob_count++;
write_header(f);
clear_state(f);
}else{
put_rac(c, &keystate, 0);
p->key_frame= 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment