Because ID3 2.0 tags are located at the beginning of an MP3 file (before the sound data), they
are available as soon as the file starts downloading. ID3 1.0 tags, however, are located at the
end of the file (after the sound data), so they aren't available until the entire MP3 file finishes
downloading.
The
event handler is called each time new ID3 data is available. So, if an MP3 file
onID3
contains ID3 2.0 tags and ID3 1.0 tags, the
located in different parts of the file.
For a list of supported ID3 tags, see
2.0 Language Reference.
You can find a sample source file that loads MP3 files, jukebox.fla, in the Samples folder on
your hard disk. This sample demonstrates how to create a jukebox by using data types, general
coding principles, and several components:
In Windows, browse to boot drive\Program Files\Macromedia\Flash 8\Samples and
Tutorials\Samples\Components\Jukebox.
On the Macintosh, browse to Macintosh HD/Applications/Macromedia Flash 8/Samples
and Tutorials/Samples/Components/Jukebox.
Assigning linkage to assets in the library
You can assign linkage identifiers for assets in the library, such as movie clips and font
symbols. In Flash Basic 8 and Flash Professional 8, you can set linkage identifiers to sound
and image assets in the library. This supports using image and sound files with shared libraries
and with the new BitmapData class.
The following example adds a bitmap image in the library with a linkage set to
Then you add the image to the Stage and make it draggable.
To use linkage with bitmap files:
1.
Create a new FLA file called linkBitmap.fla.
2.
Import a bitmap image to the library.
3.
Right-click (Windows) or Control-click (Macintosh) the image in the library, and select
Linkage from the context menu.
4.
Select Export for ActionScript and Export in first Frame and type myImage in the
Identifier text box.
5.
Click OK to set the linkage identifier.
602
Working with Images, Sound, and Video
handler is called twice because the tags are
onID3
id3 (Sound.id3 property)
in the ActionScript
.
myImage
Need help?
Do you have a question about the FLASH 8-LEARNING ACTIONSCRIPT 2.0 IN FLASH and is the answer not in the manual?