Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

27.4. Loader

Flash Player can display graphics in three ways: you can use ActionScript (and sometimes Pixel Bender) code to draw graphics on the screen (see Part VIII, "Graphics Programming and Animation"), you can use embedding to associate graphics with Class references (see Chapter 16, "Working with DisplayObjects in Flash Professional"), or you can use Flash Player's networking capabilities to load graphics files from the internet. The Loader class provides an easy-to-use interface for including the contents of external files in your Flash application.

NOTE

Choosing whether to embed graphics or load them externally (or even draw them programmatically when you can) is not always easy. The overall strategy you pick for including graphical content in your application can have a big impact on how you load and structure it. Because dynamically loaded graphics are easy to manipulate and there are multiple free libraries to assist in managing large external libraries, I prefer to externalize all assets in ActionScript projects.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint