DSL Tips and Tricks :: Internet Radio



To save and edit large large radio programs:

1. Play with xmms, rip with streamripper. This can produce a large mp3 file (or if you're lucky, breaks them into individual selections)
2. Convert to wav using sox. "/opt/sox/sox file.mp3  file.wav"
3. Edit with audacity.  I found that loading a large mp3 file into audacity quickly ate up all my ram, but it had no problem with a wav
4. Load exported wav file into wavbreaker to separate into individual selections.

To save disk space, convert back to mp3 format with lame or sox

All the above programs are in the repository.

For converting from mp3 to wav, I'd use Lame, it's smaller, faster and more accurate than sox..

Also saves you the trouble of getting the sox extension at all..

Quote (curaga @ Oct. 23 2007,11:09)
For converting from mp3 to wav, I'd use Lame, it's smaller, faster and more accurate than sox..

Also saves you the trouble of getting the sox extension at all..

Does the version in the repository (ver 3.97) do that? I tried 'lame file.mp3 file.wav'  and it created an mp3 with the name 'file.wav'
It's lame --decode file.mp3 file.wav

since it's a mp3 encoder, it's decoding if you do it other way around :)

Quote (curaga @ Oct. 23 2007,12:53)
It's lame --decode file.mp3 file.wav

since it's a mp3 encoder, it's decoding if you do it other way around :)

..tried it, but got errors:
Ibitstream problem; resynicing:  mpg123: Can't rewind stream

I found a sox script that also uses mpg123; It produced a wav file that sounds like it's on fast forward (probably the -c2 which I think is the speed):

mpg123 -b 10000 -s -r 44100 "$1" | /opt/sox/sox -t raw -r 44100 -s -w -c2 - "$2"

Edit: The -c2 is what doubled the speed; -c1 is normal speed.
This script (mp32wav) runs with: 'mp32wav file.mp3 file.wav'
Requires loading sox (the mpg123 player comes with dsl).

Mp32wav produces a wav file that loads right into wavbreaker. 'Sox file.mp3 sox.wav' produces a format unrecognized by wavbreaker, although running it through audacity changes it to one wavbreaker reads.  (I haven't fiddled with the sox switches)

Next Page...
original here.