ffmpeg/tests/ref/fate/h264_mp4toannexb_ticket5927
Andreas Rheinhardt 518bbe9eac h264_mp4toannexb: Try to avoid four byte startcodes
According to the H.264 specifications, the only NAL units that need to
have four byte startcodes in H.264 Annex B format are SPS/PPS units and
units that start a new access unit. Before af7e953a, the first of these
conditions wasn't upheld as already existing in-band parameter sets
would not automatically be written with a four byte startcode, but only
when they already were at the beginning of their input packets. But it
made four byte startcodes be used too often as every unit that is written
together with a parameter set that is inserted from extradata received a
four byte startcode although a three byte start code would suffice
unless the unit itself were a parameter set.

FATE has been updated to reflect the changes. Although the patch leaves
the extradata unchanged, the size of the extradata according to the FATE
reports changes. This is due to a quirk in ff_h2645_packet_split which
is used by extract_extradata: If the input is Annex B, the first zero of
a four byte startcode is considered a part of the last unit (if any).

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2020-03-06 00:58:31 +01:00

22 lines
1.2 KiB
Plaintext

a3b02fd09392e01619cebc959d4d9ff2 *tests/data/fate/h264_mp4toannexb_ticket5927.h264
595583 tests/data/fate/h264_mp4toannexb_ticket5927.h264
#extradata 0: 33, 0x84fe08f8
#tb 0: 1/1200000
#media_type 0: video
#codec_id 0: h264
#dimensions 0: 1920x1080
#sar 0: 0/1
0, -48000, -9223372036854775808, 48000, 247993, 0x1ce821ea
0, 0, -9223372036854775808, 48000, 43354, 0xa05dca6f, F=0x0
0, 48000, -9223372036854775808, 48000, 11423, 0x5e8086dd, F=0x0
0, 96000, -9223372036854775808, 48000, 50798, 0x145fbe4f, F=0x0
0, 144000, -9223372036854775808, 48000, 12567, 0x1e3d5304, F=0x0
0, 192000, -9223372036854775808, 48000, 52444, 0x1a6c1a64, F=0x0
0, 240000, -9223372036854775808, 48000, 12575, 0x2fff484b, F=0x0
0, 288000, -9223372036854775808, 48000, 54025, 0xb3bf0ce6, F=0x0
0, 336000, -9223372036854775808, 48000, 13539, 0xfdb16c57, F=0x0
0, 384000, -9223372036854775808, 48000, 54483, 0xefead99f, F=0x0
0, 432000, -9223372036854775808, 48000, 13705, 0x23cd27e8, F=0x0
0, 480000, -9223372036854775808, 48000, 22308, 0x4093b5af, F=0x0
0, 528000, -9223372036854775808, 48000, 6369, 0x858b2aa1