Commit 0d5e615c authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit '27b0e6eb'

* commit '27b0e6eb':
  h264: drop needs_realloc
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 215430e0 27b0e6eb
......@@ -380,9 +380,6 @@ void ff_h264_free_tables(H264Context *h, int free_rbsp)
ff_h264_unref_picture(h, &h->DPB[i]);
memset(h->delayed_pic, 0, sizeof(h->delayed_pic));
av_freep(&h->DPB);
} else if (h->DPB) {
for (i = 0; i < H264_MAX_PICTURE_COUNT; i++)
h->DPB[i].needs_realloc = 1;
}
h->cur_pic_ptr = NULL;
......
......@@ -322,7 +322,6 @@ typedef struct H264Picture {
int mbaff; ///< 1 -> MBAFF frame 0-> not MBAFF
int field_picture; ///< whether or not picture was encoded in separate fields
int needs_realloc; ///< picture needs to be reallocated (eg due to a frame size change)
int reference;
int recovered; ///< picture at IDR or recovery point + recovery count
int invalid_gap;
......
......@@ -114,7 +114,6 @@ int ff_h264_ref_picture(H264Context *h, H264Picture *dst, H264Picture *src)
dst->long_ref = src->long_ref;
dst->mbaff = src->mbaff;
dst->field_picture = src->field_picture;
dst->needs_realloc = src->needs_realloc;
dst->reference = src->reference;
dst->crop = src->crop;
dst->crop_left = src->crop_left;
......
......@@ -293,8 +293,6 @@ static inline int pic_is_unused(H264Context *h, H264Picture *pic)
{
if (!pic->f.buf[0])
return 1;
if (pic->needs_realloc && !(pic->reference & DELAYED_PIC_REF))
return 1;
return 0;
}
......@@ -309,11 +307,6 @@ static int find_unused_picture(H264Context *h)
if (i == H264_MAX_PICTURE_COUNT)
return AVERROR_INVALIDDATA;
if (h->DPB[i].needs_realloc) {
h->DPB[i].needs_realloc = 0;
ff_h264_unref_picture(h, &h->DPB[i]);
}
return i;
}
......
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