MACROMEDIA FLASH  MX 2004

Alejandra Jarabo
MAT 116-0081

Media Arts & Technologies division. Santa Barbara City College
INCORPORATING SOUND

SOUND FILES IN FLASH

You can incorporate sound files into a Flash project by IMPORTING the sound file, either to the Library or to the Stage.
In both cases the sound file will be recorded as a Library element

SOUND-FILE TYPES SUPPORTED
file format
Windows
Mac
WAV
(PC native format)
Yes
Yes
(trough Quicktime)
MP3
(this is a compressed format)
Yes
Yes
AIFF
(Apple native format)
Yes
(trough Quicktime)
Yes
Sound only Quicktime Movies
Yes
(trough Quicktime)
Yes
(trough Quicktime)
RECOMPRESSING A SOUND FOR OUTPUT


If you have imported a sound in any other format than MP3,
(that is to say: you have imported an uncompressed sound)
You need to set the Compression parameters for that sound.

Go to SOUND PROPERTIES, by double clicking on the sound's icon in the Library.

 
   
     

Once within the Sound Properties dialogue window,

_Set the compression-type to MP3.

_In most cases you will check in "Preprocesing: convert stereo to mono";
it cuts the file-size almost in half.

 

_Bit rate: Try it out by pressing the Test button on the right side of the dialogue box.
The dynamic range of the sound decreases with lower numbers: your sound-file "sounds" like comming from a cellphone but the file size decreases.

_Quality: It doesn't change the file size. Changes the amount of time that Flash takes to recompress the sound when you "Publish" or Test your movie. You can leave it in Fast or Medium, and change it to best the last time that you export the movie.

You can see the orginal size of the imported sound-file (in lavender),
and the estimated file-size of the re-compressed sound WHEN you export it to SWF.
The Fla will be still containing the original big file.

 

 

SYNC OPTIONS FOR A SOUND INSTANCE

You can control the Sync mode of a sound instance by checking the Properties Panel when the sound is already on Stage (attached to a keyframe).

Select the keyframe where the sound is "living" and look at the Properties panel:

_ You see the name of the sound playing . First line
_The Effect field (you don't need to use it for now) and the Edit button (for basic editing functions). Second line
_ The Sync-mode field and the Repeat option (if you want the sound to play once, a number of times, or to loop). Third line
_ The sound-file size. Fourth line

Set your sound to one of these Sync options

EVENT
START
STREAM
STOP
 

For Buttons.

 

They trigger the play as soon as the playhead gets to the keyframe where they are "living".

If the sound gets the order to Play meanwhile is still finishing to play the file, a new sound gets triggered,creating sound overlaps.

For Buttons.

 

No new instance of the sound gets triggered until the first one has finished playing.

 

For "background sounds" (along the Main-timeline or inside a Movie clip

 

For Long audio files, when you want the Flash movie to play, meanwhile the sound file is still getting loaded (those are usually big files)

 

For "background sounds" (along the Main-timeline or inside a Movie clip)

 

When you are going to make that sound play later though action scripting, or want to make sure that a sound already playing is silent by the time that the playhead reaches that keyframe.

       
EXAMPLE OF SYNC-MODE BEHAVIOR OF A SOUND IN A BUTTON
   

To attach asound file to a button State (rollOver or Down), create a new layer inside the button's Timeline.

Make a keyframe either on rollOver state or on Down State.

Drag the sound file from the Library to that keyframe (or to the Stage with that layer and keyframe already selected)

Define the sync mode in the properties panel.

   

Here you can experiment with Start and Event sync modes for sound-filesinside a button-symbol.

 

EVENT

 

There is a new sound instance triggered every time you rollOver or Press the button.

You can end with a full orchestra!

START

 

The sound doesn't begin playing again until it has finished the previous round.

It doesn't matter if you rollOver or Press the button again.