Slides and Demos from Flash Camp St. Louis 2010

What a great day! I loved seeing the awesome turnout of Flash designers and developers from around the area, including many interactive compatriots I hadn’t seen in quite a while. You guys are awesome!

Here are my slides and an archive of the demos I showed during my session.

The demos are FDT projects, so head over to Powerflasher and get your demo copy of FDT4. And if you don’t have a license, be sure to follow @brunofonzi, @brittrking, myself, and many others that seem to weekly be tweeting or retweeting ways to get a free Pure license.

To use the demos, open a new workspace in FDT, choose to Import > General > Existing Projects into Workspace. Browse to the extracted the ZIP file and choose each project individually. It should end up looking like this:

image

In the demos you’ll find 3 projects:

1) AssetsExamples

This is the demo I also performed step by step in the screencast on Vimeo. I demonstrate how to create assets in Flash Pro, produce a SWC file, make that SWC available in an FDT (or Flash Builder) project and then a variety of ways you can use and add behavior to those assets.

2) LoaderMaxExample

This code demonstrates the flexibility of bulk loading a variety of different asset types by defining them in an XML manifest document with custom properties telling LoaderMax how to handle them.

NOTE: for this example and the next you will need to set your Flash Player security to so you don’t get a SandBox violation. Open the FDTLaunch.cfg file you’ll find here: ~/Library/Preferences/Macromedia/Flash Player/#Security/FlashPlayerTrust/ and add paths to your project locations. Then restart FDT. Here are mine:

file:////Users/dave/work/SimplyProfound/LoaderMaxExample/bin/
file:////Users/dave/work/SimplyProfound/SWFLoaderExample/bin/

During my talk I also showed code from the STLTweets LouFest twitter display that I did with the guys at Infuz. I can’t share the entire app, but the relevant code below demonstrates how you can load images directly into containers, define the desired size, and then the scaling parameters to make sure your image fits and fills that space when it’s loaded. Awesome mojo from Greensock!

photoLoader = new ImageLoader(vo.linkThumbnail, {smoothing:true, container:tweet.imgPhoto, width:400, height:300, scaleMode:"proportionalInside"});
photoLoader.load();

iconLoader = new ImageLoader(vo.profileImageURL, {smoothing:true, container:tweet.imgUserIcon, width:60, height:60, scaleMode:"proportionalOutside"});
iconLoader.load();

3) SWFLoaderExample

This set of examples demonstrates using a utilities like CASA Lib to load linked assets from swf files. This method is more akin to the old school AS2 way of doing things and lacks the strong typing I prefer (and why I use SWCs more often). It’s a very cool and useful way of loading multiple swfs and accessing the libraries.

Download Demo Code Projects


Categories: FlashGeneralFlexPermalink