Commit 1a392fc5 authored by Michael Niedermayer's avatar Michael Niedermayer

ffv1: Store a flag in the global header that indicates if all frames are keyframes

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent cc5c1559
......@@ -106,6 +106,7 @@ typedef struct FFV1Context {
int16_t *sample_buffer;
int ec;
int intra;
int slice_damaged;
int key_frame_ok;
......
......@@ -498,6 +498,8 @@ static int read_extra_header(FFV1Context *f)
if (f->version > 2) {
f->ec = get_symbol(c, state, 0);
if (f->minor_version > 2)
f->intra = get_symbol(c, state, 0);
}
if (f->version > 2) {
......
......@@ -534,7 +534,7 @@ static int write_extradata(FFV1Context *f)
put_symbol(c, state, f->version, 0);
if (f->version > 2) {
if (f->version == 3)
f->minor_version = 2;
f->minor_version = 3;
put_symbol(c, state, f->minor_version, 0);
}
......@@ -575,6 +575,7 @@ static int write_extradata(FFV1Context *f)
if (f->version > 2) {
put_symbol(c, state, f->ec, 0);
put_symbol(c, state, f->intra = (f->avctx->gop_size < 2), 0);
}
f->avctx->extradata_size = ff_rac_terminate(c);
......
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