Tutorial - Editing an Existing File

From Audacity Development Manual
Revision as of 23:40, 18 September 2009 by Billw58 (talk | contribs) (Edit for internal consistency: we/you, active voice, etc.)
Jump to: navigation, search
I'm beginning to understand the concerns about repeating stuff in different sections of the manual - in Tutorials, Foundations and Reference for example. That said, I think these tutorials are a special case. The purpose here is to guide the new user through a few common tasks, giving just enough guidance and information to complete the task. This necessarily requires repeating information from the Reference section. I don't think this is a bad thing.
We can link to more detailed and complete information from the tutorial, but I don't think we should do so in the body of the tutorial. We don't want to break up the flow of the tutorial, or tempt the learner to hop around the manual. Instead I'd suggest that each tutorial end with a "Where to go from here" section that provides links to pages that provide more details on the topics covered. - Bill
The easiest way to use Audacity is to open up an existing audio file and make small changes. If you've never used Audacity before, this is a great place to start.

Step 1: Find a file to edit

Audacity can open many common audio file formats, including WAV, AIFF, and MP3. Audacity cannot open WMA files or copy-protected music files.

If you want to edit music that you have on an audio CD, you need to "rip" the music into an audio file. See Ripping from an Audio CD.

Don't have any audio files handy? There's lots of free music online! Here's one song you can download:

ToDo This link is broken

This recording is free, distributed under the Creative Commons Attribution-Sharealike license, which gives you the right to create a derivative work without paying royalties, as long as you give credit and make your derivative work free, too. This is similar to the license for Audacity, which allows any programmer to modify it and redistribute it for free.

Step 2: Open the file with Audacity

Open Audacity. To open an audio file, you can select "Open" from the File menu, but a handy shortcut is to just drag and drop the file into Audacity:

Opening an audio file in Windows
Windows: Drag the audio file icon into the open Audacity window.

Opening an audio file on a Mac
Mac: Drag the audio file icon to the Audacity icon in the Dock.

(Linux users: you can run Audacity on the command line and give the name of the file to open as a command-line argument.)

Step 2: Look at the waveform

Picture of a stereo waveform in a track

When the waveform is "larger", the audio is louder, and vice versa. This image shows a stereo waveform. The left channel is displayed in the top half of the track, and the right channel on the bottom.

The ruler above the waveform shows you the length of the audio in minutes and seconds.

Step 3: Listen to the audio file

The Control toolbar

The image above show the Control Toolbar. The functions of the buttons are (from left to right): Skip to Start, Play, Record, Pause, Stop and Skip to End.

Click the Play button to listen to the audio. Click the Stop button to stop playback. If you don't hear anything, see Audacity Setup and Configuration.

You can use the spacebar as a shortcut for Play and Stop. When playback is stopped, pressing the spacebar will start playback, the same as clicking the Play button. During playback pressing the spacebar will stop playback, the same as clicking on the Stop button.

Click on the waveform using the selection tool Tool select.png to choose a place to start, then click the Play button (or press the spacebar). Click and drag to create a selection, and then when you click Play, only the selection will Play.

You can select audio entirely using the keyboard. For example you can use the left-arrow and right-arrow keys to move the cursor left and right in the waveform. Holding down the shift key while pressing these keys will create and extend a selection.

Clicking the Skip to Start button will move the cursor to the beginning of the track. The keyboard shortcut for Skip to Start is the Home key (on most keyboards? - please check this). It's kind of like rewind, but it's not for playback - it will only work when playback is stopped.

Similarly the Skip to End button will move the cursor to the end of the track. The keyboard shortcut for Skip to End is the End key (on most keyboards? - please check this).

ToDo Introduce keys to skip around while listening.///such as?///

Step 4: Create a 10-second clip

You edit audio waveform in Audacity in much the same way as you would edit text in a word-processing document. When you are editing text you first select the text you want to change and then choose what you want to do with it. You might want to Cut or Copy the text, delete it, Paste new text in it's place, or change it to bold. You do the same thing in Audacity: first select the range of audio you want to change, and then choose what you want to do with it.

