[FFmpeg-devel] [PATCH 2/3] ff_put_wav_header: add flag to omit 0 cbSize field
daniel at drv.nu
Wed Mar 19 08:56:04 CET 2014
On Tue, Mar 18, 2014 at 7:30 PM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Tue, Mar 18, 2014 at 12:40:51AM -0700, Daniel Verkamp wrote:
>> For a specific example, see "[FFmpeg-devel] Wave header" thread from
>> last year .
>> -flags +bitexact is still needed to produce "normal" WAV files; it may
>> be worth considering whether the INFO tag should be written by
>> default. Clearly tools that don't properly interpret the headers are
>> broken, but it is probably better to produce files that work rather
>> than files with the mostly-useless-for-WAV encoder information by
> Does the affected software support non-PCM wav files ?
The particular tool mentioned in the previous thread only handles PCM.
> also RIFF does not mandate cbsize for PCM, so ommiting it for PCM
> seems perfectly within what the spec says
Agreed, it looks like PCMWAVEFORMAT (the structure used before
WAVEFORMATEX was defined) indeed only includes up to wBitsPerSample,
not cbSize, so that is a more reasonable argument.
I will rework the patch and send a less invasive change that only
applies for PCM; that should cover most of the broken tools, and
anything sophisticated enough to decode non-PCM codecs should
hopefully be able to understand the extra header fields.
-- Daniel Verkamp
More information about the ffmpeg-devel