Chapter 29. Sharing and Loading Assets

IN THIS CHAPTER

  • Creating a preloader for your Flash movie

  • Loading Flash movies into other Flash movies

  • Using the MovieClipLoader API

  • Loading image files into Flash movies

  • Loading MP3 audio into Flash movies

  • Loading Flash Video files into Flash movies

  • Using a preloader for external media files

Because most Flash movies are downloaded and viewed over the Web, ActionScript has a number of advanced actions that are dedicated solely to controlling the download and display of movies and Library assets. Actions that check the loaded bytes of a Flash movie file (.swf) or media file let developers prevent a movie from playing before a specified portion of it has finished loading. The loadMovie() and unloadMovie() actions enable Flash content to be broken into small pieces or assets that are downloaded only when they are needed.

Tip

Flash Player 8 and higher enable you to load PNG, GIF, and progressive JPEG images into your Flash movies, in addition to MP3, .flv, and .swf files. We show you how to load these media files in this chapter.

Note

This chapter discusses ActionScript 2.0 implementations of asset loading and sharing.

Managing Smooth Movie Download and Display

When Flash movies are played back over the Internet, they progressively download, meaning that the Flash Player plug-in shows as much of the movie as it can during download, even if the whole file has not been transferred to the user's system or browser cache. The benefit of this feature is that users ...

Get Adobe® Flash® CS3 Professional Bible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.