Re: Soxi warn about missing extended part of the fmt chunk--but it seems to be there

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sylvain Leroux <sylvain@xxxxxxxxxxx> writes:

> Hi everyone.
>
> First thank you for the great work and support. I'm in the process of
> writing a sound library for an internal project, and I realize more each
> day the amount of work the developers may have put in writing SoX.
>
> I am working now on a Wave file exporter, and while using `soxi` to
> verify the my wave files are well formed, I noticed the warning "wave
> header missing extended part of fmt chunk":
>
>> sh$ soxi -V4 test/tmp/float_32_1.wav
>> soxi INFO formats: detected file format type `wav'
>> soxi DBUG wav: WAV Chunk fmt
>> soxi INFO wav: EXTENSIBLE
>> soxi WARN wav: wave header missing extended part of fmt chunk
>> soxi DBUG wav: WAV Chunk fact
>> soxi DBUG wav: WAV Chunk data
>> soxi DBUG wav: Reading Wave file: IEEE Float format, 1 channel, 48000
>> samp/sec
>> soxi DBUG wav:         192000 byte/sec, 4 block align, 32 bits/samp,
>> 643200 data bytes
>> soxi DBUG wav:         160800 Samps/chans
>>
>> Input File     : 'test/tmp/float_32_1.wav'
>> Channels       : 1
>> Sample Rate    : 48000
>> Precision      : 24-bit
>> Duration       : 00:00:03.35 = 160800 samples ~ 251.25 CDDA sectors
>> File Size      : 643k
>> Bit Rate       : 1.54M
>> Sample Encoding: 32-bit Floating Point PCM
>
> However, it seems to me I write the extended 40 bytes fmt chunk in the file:
>
>> 00000000  52 49 46 46 cc d0 09 00  57 41 56 45 66 6d 74 20  |RIFF....WAVEfmt |
>> 00000010  28 00 00 00 fe ff 01 00  80 bb 00 00 00 ee 02 00  |(...............|
>> 00000020  04 00 20 00[16 00]20 00  00 00 00 00 03 00 00 00  |.. ... .........|
>> 00000030  00 00 10 00 80 00 00 aa  00 38 9b 71 66 61 63 74  |.........8.qfact|
>> 00000040  04 00 00 00 80 d0 09 00  64 61 74 61 80 d0 09 00  |........data....|
>> 00000050  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
>> *
>> 0009d0d0
>
> At byte 0x24 we can see 0x0016 which is the size (22 bytes) of the
> extended fmt header, followed by the extended header content. And after
> that, the `fact` chunk starts.
>
> Why is `soxi` considering the extended header is missing?

There is a small bug that triggers that warning in error for some
combinations of parameters.  Your file header looks correct to me.

-- 
Måns Rullgård


_______________________________________________
Sox-users mailing list
Sox-users@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/sox-users




[Index of Archives]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux