Flash CS3 Documentation |
|||
| Flash Lite 2.x ActionScript Language Reference > ActionScript classes > Sound | |||
Object
|
+-Sound
public class Sound
extends Object
The Sound class lets you control sound in a movie. You can add sounds to a movie clip from the library while the movie is playing and control those sounds. If you do not specify a target when you create a new Sound object, you can use the methods to control sound for the whole movie.
You must use the constructor new Sound to create a Sound object before calling the methods of the Sound class.
|
Modifiers |
Property |
Description |
|---|---|---|
|
|
The duration of a sound, in milliseconds. |
|
|
|
Provides access to the metadata that is part of an MP3 file. |
|
|
|
The number of milliseconds a sound has been playing. |
Properties inherited from class Object constructor (Object.constructor property), __proto__ (Object.__proto__ property), prototype (Object.prototype property), __resolve (Object.__resolve property)
|
Event |
Description |
|---|---|
|
onID3 |
Invoked each time new ID3 data is available for an MP3 file that you load using |
|
Invoked automatically when a sound loads. |
|
|
onSoundComplete |
Invoked automatically when a sound finishes playing. |
|
Signature |
Description |
|---|---|
|
Creates a new Sound object for a specified movie clip. |
|
Modifiers |
Signature |
Description |
|---|---|---|
|
|
attachSound |
Attaches the sound specified in the |
|
|
getBytesLoaded |
Returns the number of bytes loaded (streamed) for the specified Sound object. |
|
|
getBytesTotal |
Returns the size, in bytes, of the specified Sound object. |
|
|
Returns the pan level set in the last |
|
|
|
getTransform |
Returns the sound transform information for the specified Sound object set with the last |
|
|
Returns the sound volume level as an integer from 0 to 100, where 0 is off and 100 is full volume. |
|
|
|
Loads an MP3 file into a Sound object. |
|
|
|
Determines how the sound is played in the left and right channels (speakers). |
|
|
|
setTransform |
Sets the sound transform (or balance) information, for a Sound object. |
|
|
Sets the volume for the Sound object. |
|
|
|
Starts playing the last attached sound from the beginning if no parameter is specified, or starting at the point in the sound specified by the |
|
|
|
Stops all sounds currently playing if no parameter is specified, or just the sound specified in the |
Methods inherited from class Object
Flash CS3
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/flash/9.0/main/00005421.html