home | et13 - game prototyping in Gamemaker prev | next

David Javelosa

Copyright © 2001-2020, David Javelosa unless otherwise stated.


week 04 - sound

Sound Utillities in Windows

There are sound utillities and applications available for Windows that allow for direct digital capture ("ripping") of CD audio to hard drive. The method below is an Analog method that routes the audio signal in software from the CD audio output to the sound chip's input, and then into the recording application. If there is no sound transfer to the input, the Stereo Mix Balance in the Recording Control window may need to be adjusted. This can be accessed by right-clicking on the Volume icon in the system tray; selecting properties in the Options menu; selecting Adjust Volume for RECORDING; and selecting OK.

Note: If you are unable to record audio, it's possible that your PC is not set up correctly for recording:
Double click on the small speaker in the lower right hand portion of the windows task bar. This will open the Volume Control Panel
Uncheck the mute checkboxes on any outputs you need
Select Properties from the Options pull-down, check the Recording box and put checks next to any inputs you need.
Select OK, which opens the Records Mixer
Set the volumes to the middle, and uncheck the mute checkboxes on any inputs you need

Using Audacity

Audacity is an audio editing program on the PC that enables you to record and edit audio. It is similar in function to programs like Premier, and even a word processor. You can select sections of audio, cut, copy, and paste them.

This shows the basic interface for Audacity. The transport controls in the upper left, are for pausing, play, stop, rewind, fast forward and record. The tools in the center are for select, envelope (volume editing) and penci for correcting wave forms. The main editing window shows a track called TUTOR1. This is a mono file at 44.1khz sample rate.

To record audio off of a CD

  1. Open CD from Windows media player
  2. Save to hard drive as MP3
  3. Open in Audacity to edit

To record audio from the microphone

You can use the same procedure for the microphone on the keyboard with the following changes:

  1. Be sure there is no CD in the computer, and the CD Player application is not open
  2. Plug Mic into the mic input of the computer sound card/jack
  3. Turn on record first, then start the noise

To edit a sound file

  • Select the section of audio you want to modify
  • You can copy, cut, and paste audio, either in the current file, or in a new file
  • To turn a section of audio into a new file,
    1. Select a section and copy it (control-c)
    2. Create a new audio file (File>New)
    3. Paste the section of audio you copied
    4. Save the audio on your Zip (as a .wav file)
  • To remove a section of audio from the current file
    1. Select the audio
    2. Select File>Cut
  • To insert a section of audio
    1. Copy the audio from a file
    2. Set the cursor in the location of the file you want the audio inserted
    3. Paste the audio

To save a sound file

  • Select Save or Save As from the File menu
  • Select .WAV as the file type

This window shows a multi-track session in Audacity. The pull-down menu of EFFECT displays many of the sound processing options available.

To process the audio

  • Normalizing -- For the best results with digital audio, you usually want the maximum audio level in the sound file, without distortion. Sound editing software usually enables you to achieve this in one simple step called Normalizing. The normalizing process searches for the maximum volume anywhere in the file. It then increases the volume of the entire file so that maximum volume is the loudest possible without distorting. In general, you should always normalize your audio just before you encode it into it's final form. In Audacity:
    1. Select all to select the entire file
    2. Select EFFECT >Normalize
  • Equalization -- You can change the timbre of the audio by using a digital equalizer (i.e. fancy tone controls). For example, you could enhance the high frequencies to make the cymbals in a drum set more prominent. Or you could reduce the bass frequencies to eliminate some hum from a recording. In Audacity:
    1. Select the section of the file you want to equalize
    2. Select EFFECT>Equalization
  • Time compression/expansion -- Digital processing can change the length of a section of audio without the normal changes in pitch that would take place if you simply sped up or slowed down the audio. This allows you to adjust the time of a section of audio to exactly fit a desired time (e.g. change an audio clip from 25 seconds to the length of a 30 second animation). In Audacity:
    1. Select CHANGE SPEED
    2. Set the new number of seconds

sfxr - sound effect generator
by DrPetter, 2007-12-14
developed for LD48#10

Basic usage:

Start the application, then hit
some of the buttons on the left
side to generate random sounds
matching the button descriptions.

Press "Export .WAV" to save the
current sound as a WAV audio file.
Click the buttons below to change
WAV format in terms of bits per
sample and sample rate.

If you find a sound that is sort
of interesting but not quite what
you want, you can drag some sliders
around until it sounds better.

The Randomize button generates
something completely random.

Mutate slightly alters the current
parameters to automatically create
a variation of the sound.

Advanced usage:

Figure out what each slider does and
use them to adjust particular aspects
of the current sound...

Press the right mouse button on a slider
to reset it to a value of zero.

Press Space or Enter to play the current sound.

The Save/Load sound buttons allow saving
and loading of program parameters to work
on a sound over several sessions.

Volume setting is saved with the sound and
exported to WAV. If you increase it too much
there's a risk of clipping.

Some parameters influence the sound during
playback (particularly when using a non-zero
repeat speed), and dragging these sliders
can cause some interesting effects.

Using an external sound editor to capture and edit
sound can also be used to string several sounds
together for more complex results.
To record this you will need to use an external
recording application, for instance Audacity.
Set the recording source in that application
to "Wave", "Stereo Mix", "Mixed Output" or similar.

Parameter description:
- The top four buttons select base waveform
- First four parameters control the volume envelope
Attack is the beginning of the sound,
longer attack means a smoother start.
Sustain is how long the volume is held constant
before fading out.
Increase Sustain Punch to cause a popping
effect with increased (and falling) volume
during the sustain phase.
Decay is the fade-out time.
- Next six are for controlling the sound pitch or
Start frequency is pretty obvious. Has a large
impact on the overall sound.
Min frequency represents a cutoff that stops all
sound if it's passed during a downward slide.
Slide sets the speed at which the frequency should
be swept (up or down).
Delta slide is the "slide of slide", or rate of change
in the slide speed.
Vibrato depth/speed makes for an oscillating
frequency effect at various strengths and rates.
- Then we have two parameters for causing an abrupt
change in pitch after a ceratin delay.
Amount is pitch change (up or down)
and Speed indicates time to wait before changing
the pitch.
- Following those are two parameters specific to the
squarewave waveform.
The duty cycle of a square describes its shape
in terms of how large the positive vs negative
sections are. It can be swept up or down by
changing the second parameter.
- Repeat speed, when not zero, causes the frequency
and duty parameters to be reset at regular intervals
while the envelope and filter continue unhindered.
This can make for some interesting pulsating effects.
- Phaser offset overlays a delayed copy of the audio
stream on top of itself, resulting in a kind of tight
reverb or sci-fi effect.
This parameter can also be swept like many others.
- Finally, the bottom five sliders control two filters
which are applied after all other effects.
The first one is a resonant lowpass filter which has
a sweepable cutoff frequency.
The other is a highpass filter which can be used to
remove undesired low frequency hum in "light" sounds.

Assignment: REVIEW Chapter 4 - Game Maker's Apprentice - Lazarus Squished



Copyright © 2001-2014, David Javelosa