[FFmpeg-devel] lavf/matroska*: DiscardPadding is a signed integer

Jan Gerber j at v2v.cc
Fri Nov 15 23:12:05 CET 2013


On 11/15/2013 09:51 PM, Michael Niedermayer wrote:
> On Thu, Nov 14, 2013 at 12:58:28PM +0100, Jan Gerber wrote:
>>
>> according to the Matriska Specification
>>  http://matroska.org/technical/specs/index.html
>> DiscardPadding is a signed integer.
> 
> has this been tested against other (de)muxers ?
> its the first code that uses sint_* so having it double checked makes
> sense, to ensure we dont generate invalid files

Afaik the only use of DiscardPadding right now is with Opus (still
-strict -2) - and Opus only uses it for end trimming so will never use
negative values.

To test negative values I modified libavformat/matroskaenc.c:1399 to
always write a negative value. The value in the resulting file is parsed
correctly if inspected with mkvinfo and with a test program using
libnestegg (part of firefox). Positive values are also correct.



More information about the ffmpeg-devel mailing list