Image of edit toolbar with zoom controls highlighted

The image above shows the Edit Toolbar with the Zoom buttons highlighted. The "magnifying glass with + symbol" is the Zoom In tool, and the "magnifying glass with - symbol" is the Zoom Out tool.

To zoom in to get a closer look at the waveform, first click near the point you're interested in, then click the Zoom In button. Keep clicking the Zoom In button until you see the detail you need. Note that when you click the Zoom In button the cursor is centered on the screen.

There are also menu commands and keyboard shortcuts for zooming. View > Zoom In (shorcut CTRL + 1) is the same as clicking the Zoom In button. View > Zoom Out (shorcut CTRL + 3) is the same as clicking the Zoom In button. View > Fit in Window (shorcut CTRL + F) will zoom the waveform so it fits in the window.

Use the Zoom commands so that you can make maximal use of your Audacity window to see as much detail as you need, or to make sure you see the entire file when necessary.

Walk through deleting all but approximately 10 seconds of audio.

To cut this audio file down to 10 seconds, follow these steps:

  • Click near the point where you want the 10-second piece to begin.
  • Zoom in until the timeline shows 10 seconds or more before and after the cursor.
  • While holding down the shift key, click 10 seconds to the right of the cursor.
    • Note that this is just like selecting a range of text in a word processor

image of audio with 10 seconds selected

  • Press the spacebar to listen to the selection.
  • Adjust the start and end of the selection with the mouse:
    • Move the pointer over the start of the selection - the cursor will change to a left-pointing hand
    • Click and drag to adjust the beginning of the selection
    • You can adjust the end of the selection in a similar manner
  • Adjust the start and end of the selection with the keyboard:
    • Pressing SHIFT + Left-arrow will expand the selection to the left
    • Pressing SHIFT + Right-arrow will expand the selection to the right
    • Pressing SHIFT + CTRL + Left-arrow will contract the selection from the right
    • Pressing SHIFT + CTRL + Right-arrow will contract the selection from the left

Note the Selection Toolbar at the bottom of the window. It shows the start time of the selection, and either the end time or length of the selection. If you want to select exactly ten seconds starting from the start of the current selection:

  • Click the Length radio button above the second group of numbers if it is not already selected
  • Click on the first digit to the right of the decimal point in the Length box
  • Press the 0 (zero) key - the digit changes to zero, the digit to the right is selected and the selection in the waveform changes to match
  • Press the 0 key - the selection length is now 10.00 seconds.

You've now selected the portion of the audio that you want to keep. To delete everything except the selected audio, click on Edit > Trim.

If you make a mistake, you can always click on Edit > Undo. Audacity has unlimited Undo and Redo. You can undo your editing actions all the way back to when you opened the file. You can also Redo actions that you have undone.

Step 5: Fade out the last second

Click the Skip to End button, then Zoom In until you can see the last two or three seconds of the audio. Click in the waveform about 1 second before the end. Now click on Effect > Fade Out. The last second of the audio is smoothly faded out.

Note that we always first select some audio first, then choose what action we want to perform on it.

Step 6: Export the resulting file

When you save an Audacity project with File > Save you are doing just that - saving an Audacity project. Audacity projects can be opened only by Audacity. If you want other programs (such as iTunes or Windows Media Player) to be able to open this file we need to Export it.

You have a region of audio that starts several seconds (or perhaps minutes) from the beginning of the track. Before you export this audio you want to move it to the beginning of the track. If you don't do this, the exported file will contain silence, then your 10-second piece of audio. To correct this, click on Tracks > Align Tracks > Align with Zero. This moves your audio to the beginning of the track.

ToDo WAV first. Close and open the file. Always suggest a new name for the edited file, and keep the original around unless you're absolutely sure you can delete it.

Then optionally talk about exporting MP3. This is tricky because it requires downloading an extra program. Note that version 1.3.3 makes this much easier and we have new LAME installers.

Where to go from here

More tutorials

For more information