
276
USING FLASH CS4 PROFESSIONAL
Sound
Add a sound to a button
You can associate sounds with the different states of a button symbol. Because the sounds are stored with the symbol,
they work for all instances of the symbol.
1
Select the button in the Library panel.
2
Select Edit from the Panel menu in the upper-right corner of the panel.
3
In the button’s Timeline, add a layer for sound (Insert > Timeline > Layer).
4
In the sound layer, create a regular or blank keyframe to correspond with the button state to which you want to add
a sound (Insert > Timeline > Keyframe or Insert > Timeline > Blank Keyframe).
For example, to add a sound that plays when you click the button, create a keyframe in the frame labeled Down.
5
Click the keyframe you created.
6
Select Window
> Properties.
7
In the Property inspector, select a sound file from the Sound pop-up menu.
8
Select Event from the Sync pop-up menu.
To associate a different sound with each of the button’s keyframes, create a blank keyframe and add another sound file
for each keyframe. You can also use the same sound file and apply a different sound effect for each button keyframe.
Synchronize a sound with animation
To synchronize a sound with animation, you start and stop the sound at keyframes.
1
Add a sound to a document.
2
To synchronize this sound with an event in the scene, select a beginning keyframe that corresponds to the keyframe
of the event in the scene. You can select any of the synchronization options.
3
Create a keyframe in the sound layer’s Timeline at the frame where you want the sound to end. A representation of
the sound file appears in the Timeline.
4
Select Window
> Properties, and click the arrow in the lower-right corner to expand the Property inspector.
5
In the Property inspector, select the same sound from the Sound pop-up menu.
6
Select Stop from the Sync pop-up menu.
When you play the SWF file, the sound stops playing when it reaches the ending keyframe.
7
To play back the sound, simply move the playhead.
Edit a sound in Flash
In Flash, you can define the starting point of a sound or control the volume of the sound as it plays. You can also change
the point at which a sound starts and stops playing. This is useful for making sound files smaller by removing unused
sections.
1
Add a sound to a frame, or select a frame that already contains a sound.
2
Select Window
> Properties.
3
Click the Edit button on the right side of the Property inspector.
4
Do any of the following:
•
To change the start and end points of a sound, drag the Time In and Time Out controls in the Edit Envelope.
Updated 5 March 2009