Chapter 11: Working With Sound - MACROMEDIA FLASH MX 2004-USING FLASH Use Manual

Hide thumbs Also See for FLASH MX 2004-USING FLASH:
Table of Contents

Advertisement

CHAPTER 11
Working with Sound
Macromedia Flash MX 2004 and Macromedia Flash MX Professional 2004 offer several ways to
use sounds. You can make sounds that play continuously, independent of the Timeline, or you
can synchronize animation to a sound track. You can add sounds to buttons to make them more
interactive and make sounds fade in and out for a more polished sound track.
There are two types of sounds in Flash: event sounds and stream sounds. An event sound must
download completely before it begins playing, and it continues playing until explicitly stopped.
Stream sounds begin playing as soon as enough data for the first few frames has been
downloaded; stream sounds are synchronized to the Timeline for playing on a website.
You select compression options to control the quality and size of sounds in exported SWF files.
You can select compression options for individual sounds using the Sound Properties dialog box
or define settings for all sounds in the document in the Publish Settings dialog box.
You can use sounds in shared libraries to link a sound from one library to multiple documents.
For more information, see
"Using shared library assets" on page
69. You can also use the
ActionScript
event to trigger an event based on the completion of a sound. For
onSoundComplete
more information, see
"About the onSoundComplete event" on page
208.
You can use behaviors that are prewritten ActionScript scripts to load and control the playback of
sounds. As with behaviors, the media components contain prewritten ActionScript scripts to load
and control sounds (MP3 sounds only) but also provide a controller for stop, pause, rewind, and
so on. For more information on using the media components, see
"Playing FLV video clips with
media components (Flash Professional only)" on page
196.
Note: You can also use actions to load sounds dynamically. For more information, see
Sound.attachSound() and Sound.loadSound() in Flash ActionScript Language Reference.
This chapter contains the following sections:
Importing sounds. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
Adding sounds to a document . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
Adding sounds to buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
Using sounds with Sound objects. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
About accessing ID3 properties in MP3 files with Flash Player . . . . . . . . . . . . . . . . . . . . . . . 205
201

Advertisement

Table of Contents
loading

This manual is also suitable for:

Flash mx 2004 - actionscript

Table of Contents