MPEGGroup / FileFormat

MPEG file format discussions
20 stars 0 forks source link

Query on AVCConfigurationBox #97

Open bradh opened 3 months ago

bradh commented 3 months ago

ISO/IEC 14496-15:2022 Section 5.3.2.1 described the AVC decode configuration record (which appears in the AVCConfigurationBox as well as the corresponding ISO/IEC 23008-12 item property)

My initial implementation overran the box in some of the sample files when parsing items with AVCProfileIndication (aka profile_idc) equal to 100.

The way I read the description and syntax was that there could be additional data, but any extensions to the box would be consistent with previous definitions. So if some new profile (like "High") needed additional fields, those would be conditional and in the syntax.

It looks like at least one of the conformance sample files nalu/mvc/DDF_10s_25fps.mp4 doesn't do that. It has AVCProfileIndication == 100 but none of the fields.

So I've modified my parsing to check there is enough data left. A bit messy because of the external framing, but achieved. Does leave a few questions open though.

Queries:

  1. Is that file considered valid?
  2. When reading, what are the default values for chroma_format, bit_depth_luma_minus8 and bit_depth_chroma_minus8? (I'm assuming SPS NALUs are assumed empty)
  3. When writing out a file that happens to have values equal to those default values, is it preferred to write them out anyway?