#133 Misleading help-hint in soxi with MPEG stream in RIFF

open
nobody
None
5
2009-05-12
2009-05-12
^Rooker
No

Opening WAV files containing MPEG data (e.g. mp2, mp3) with "soxi" returns the following hint:
"Try overriding the encoding: e.g. for an MP3 WAV, `-t mp3'"

Soxi does not provide the option to override the detected type, so it's impossible to follow the given "hint".

Here is the full output:
----------------
soxi formats: detected file format type `wav'
soxi wav: WAV Chunk bext
soxi wav: WAV Chunk fmt
soxi formats: can't open input file `xxx.wav': Unhandled WAV file encoding (MPEG).
Try overriding the encoding: e.g. for an MP3 WAV, `-t mp3'
----------------

Thanks for your great work!

btw: It would be great if soxi could read these files, but that's a separate feature request, I guess...

Discussion

  • robs
    robs
    2009-05-12

    Well this is a bug, but being able to follow the hint probably wouldn't help and shouldn't be needed anyway: soxi is basically about reading the file header, and the fact that libSoX cannot decode the body of these files shouldn't prevent soxi from doing this. So probably what is needed is to move the generation of these errors from the wav.c `start_read' function to the `read_samples' function (codec not available) and sox.c (hint on what to do about it). I'm guessing this will have to wait until after the upcoming 14.3.0 release.

     
  • bat
    bat
    2013-02-19

    Is this bug evident in current version SoX-14.4.1?