[plug] Converting WAVs with 0-bit sample size?

Andrew Furey andrew.furey at gmail.com
Fri Jul 27 19:51:08 WST 2007


On 21/07/07, Michael Holland <myk at myk.id.au> wrote:
> Obviously the samples cannot really be zero bit. I suppose it is
> reading the header incorrectly.
>     Try overriding it - i think its "lame -bitwidth xx", or post a link to
> a sample.

Thanks for that Mike,

I found that my old version of lame didn't have the bitwidth option.
I've since compiled the latest which does, but it doesn't need it - it
runs without errors. Now if only the MP3 it generated was actually
correct...

I've put samples up at http://www.northway.org.au/plugtest/ . The
original source is an Asterisk voicemail file, so the .gsm file is the
original (although it called it .wav, file(1) clearly shows it as
GSM).

I then converted it to MS-style WAV with
sox -g plugtest.gsm -a plugtest.wav

This file is correct as you can download and see (I'd better not offer
a prize for anyone getting the reference, with the longevity of this
list... :-P)

So far so good, but if I convert it to MP3 with bog-standard
lame plugtest.wav plugtest.mp3

it produces the third file, which is obviously garbage. The screen
output for that conversion was:

Encoding /tmp/plugtest.wav
      to /tmp/plugtest.mp3
Encoding as 44.1 kHz 128 kbps j-stereo MPEG-1 Layer III (11x) qval=3
    Frame          |  CPU time/estim | REAL time/estim | play/CPU |    ETA
     8/8     (100%)|    0:00/    0:00|    0:00/    0:00|   2.9854x|    0:00
-------------------------------------------------------------------------------
   kbps        LR    MS  %     long switch short %
  128.0       12.5  87.5        62.5  25.0  12.5

Any further suggestions? I feel I'm _this close_...

Andrew

-- 
Linux supports the notion of a command line or a shell for the same
reason that only children read books with only pictures in them.
Language, be it English or something else, is the only tool flexible
enough to accomplish a sufficiently broad range of tasks.
                          -- Bill Garrett



More information about the plug mailing list