Commit a4397fa9 authored by Baptiste Coudurier's avatar Baptiste Coudurier

fix temporal offet of ipbb sequences, simplification welcome

Originally committed as revision 16940 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent b17f1a07
......@@ -894,9 +894,13 @@ static int mxf_write_index_table_segment(AVFormatContext *s)
for (j = i+1; j < mxf->edit_units_count; j++) {
temporal_offset++;
if (mxf->index_entries[j].flags & 0x10) { // backward prediction
// next is not b, so is reordered
if (!(mxf->index_entries[i+1].flags & 0x10))
temporal_offset = -temporal_offset;
// next is not b, so is reordered
if (!(mxf->index_entries[i+1].flags & 0x10)) {
if ((mxf->index_entries[i].flags & 0x11) == 0) // i frame
temporal_offset = 0;
else
temporal_offset = -temporal_offset;
}
break;
}
}
......
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