Cut and Paste

Cut and Paste

Now that you have a decent recording, how can you make it sound more professional? There are several ways to do this; a good first step is to remove dead space at the beginning and end of the audio clip. You can do this visually with the audacity waveform editor ( Figure 19-2 ):

Figure 19-2. Cutting a section from an audio file with the audacity utility.

$ audacity mysong.wav

I selected the first half second of the song, shown in darker gray. Next , I would go to Edit/Delete to remove this little bit of silence. I could also modify the volume and apply audio effects to all or part of the file. Finally, I would export the audio clip as a New and Improved WAV file.

In this version of audacity, exporting is not as simple as it sounds. You must split the stereo track into left and right channels before exporting, or both tracks will be mixed down into a monaural WAV file. You can do this by right-clicking on the track name (next to the little X) and selecting Split Audio Track. Then right-click on each of the mono tracks and set the channel (left or right), as in Figure 19-3 :

Figure 19-3. Exporting a WAV file from audacity.

If you record your files as raw PCM samples, you can even use basic Unix utilities to do the same kind of thing. For example, to shave a half second off the beginning of a song, you can use the tail command. The first line is there to calculate how many bytes to remove:

$ perl -e 'print 44100 * 4 * 0.5'

88200

$ tail -c +88200 mysong.wav > newsong.wav

Assuming the raw file is at standard CD quality, there are 44,100 4-byte samples every second. So a half second is 22,050 samples at 4 bytes per sample, or 88,200 bytes. We'll use dd in the same way in the Trimming sections later in this chapter.

 



Multitool Linux. Practical Uses for Open Source Software
Multitool Linux: Practical Uses for Open Source Software
ISBN: 0201734206
EAN: 2147483647
Year: 2002
Pages: 257

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net