[FFmpeg-devel] [PATCH]lavf/matroska: Support codec id V_FFV1 for FFV1.

Nicolas George george at nsup.org
Thu Mar 2 11:28:19 EET 2017


Le primidi 11 ventôse, an CCXXV, James Almer a écrit :
> Ah, i see there's generic code to read and write CodecPrivate elements
> to and from raw extradata for native codecids where no special handling
> is required.
> 
> In any case, the spec says
> 
> "For FFV1 versions 2 or less, Private Data SHOULD NOT be written."
> 
> The ffv1 encoder creates extradata for v2 and newer, so the muxer
> should have a custom case for ffv1 in order to detect v2 streams and
> avoid writing said extradata.

I have not looked myself at the situation, I only read what you wrote
her. According to it, it seems here the FFV1 encoder is violating the
specification and needs to be fixed.

The way I see it, we should try to make muxers as generic and
codec-independent as possible. Most cases where we have codec-specific
code in muxers are when someone bungled the design, usually an
industrial committee (but do not ask me how the Ogg people managed to
make something even worse).

There are several ways to interpret the quote of the spec above:

1a: Encoders SHOULD NOT return extradata to the application.

1b: Applications SHOULD discard extradata returned by the encoder.

2a: Applications SHOULD NOT give extradata to the muxer.

2b: Muxers SHOULD discard extradata given by the application.

IMHO, the only reasonable one is 1a; it achieves automatically 2a and
makes 1b and 2b completely unnecessary.

Regards,

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170302/ed31d466/attachment.sig>


More information about the ffmpeg-devel mailing list