45,50 €
A completely revised and updated edition of the all-timebestselling Flash title* Written by two of the world's leading Flash experts, thiscomprehensive reference provides you with undocumented techniques,tips, and tricks on the CS4 release of Flash, the popular tool thatallows you to create animations and build interactive Websites* In-depth coverage on more than one thousand pages includessomething for everyone--whether you're a Web novice oran accomplished Web professional--this resource will be yourguide to the inner workings and capabilities of Flash CS4* Two of the world's leading Flash experts offer morecoverage than any other book on the market* The accompanying CD-ROM includes trial software, addons,plugins, shareware, templates, and examplesNote: CD-ROM/DVD and other supplementary materials arenot included as part of eBook file.
Sie lesen das E-Book in den Legimi-Apps auf:
Seitenzahl: 1976
Veröffentlichungsjahr: 2009
Table of Contents
Part I: An Introduction to Flash Web Production
Chapter 1: Understanding the Adobe Flash CS4 Blueprint
The Key Is Integration
The topography of Flash CS4
File types in Flash CS4
The Many Worlds of Flash CS4
Bitmap handler
Vector-based drawing program
Vector-based animator
Video engine
Audio player
Multimedia authoring program
Animation sequencer
Programming and database front end
Desktop application authoring program
Summary
Chapter 2: Exploring Web Technologies
Contextualizing Flash in the Internet Evolution
High expectations for Web experiences
To Flash or not to Flash?
Alternative methods of multimedia authoring
Exploring Companion Technologies
HTML is here to stay
Client-side scripting using JavaScript
The world of Web services
Adobe server technologies
Recognizing Project Potential
Linear presentations
Interactive presentations
Data-driven presentations
Data-driven applications (or Rich Internet Applications)
Summary
Chapter 3: Planning Flash Projects
Workflow Basics
Phase I: Establishing the concept and goals
Phase II: Producing, testing, and staging the presentation
Using the Project Panel in Flash CS4
1. Establishing a project structure
2. Creating the project in Flash CS4
3. Changing project and panel preferences
4. Opening and editing files in the project
5. Publishing the entire project
Summary
Part II: Mastering the Flash Environment
Chapter 4: Interface Fundamentals
Getting Started
Welcome to Flash CS4
Start Page
Help menu options
The Flash CS4 interface on Macintosh and Windows
What to expect from the Properties panel
Managing Windows and Panels
Contextual menus
Floating and docking panels
Focus: Making panels or windows active
Creating custom workspace layouts
Keyboard shortcuts
The Tools Panel
Controlling the Tools panel
Reading the Tools panel
Using Tool options
Customizing the Tools panel
The Document Window
Controlling the Document window
Reading the Document window
Using scenes
Using Document window menu options
Working with Flash templates
The Timeline Window
Controlling the Timeline window
Using the Timeline Controller toolbar
Reading the Timeline
Editing frames and layers
Using Frame View options
Printing
Summary
Chapter 5: Drawing in Flash
Using Geometric Shape Tools
The Oval tool
The Oval Primitive tool
The Rectangle tool and Rectangle Primitive tool
Join and Miter settings
The PolyStar tool
The Line tool
Using Drawing Tools
The Pencil tool
The Brush tool
The Eraser tool
Creating Precise Lines and Bezier Curveswith the Pen Tool
Using Fill and Stroke Controls
Choosing colors
Choosing line styles
Controlling Stroke Scale behavior
Optimizing Drawings
Putting Selection Tools to Work
The Selection tool
The Lasso tool
The Subselection tool
Designing and Aligning Elements
Simplifying snapping settings
Design panels
The Edit menu
Creating Patterns with Symbols Using the Spray Brush Tool and the Deco Tool
Applying random “ink” with the Spray Brush tool
Creating order and pattern with the Deco tool
Summary
Chapter 6: Symbols, Instances, and the Library
Understanding the Document Library
Working with Common Libraries and External Libraries
Working with multiple Document Libraries
Reading the Library panel
Organizing Library panels
Defining Content Types
Raw data
Drawing objects and shape primitives
Groups
Native symbols
Imported media elements
Editing Symbols
Modifying a symbol in Edit mode
Editing a symbol in a new window
Editing a symbol in place
Editing symbols from the Library
Returning to the Main Timeline or scene
Modifying Instance Properties
Applying basic color effects to symbol instances
Changing the symbol type of an instance
Swapping symbols
Building Nested Symbol Structures
Converting a raw shape into a Graphic symbol
Using Graphic symbols in a button
Animating Graphic symbols in a Movie Clip
Adding a Movie Clip to a Button symbol
Modifying a MovieClip instance
9-Slice Scaling for Movie Clip Backgrounds
Using the Movie Explorer
Filtering buttons
The display list
The Movie Explorer Options menu
The contextual menu
Using Authortime Shared Libraries
Summary
Chapter 7: Applying Color
Introducing Color Basics
Discussing Web-safe color issues
Using hexadecimal values
Using color effectively
Working in the Swatches Panel
Swatches panel options
Importing custom palettes
Using the Color Panel
Adjusting fill and stroke transparency
Working with gradient fills
Controlling gradient fill colors
Using alpha settings with gradients
Selecting bitmap fills
Working with Droppers, Paint Buckets, and Ink Bottles
Summary
Chapter 8: Working with Text
Considering Typography
Text Field Types in Flash
Static text boxes
Editable text fields: Dynamic and input
The Text Tool and the Properties Panel
Working with the Text tool
Setting text attributes in the Properties panel
Font Export and Display
Smoothing text with anti-alias settings
Rendering outlines with the Bitmap text setting
Understanding device fonts
Working with the Use Device Fonts setting
Troubleshooting font display
Controlling font substitution
Font Symbols and Shared Font Libraries
Creating a font symbol
Updating font symbols at authortime
Using font symbols in runtime shared libraries
Modifying Text
Editing text manually
Moving beyond the box with live filter effects
Summary
Chapter 9: Modifying Graphics
Sampling and Switching Fills and Strokes
The Eyedropper tool
The Ink Bottle tool
The Paint Bucket tool
Using the Paint Bucket Gap size option
Using the Paint Bucket Lock Fill option
Transforming Gradients and Bitmap Fills
Adjusting the center point with the Gradient Transform tool
Rotating a fill with the Gradient Transform tool
Adjusting scale with the Gradient Transform tool
Setting gradient fill overflow styles
Skewing a bitmap fill with the Gradient Transform tool
Gradient Transform Used for Lighting Effects
Applying Modify Shape Menu Commands
Convert Lines to Fills
Creating scalable artwork
Expand Fill
Soften Fill Edges
Free Transform Commands and Options
The Transform panel
The Modify Transform menu
The Free Transform tool
Transforming shapes, symbols, text, and groups
Manipulating Symbols in 3D Space
Controlling the camera view: Perspective and vanishing point
Transforming symbols with the 3D Rotation tool
Moving symbols with the 3D Translation tool
Modifying Item Types
Stacking order
Grouping
Applying Break apart
About the Magic Wand option
Tracing bitmaps
Working with Drawing Objects and Combine Object Commands
Working with Compound Shapes
Editing with Find and Replace
Using the History Panel
Replay Steps
Copy Steps
Clear History
History View
Save As Command
Summary
Part III: Creating Animation and Effects
Chapter 10: Animation Strategies
Establishing Ground Rules
Defining Variables
The environment
The materials
The motion
Adding Personality
Manipulating Perception and Illusion
Viewpoint, framing, and depth
Anticipation
Secondary motion
Understanding the Laws of Nature
Law #1: Inertia
Law #2: Acceleration
Law #3: Action/reaction force pairs
Summary
Chapter 11: Timeline Animation and the Motion Editor
Basic Methods of Flash Animation
Frame-by-Frame Animation
Adding keyframes
Creating frame-by-frame animation
Modifying Multiframe Sequences
Onion skinning
Editing multiple frames
Using Tweens for Animation
Shape tweening
Adding shape hints
Motion tweening
Modifying motion tween properties
Working with motion tween spans and layers
Editing motion paths
Adding control to animation along a motion path
Working with motion presets
Adjusting Easing and Tween Properties with the Motion Editor
Controlling property views in the Motion Editor
Editing tween curves and property key frames
Eases and custom eases
Animating 3D properties
Integrating Multiple Animation Sequences
Moving tweens onto symbol timelines
Organizing symbol instances on the Main Timeline
Reusing and Modifying Tweened Symbol Instances
Controlling symbol instances with ActionScript
Make Flash work for you
Summary
Chapter 12: Applying Filters, Blends, Guides, and Masks
Applying Filters in Flash
Adding and adjusting filters
Creating dimensional shadows
Combining filters and saving custom presets
Animating filters with motion tweens
Using the Motion Editor to control filter interpolation
Controlling Color: Properties versus Filters
Adjust Color filter
Color properties
Using advanced color effects: Understanding relative and absolute color settings
Layering Graphics with Blend Modes
Understanding blend modes
Applying basic blends
Applying compound blend modes: Alpha and Erase
Creating an animated Alpha blend
Working with Special Layer Types: Guides and Masks
Using guide layers
Adding masks
Masking with a filled shape
Masking with a group
Masking with a symbol instance
Masking text
Using Distribute to Layers
Summary
Chapter 13: Character Animation Techniques
Working with Large File Sizes
Storyboarding scenes and shots
Flash scenes and project files
Voices, sound effects, and ambient sound
Some Cartoon Animation Basics
Expressing motion and emotion
Anticipation
Weight
Overlapping actions
Blurring to simulate motion
Animator's Keys and Inbetweening
Walk cycles (or walk loops)
Repeaters
Types of walks
Coloring the Art
The model sheet
Gap problems
Speed coloring
Temporary backgrounds
Flash Tweening
Panning
Instance swapping
Motion guides
Lip-Syncing
Shape morphing is not for lip-syncing
Expression and lip-syncing
Lip-sync tricks
Syncing with music and sound effects
Backgrounds and Scenery
Runtime bitmap caching
Bitmaps
QuickTime limitations
Building layered backgrounds in Photoshop
Flash mask layers
Long pans
Multiplane pans
Blurring to simulate depth
Creating IK Armatures with the Bone Tool and Bind Tool
Finishing Up
Final output
Post production
Summary
Part IV: Integrating Media Files with Flash
Chapter 14: Adding Sound
Identifying Sound File Import and Export Formats
Import formats
Export formats
Importing Sounds into Flash
Assigning a Sound to a Button
Adding Sound to the Timeline
Organizing Sounds on the Timeline
Enhanced viewing of sound layers
Organizing sound layers with a layer folder
Synchronizing Audio to Animations
Event
Start
Stop
Stream
Stopping Sounds
Stopping an event sound
Stopping a single instance of a stream sound
Stopping all sounds
Editing Audio in Flash
Sound-editing controls
Applying effects from the Effect menu of the Properties panel
Sound Optimization Overview
Publish Settings for Audio
The Set options
Supporting audio and MP3 playback
Fine-Tuning Sound Settings in the Library
Settings for audio in the library
Combining methods for controlling sounds
Final Sound Advice and Pointers
VBR (Variable Bit Rate) MP3
Optimizing sounds for bandwidth usage
Extracting a sound from a Flash document
Summary
Chapter 15: Importing Artwork
Defining Vectors and Bitmaps
Knowing the File Formats for Import to Flash
Preparing Bitmaps
Preserving Bitmap Quality
Importing and Copying Bitmaps
Importing sequences
Working with layered bitmap files
Copying and pasting a bitmap into Flash
Applying color effects, alpha, and filters to bitmaps
Setting Bitmap Properties
Being prepared for common problems
Cross-browser consistency
Using the Bitmap Buttons in the Properties Panel
Swap
Edit
Making Sense of Bitmap Compression
24-bit or 32-bit lossless source files
8-bit lossless source files
Source files with lossy compression
Converting Rasters to Vectors
Using External Vector Graphics
Importing Vector Artwork
Copying and pasting a vector image into Flash
Importing Adobe Illustrator files
Optimizing Vectors
Interpreting complex vector artwork
Converting text to outlines
Optimizing curves
Runtime bitmap caching
Working with XFL: The Flash Format of the Future
Summary
Chapter 16: Displaying Video
Integrating Video: The Solutions
Loading a Flash Video file at runtime
Real-time streaming a Flash Video file at runtime
Embedding video into a Flash movie
Importing the Video
An overview of codec options
Compressing video with Adobe Media Encoder CS4
Using the Video Import wizard
Deploying video files with Flash CS4
Using the FLVPlayback Component (AS3)
Working with the Component parameters
Using FLVPlayback Custom UI components
Working with Cue Points
Working with Video Alpha Channels
Live action footage
Summary
Part V: Adding Basic Interactivity to Flash Movies
Chapter 17: Understanding Actions and Event Handlers
Actions and Event Handlers
What is ActionScript?
Navigating the Actions panel
A brief primer on code syntax
Your First Five Actions
gotoAndPlay() and gotoAndStop()
nextFrame() and prevFrame()
nextScene() and prevScene()
play() and stop()
navigateToURL()
Making Actions Happen with Event Handlers
Combining an action with an event handler to make a functioning button
The Flash event handlers
Creating Invisible Buttons and Using getURL
Summary
Chapter 18: Building Timelines and Interactions
A Brief History of Movie Clips: The Key to Self-Contained Playback
How Movie Clips interact within a Flash movie
One movie, several timelines
Targets and Paths Explained
Absolute paths
Relative paths
Targeting Movie Clips in Flash CS4
Summary
Chapter 19: Making Your First Flash CS4 Project
The Main Timeline as the Site Layout
Creating a plan
Setting up a local folder structure
Determining Flash movie properties
Mapping presentation areas to keyframes
Creating content for each area
Adding Navigation Elements to the Main Timeline
Creating text buttons for a menu
Browsing the video items
Text Scrolling with the TextArea Component
Using the Custom BlurFader Component
Making the Movie Accessible
Summary
Part VI: Distributing Flash Movies
Chapter 20: Publishing Flash Movies
Testing Flash Movies
Using the Test Scene or Test Movie command
Using the Bandwidth Profiler
Using the size report
Publishing Your Flash Movies
Publish Settings
Selecting formats
Using the Flash settings
Using the HTML settings
Using the GIF settings
Using the JPEG settings
Using the PNG settings
Creating Windows and Mac projectors
Publish Preview and Publish Commands
Using Publish Preview
Using Publish
Using Publish Profiles
Summary
Chapter 21: Integrating Flash Content with Web Pages
Writing Markup for Flash Movies
Using the <object> tag
Using the <embed> tag
Detecting the Flash Player
Plug-in versus ActiveX: Forcing content without a check
Detecting the Flash Player with Flash CS4
Detecting the Flash Player with SWFObject
Using Flash Movies with JavaScript and DHTML
A word of caution to Web developers
Understanding how Flash movies work with JavaScript
Changing HTML attributes
Adding a percentLoaded() method
Summary
Chapter 22: Using the Flash Player and Projector
Using the Stand-Alone Flash Player and Projector
Creating a projector
Distribution and licensing
Distribution on CD-ROM or DVD-ROM
Stand-Alone Limitations and Solutions
Using the Flash Player Plug-in for Web Browsers
Supported operating systems
Supported browsers
Plug-in and Flash movie distribution on the Web
Plug-in installation
Using the Settings in Flash Player 6 and Later
Privacy
Local Storage
Microphone
Camera
Player Utilities
Summary
Part VII: Approaching ActionScript
Chapter 23: Knowing the Nuts and Bolts of Code
Breaking Down the Interactive Process
Define your problems
Clarify the solution
Translate the solution into the interactive language
The Basic Context for Programming in Flash
Accessing ActionScript commands
Actions list organization in the Actions panel
The Help documentation
ActionScript 1.0 and 2.0
One Part of the Sum: ActionScript Variables
String literals
Expressions
Variables as declarations
Declaring Variables in ActionScript
Using actions to define variables
Loading variables from a predefined source
Establishing variables with HTML
Creating Expressions in ActionScript
Operators
Checking conditions: if . . . else actions
Branching conditions with switch() and case
Loops
Properties
Built-in functions
Creating and calling subroutines
Creating a Login Sequence with Variables
Summary
Chapter 24: Controlling Movie Clips
Movie Clips: The Object Overview
Movie Clip properties
Movie Clip methods
Event listener methods: The flexible Movie Clip handler
Other classes and functions that use the MovieClip object
Working with Movie Clip Properties
Positioning Movie Clips
Scaling Movie Clips
Rotating Movie Clip instances
Creating Draggable Movie Clips
Drag-and-drop basics
Detecting the drop position: Using dropTarget
Making alpha, scale, and blur sliders
Summary
Chapter 25: Using Functions and Arrays
What Are Data Types?
String
Number
Boolean
Object
Function
Undefined
Checking data types with typeof
Checking class type in ActionScript 3.0
Overview of Functions as Procedures
What functions do
When to create a function
How to define a function
How to execute a function
Managing Related Data: The Array Class
Creating a Dynamic Reusable Flash Menu
Summary
Chapter 26: Interacting with Movie Clips
Movie Clip Collision Detection
Using dropTarget
Collision detection with hitTestObject() and hitTestPoint()
Using the Mouse Class
Manipulating Color Attributes
Creating a ColorTransform object
Setting multiplier and offset values
Enabling Sound with ActionScript
Creating sounds with ActionScript
Creating a SoundTransform object
Creating volume and balance sliders for sounds
Printing with ActionScript
Summary
Part VIII: Applying ActionScript
Chapter 27: Animating with ActionScript
Reviewing the Tween Parameters
Making an Object Move Back and Forth
Animating 3D Properties
Following the Mouse Cursor
Summary
Chapter 28: Sharing and Loading Assets
Managing Smooth Movie Download and Display
Preloading a Flash Movie
Loading Flash Movies
Basic overview of Flash site architecture
Loading an external .swf file into a movie
How Flash handles loaded movies of differing dimensions
Placing, scaling, and rotating externally loaded Flash movies
Loading Images into Flash Movies
Loading MP3 Audio into Flash Movies
Loading a Flash Video into a Flash Movie
Displaying a Flash Video at Its Native Size
Adjusting video size with metadata
Setting the video size without metadata
Accessing Items in Shared Libraries
Setting up a shared library file
Specifying the shared library's location
Publishing the shared library movie file
Linking to assets from other movies
Updating shared assets
Summary
Chapter 29: Sending Data In and Out of Flash
Using Text Fields to Store and Display Data
Input text fields
Dynamic text fields
Defining a Data Process with States
Input state
Send state
Wait state
Output state
Creating a User Comment Form
Using XML Data in Flash Movies
Understanding XML
Loading an XML document into a Flash movie
Summary
Chapter 30: Applying HTML and Text Field Formatting
Exploring HTML Usage in Text Fields
Supported HTML tags
Formatting text with the Properties panel
Inserting HTML tags into text fields with ActionScript
Formatting fields with the TextFormat object
Applying style sheets to text fields
Inserting images into text fields
Using the TextEvent.LINK event with anchor tags
Controlling Text Field Properties
Scroll properties
Text rendering properties
Pixel-based Text Scrolling with Movie Clips
Summary
Chapter 31: Creating a Game in Flash
The Game Plan: Four Phases of Game Design
Game design
Interaction design
Visual and sound design
Scripting
Building the Project
Scripting the Game
Initializing the Game
Main Timeline and Document Class overview
The Hangman.as document class
The shared font layer
The placeholder GameView instance
Building the Interface
Creating text fields
Creating the alphabet
Starting the Game
Display the letters of the alphabet
Choose a random word
Create the letters of the displayed word
The User Input
Interpreting the User Input
Was the letter selected before?
Is the letter part of the word?
Checking the Status of the Game
Is the word complete?
Is the hangman complete?
Are there more words to guess?
How do you end the round?
Removing the hangman
Reset the game or just the round?
Added Feature: Storing User and Game Information
Summary
Chapter 32: Using Components
What Are Components?
Why Use Components?
Compiled Clips: A Specific Component Format
How to Add a Component
Where to Find Components, Assets, and Parameters
Components panel
Component Inspector panel
Library panel
Actions panel and ActionScript
Modifying Component Color Properties and Parameters
Removing Components from Your Movie
Components in Flash CS4
Button component
CheckBox component
ComboBox component
List component
RadioButton component
ScrollPane component
TextArea component
UIScrollBar component
Understanding the Listener Event Model for Components
What a typical listener looks like
Letting the component know who its listeners are
Using Components in Your Movie
Modifying Components
Global style formats
Changing styles for a component class
Changing styles for individual instances
Using Embedded Fonts with Components
Modifying AS3 Component Skins
Using the UILoader and ProgressBar Components
Adding a UILoader component to your Flash movie
Applying the ProgressBar component
Custom Components
Live preview
Exchanging and acquiring components
Summary
Chapter 33: Building an Image Gallery Component
Creating a Plan
Describing the feature set
Determining the server-side scripting requirements
Phase 1: Setting Up the Gallery Class
Reviewing the starter files
Constructing the Gallery component
Phase 2: Loading Thumbnails into the ScrollPane
Uploading scripts and images to your Web server
Building data properties for the Gallery class
Architecting the Thumbnail class
Creating thumbnail holders in the Gallery class
Phase 3: Displaying the Full-Size JPEG Image
Loading the full-size image
Updating the scroll bar and auto-loading the first image
Phase 4: Enhancing the Thumbnail and Image States
Tracking the selected thumbnail
Framing the selected thumbnail with the BevelFilter class
Creating a loading transition with the BitmapData and BlurFilter classes
Transitioning thumbnail states with the Tween and ColorMatrixFilter classes
Setting the image caption
Completing the thumbnail button handlers
Building a right-click download menu item for the full-size JPEG
Phase 5: Finalizing the Component
Copying existing component class files
Adding the component definition
Changing script paths for final deployment
Summary
Part IX: Appendixes
Appendix A: Using the CD-ROM
Appendix B: Guest Experts' Information
Appendix C: Digital Audio Basics
What is sound?
What affects the quality and size of sound files?
Appendix D: Digital Video Basics
Source format
Image quality
Sound quality
Subject matter
Adobe® Flash® CS4 Professional Bible
Robert Reinhardt and Snow Dowd
Adobe® Flash® CS4 Professional Bible
Published by:Wiley Publishing, Inc.111 River St.Hoboken NJ 07030-5774
www.wiley.com
Copyright © 2009 by Wiley Publishing, Inc., Indianapolis, Indiana
ISBN: 978-0-470-37918-9
Manufactured in the United States of America
10 9 8 7 6 5 4 3 2 1
Published by Wiley Publishing, Inc., Indianapolis, IndianaPublished simultaneously in Canada
No part of this publication may be reproduced, stored in a retrieval system or transmitted in any form or by any means, electronic, mechanical, photocopying, recording, scanning or otherwise, except as permitted under Sections 107 or 108 of the 1976 United States Copyright Act, without either the prior written permission of the Publisher, or authorization through payment of the appropriate per-copy fee to the Copyright Clearance Center, 222 Rosewood Drive, Danvers, MA 01923, (978) 750-8400, fax (978) 646-8600. Requests to the Publisher for permission should be addressed to the Permissions Department, John Wiley & Sons, Inc., 111 River Street, Hoboken, NJ 07030, (201) 748-6011, fax (201) 748-6008, or online at www.wiley.com/go/permissions.
Limit of Liability/Disclaimer of Warranty: THE PUBLISHER AND THE AUTHOR MAKE NO REPRESENTATIONS OR WARRANTIES WITH RESPECT TO THE ACCURACY OR COMPLETENESS OF THE CONTENTS OF THIS WORK AND SPECIFICALLY DISCLAIM ALL WARRANTIES, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE. NO WARRANTY MAY BE CREATED OR EXTENDED BY SALES OR PROMOTIONAL MATERIALS. THE ADVICE AND STRATEGIES CONTAINED HEREIN MAY NOT BE SUITABLE FOR EVERY SITUATION. THIS WORK IS SOLD WITH THE UNDERSTANDING THAT THE PUBLISHER IS NOT ENGAGED IN RENDERING LEGAL, ACCOUNTING, OR OTHER PROFESSIONAL SERVICES. IF PROFESSIONAL ASSISTANCE IS REQUIRED, THE SERVICES OF A COMPETENT PROFESSIONAL PERSON SHOULD BE SOUGHT. NEITHER THE PUBLISHER NOR THE AUTHOR SHALL BE LIABLE FOR DAMAGES ARISING HEREFROM. THE FACT THAT AN ORGANIZATION OR WEBSITE IS REFERRED TO IN THIS WORK AS A CITATION AND/OR A POTENTIAL SOURCE OF FURTHER INFORMATION DOES NOT MEAN THAT THE AUTHOR OR THE PUBLISHER ENDORSES THE INFORMATION THE ORGANIZATION OR wEBSITE MAY PROVIDE OR RECOMMENDATIONS IT MAY MAKE. FURTHER, READERS SHOULD BE AWARE THAT INTERNET WEBSITES LISTED IN THIS WORK MAY HAVE CHANGED OR DISAPPEARED BETWEEN WHEN THIS WORK WAS WRITTEN AND WHEN IT IS READ.
For general information on our other products and services or to obtain technical support, please contact our Customer Care Department within the U.S. at 877-762-2974, outside the U.S. at 317-572-3993 or fax 317-572-4002.
Wiley also publishes its books in a variety of electronic formats. Some content that appears in print may not be available in electronic books.
Library of Congress Cataloging-in-Publication Data: 2008942706
Trademarks: Wiley, the Wiley logo, and related trade dress are trademarks or registered trademarks of John Wiley & Sons, Inc. and/or its affiliates, in the United States and other countries, and may not be used without written permission. Adobe and Flash are registered trademarks of Adobe Systems Incorporated in the United States and/or other countries. All other trademarks are property of their respective owners. Wiley Publishing, Inc. is not associated with any product or vendor mentioned in this book.
About the Authors
After discovering Flash while working on an art project, Robert soon realized that there was a need for more comprehensive documentation of its capabilities. In 1998 not many people had even heard of Flash and publishers were wary of the limited market, but IDG Books Worldwide, Inc. (now Wiley Publishing, Inc.) committed to doing the Flash 4 Bible. The rest, as they say, is history. After studying and working together in Toronto for five years, Robert Reinhardt and Snow Dowd established a multimedia consulting and design company in Los Angeles in 1999 called [the MAKERS]. Five years in the Hollywood Hills saw them through the dotcom boom and bust and gave them the chance to work on a wide range of projects — without ever having to wear wool socks. Now based in Portland, Oregon, [the MAKERS] continue to do work for entertainment companies, educational institutions, entrepreneurs, independent artists, and nonprofit organizations — and enjoy wearing stylish rain boots. Snow and Robert have expanded their services by working with DesignProVideo.com to produce Flash training videos.
Robert Reinhardt — With a degree in photographic arts, Robert takes a holistic approach to the creation of compelling multimedia. For five years, Robert oversaw the growth of the Multimedia Platforms Group at Schematic, a worldwide interactive agency. There, he led various assignments including multimedia data analysis applications for Nielsen's Media and Entertainment division and created interactive applications for The Weather Channel's WeatherClassroom.com, DC Comics, and Microsoft Windows XP Media Center Edition spotlights for major cable networks. Robert now consults and trains a wide range of clients, from Adobe Systems to the Walt Disney Internet Group to UCLA's Center for International Emergency Medicine.
When he isn't building or consulting on Flash projects, Robert loves to teach and write about Flash and rich media technologies. In addition to this book, he is the coauthor of Flash MX 2004 ActionScript Bible (Wiley, 2004). He has developed and taught Flash workshops for Lynda.com, Art Center College of Design, and Portland State University, as well as conducted on-site training and seminars for clients in the United States and Canada such as LodgeNet, Wieden+Kennedy, and Scripps Networks. Robert has been a regular featured speaker at the Flashforward, FITC, Flashbelt, and SIGGRAPH conferences. Robert is also a writing partner for CommunityMX.com.
Snow Dowd — Snow initially collaborated with Robert Reinhardt on multimedia, film, and photography-based installation projects while earning a BFA in Image Arts and New Media at Ryerson University. During this time, she was also the production manager for Design Archive, one of Canada's preeminent architectural photography studios. Working with renowned photographers and an exacting international client base of architects and designers helped her gain a deeper appreciation for images, architecture, and industrial design.
Fully immersed in digital production since 1998, Snow is able to synthesize her background in visual arts and communication theory with an ever-evolving software toolkit. Focusing on content architecture and interface design, Snow strives to create print and Web projects that are beautiful, functional, and memorable. Snow was honored to be featured in the June 2005 spotlight on FlashGoddess.com — a great place to go if you've been wondering where all the women are in the Flash world.
About the Technical Editor
Jeremy Petty — Jeremy is a design engineer based in Portland, Oregon. His work has ranged from developing electro-mechanical systems used in a miniature TOF-mass spectrometer to designing tools sets for the sports apparel industry. For fun, he enjoys bicycling around the Portland area, searching for the prefect surface to longboard on, and spending time with his family.
Credits
Acquisitions Editors
Laura SiniseAaron Black
Project Editor
Katharine Dvorak
Technical Editor
Jeremy Petty
Copy Editor
Scott Tullis
Editorial Manager
Robyn Siesky
Business Manager
Amy Knies
Senior Marketing Manager
Sandy Smith
Vice President and Executive Group Publisher
Richard Swadley
Vice President and Executive Publisher
Barry Pruett
Project Coordinator
Patrick Redmond
Graphics and Production Specialists
Stacie BrooksAndrea HornbergerJennifer MayberrySarah Philippart
Quality Control Technicians
Amanda Graham
Jessica Kramer
Proofreader
Bonnie Mikkelson
Indexer
Christine Spina Karpeles
Media Development Project Manager
Laura Moss
Media Development Assistant Project Manager
Jenny Swisher
Media Development Associate Producer
Kit Malone
In 1997, Macromedia acquired a small Web graphics program, FutureSplash, from a company named FutureWave. FutureSplash was a quirky little program with the astounding capability to generate compact, vector-based graphics and animations for delivery over the Web. With Macromedia's embrace, Flash blossomed. In 2005, Adobe Systems, Inc. acquired Macromedia and, in three short years, has successfully integrated Flash into their family of powerhouse graphics, video, and design software. Not only has the Flash platform obtained ubiquity, but Flash content is now more easily created across a wide range of professional software applications. The Flash Player plug-in ships with most major browsers and operating systems. Flash graphics appear not only all over the Web, but also on television and movie screens, on phones, on kiosks, and even in art galleries.
As the Web-surfing public and the development community have continued to demand more of Flash, Adobe has delivered. After Creative Suite 3 was released, Adobe went out into the world and sat with people using its programs to see what they used, what they needed, and how the next generation of Creative Suite tools could support daily workflow and specialize tasks more effectively. The result is a release that promotes expressiveness and enhances efficiency while encouraging best practices in development — a functional and an inspiring combination that has earned rave reviews from visual designers and code-oriented developers at all levels.
The Flash CS4 Professional interface is consistent with other Creative Suite 4 (CS4) products; it has tool options and other editing features contained in streamlined panels and lots of important changes to the authoring environment. The Mac interface is nearly 100 percent identical to the Windows interface, with support for docked panels, tabbed panels, and enhancements to the coding environments in Flash CS4 and Dreamweaver CS4.
Flash movies can communicate directly with server-side scripts and programs, using standard URL-encoded variables, XML-formatted structures, Web services, or powerhouse data transfers from Flash Remoting–enabled servers. Sounds can be imported and exported as MP3 audio for high-quality music on the Web at the smallest file sizes. Flash Player 10 supports nearly every Web file format you'll ever come across. Loading of JPEG, PNG, GIF, MP3, FLV, AAC, and H.264 video content streamlines production and maintenance of dynamic high-volume media sites. The updated FLVPlayback component and the addition of custom tools, custom effects, and behaviors offer Flash users of all skill levels some exciting possibilities. Evidence of the dominance of the Flash format can be found in the wide range of third-party developers creating applications that output to the Flash movie format (.swf files). Flash has fulfilled its promise of becoming the central application for generating interactive content for delivery on the Web; the potential only seems to expand as more developers tap into the data-handling power of Flash and its increasingly sophisticated graphics capabilities as it continues to grow beyond the computer screen.
Is there any other Flash book for you?
Adobe Flash CS4 Professional Bible is the most comprehensive and exhaustive reference on Flash. It helps you get started on your first day with the program and will still be a valuable resource when you've attained mastery of the program. When you're looking for clues on how to integrate Flash with other programs so that you can deliver unique and compelling content in the Flash format, you'll know where to turn. We've put significant effort into this edition, updating all ActionScript content to use ActionScript 3.0, the most recent version of the ActionScript language available in Flash Player 9 or higher.
Flash is not just a single tool. You can think of Flash as a multitasking application. It's an illustration program, an image/sound/video editor, an animation machine, and a scripting engine, all rolled into one. In this book, we look at each of these uses of Flash and explain how all the features work together.
To address advanced scripting topics and more server-side development issues, Robert coauthored the Flash ActionScript Bible series with Joey Lott (Wiley), which has been updated and expanded with the past three releases of Flash. Roger Braunstein, Mims Wright, Josh Noble, and Joey have written the new ActionScript 3 Bible (Wiley, 2007) to fully address advanced use of the ActionScript 3.0 scripting language. If you're already adept at creating animation and basic interactive interfaces in Flash and you want to expand your knowledge of more complex coding techniques, you may want to compare the table of contents in this book with that of ActionScript Bible to determine which book covers the topics you're most interested in.
How to Get the Most out of This Book
Here are some things to know so you can get the most out of this book:
First, to indicate that you need to select a command from a menu, the menu and command are separated by an arrow symbol. For example, if we tell you to select the default workspace layout from the Flash application menu, the instructions will say to choose Window ➪ Workspace ➪ Essentials.
Parts I and II of the book are entirely dedicated to project planning and getting familiar with the Flash interface. Parts III and IV explain how to generate animation and integrate other media files into your Flash movies. Parts V through VIII gradually introduce you to the power of ActionScript and show you how to take advantage of Flash components to quickly create dynamic applications that support live data. Although this book was written to take a beginner by the hand, starting from page one, you can also use it as a reference. Use the index and the table of contents to find what you're looking for, and just go there, or jump in anywhere. If you already know Flash and want to get some details on sound, for example, just go to any of the chapters in Part IV, “Integrating Media Files with Flash.”
This is a real-world production book: We've worked hard to ensure that our lessons, examples, and explanations are based on professional conventions. We've also continued the use of expert tutorials to bring you tips and techniques from talented people in the Flash industry, so that you can benefit from their specialized expertise. Tutorials that do not relate to Flash CS4 but still offer some valuable information on specific topics have been archived online: you can find them at www.flashsupportcom/archive.
The CD-ROM that accompanies this book contains many of the source Flash project files (.fla), with original artwork and ActionScript for the examples and lessons in the book. You can also find sample video files to encode with Flash video!
In order to create a forum for the delivery of updates, notes, and additional sample files, we have established an integrated Web site specifically for the Flash Bible series: www.flashsupportcom. At the Web site, you'll find new material and corrections that may be added after the book goes to print, and moderated forums where readers can share information or ask questions. We invite you to contribute your comments and suggestions for this edition so that we can continue to improve the material.
We have created a chapter-based evaluation system that makes it easy for you to let us know what parts of this book were most (or least) useful to you. Visit www.flashsupportcom/feedback and let us know what you think of the content as you progress through the book.
Icons: What Do They Mean?
Although the icons are pretty standard and self-explanatory (they have their names written on them!), here's a brief explanation of what they are and what they mean.
Tips offer you extra information that further explains a given topic or technique, often suggesting alternatives or workarounds to a listed procedure.
Notes provide supplementary information to the text, shedding light on background processes or miscellaneous options that aren't crucial to the basic understanding of the material.
When you see the Caution icon, make sure you're following along closely to the tips and techniques being discussed. Some external applications may not work exactly the same with Flash on different operating systems and some workflows have inherent risks or drawbacks.
If you want to find related information to a given topic in another chapter, look for the Cross-Reference icons.
The New Feature icons point out differences between Flash 8 and previous versions of Flash.
For related information, resources, or software available online, look for the Web Resource icons.
This icon indicates that the CD-ROM contains a related file and points you to the folder location.
How This Book Is Organized
This book has been written in a format that gives you access to need-to-know information very easily in every section (or part) of the book. If you are completely new to Flash, then you'll want to read Parts I through VI. After you have developed a familiarity with the Flash interface and the new drawing and effects tools, you can proceed to Parts VII and VIII. We've included step-by-step descriptions of real Flash projects to help you “leap” from the intro topics to the advanced topics. These sections of the book guide you through the production process, helping you apply ActionScript and production techniques that may be new to you.
If you've already used Flash, then you may want to review the changes to the Flash CS4 interface in Part I, and then jump right into other specific parts to learn more about character animation, ActionScript, creating artwork and content in other applications, and integrating Flash with HTML. There are many new features and workflow enhancements for new and experienced users alike in every section of the book, so even if you've done a lot of work in Flash, it's worth scanning each part for an introduction to new tools and techniques.
Part I: An Introduction to Flash Web Production
The first part of this book explores the Flash file format and how Flash CS4 fits into the evolution of the program (Chapter 1), explains the context in which Flash movies interact on the Web (Chapter 2), and gives an overview of multimedia planning and some specific techniques and suggestions that will make your Flash project development less painful and more productive (Chapter 3).
Part II: Mastering the Flash Environment
This part gives you all the information you need to feel comfortable in the Flash CS4 authoring environment. Get an introduction to, and some tips for, customizing the Flash UI (Chapter 4). Learn where to find your drawing tools and how to use them efficiently (Chapter 5), and then discover all the ways that Flash helps you to organize and optimize project assets (Chapter 6). Learn key color concepts relevant to multimedia production and find out why Flash has the best color tools yet (Chapter 7). Jump into using text-editing tools and see how to get the best-looking type and the smallest file sizes in your Flash projects (Chapter 8). Finally, learn how to modify text and graphics to get the most out of your Flash artwork (Chapter 9).
Part III: Creating Animation and Effects
After you've learned how to find your way around the Flash interface and how to create static graphics, you can get some perspective on animation strategies (Chapter 10). Learn to make things move and how to work with different symbol types to optimize your animation workflow (Chapter 11). Add polish and pizzazz with Flash filter effects and blend modes (Chapter 12). Finally, get special production tips for professional character animation and broadcast-quality graphics (Chapter 13).
Part IV: Integrating Media Files with Flash
Now that you're fluent in the Flash workspace, take your projects to the next level by adding sound, special graphics, and video assets. In Chapter 14, you learn the basics of digital sound, and how to import, optimize, and export high-quality sound for different types of projects. Chapter 15 gives you an overview of how to bring vector or raster artwork from other programs into Flash and how to protect image quality while optimizing your Flash movies. Chapter 16 introduces the exciting new video features of Flash CS4 and the new Adobe Media Encoder CS4 application, including the use of the high-quality AVC/H.264 video codec.
Part V: Adding Basic Interactivity to Flash Movies
Learn how to start using Flash actions to create interactive and responsive presentations. Get oriented in the Flash CS4 Actions panel and fundamental ActionScript in your movies (Chapter 17). Use ActionScript in Flash movies to control internal elements on multiple timelines, such as nested Movie Clips (Chapter 18). Use Flash CS4 components to create fast, clean interfaces for multipart presentations that also include some of the Accessibility options (Chapter 19).
Part VI: Distributing Flash Movies
You need to learn how to export (or publish) your Flash presentations to the .swf file format for use in an HTML document, or within presentations in other formats. Chapter 20 details options in the Flash CS4 Publish settings, and provides tips for optimizing your Flash movies in order to achieve smaller file sizes for faster download performance. If you prefer to hand-code your HTML, read Chapter 21, which describes how to use the <embed> and <object> tags and how to create plug-in detection systems for your Flash movies using the SWFObject JavaScript library. If you want to find out how to create a Flash stand-alone projector, or use the Flash stand-alone player, check out Chapter 22.
Part VII: Approaching ActionScript
Learn the basic elements of ActionScript syntax (Chapter 23), and how to use ActionScript to control properties and methods of MovieClip objects (Chapter 24). Learn about making functions and arrays (Chapter 25), detecting Movie Clip collisions, and using the ColorTransform, Sound, and PrintJob classes for dynamic control of movie elements (Chapter 26).
Part VIII: Applying ActionScript
Learn how to use ActionScript to animate elements in a Flash movie (Chapter 27). Get an introduction to runtime MP3, JPEG/PNG/GIF, and FLV loading features as well as how to share and load assets in multiple .swf files (Chapter 28). Start creating Flash movies that send data with the LoadVars object and learn to integrate XML data with Flash movies (Chapter 29). Take control of text fields using updated HTML tags, the TextFormat class, CSS (Cascading Style Sheets), and high-quality anti-aliasing options (Chapter 30). Part VIII includes a detailed chapter dedicated to building a Flash game from the ground up (Chapter 31). Find out how to use the many User Interface components that ship with Flash CS4 to enhance your Flash projects (Chapter 32). Finally, build a Gallery component from scratch that works with dynamic PHP scripts to load image thumbnails and display full-size downloadable JPEG images (Chapter 33).
Part IX: Appendixes
In the appendixes, you'll find directions for using the CD-ROM (Appendix A), and a listing of contact information for the guest experts is also available (Appendix B). You can also find information on digital sound basics that explains sound sampling rates and bit-depths (Appendix C), and information on digital video basics (Appendix D).
Getting in Touch with Us
You can find additional information, resources, and feedback from the authors and other readers at www.flashsupportcom. We want to know what you think of individual chapters in this book. Visit www.flashsupportcom/feedback to send us your comments.
If you have a great tip or idea that you want to share with us, we'd like to hear from you. You can also send comments about the book to [email protected].
Also, check Appendix B to learn more about this book's various contributors and guest experts, including URLs of their work and contact information for people who don't mind being contacted directly by our readers.
For quality concerns or issues with the CD-ROM, you can call the Wiley Customer Care phone number: (800) 762-2974. Outside the United States, call 1 (317) 572-3994, or contact Wiley Customer Service by e-mail at [email protected]. Wiley Publishing, Inc. will provide technical support only for CD-ROM installation and other general quality-control items; for technical support on the applications themselves, consult the program's vendor.
Adobe Wants to Help You
Adobe has created a Feature Request and Bug Report form to make it easier to process suggestions and requests from Flash users. If you have an idea or feature request for the next version or you find a bug that prevents you from doing your work, let the folks at Adobe know. You can find the online form at www.adobecom/wishform.
The simple fact is this: If more users request a specific feature or improvement, it's more likely that Adobe will implement it.
Regardless of your geographic location, you always have access to the global Flash community for support and the latest information through the Adobe online forums at www.adobe.com/cfusion/webforums/forum/index.cfm?forumid=15.
For inspiration and motivation check out the Site of the Day, weekly features, and case studies at www.adobecom/showcase.
This book would not have been possible without the dedication and talent of many people. Although much of the content in this edition has changed to reflect changes in the tools, there is also a good deal of content from dedicated contributors that has been carried over from the previous edition. We are always grateful for the added breadth and depth the tutorials from our guest experts bring to the content. First and foremost, we would like to thank the Flash development community. In our combined experiences in research and multimedia production, we haven't seen another community that has been so open, friendly, and willing to share advanced tips and techniques. It has been gratifying to be involved as the community keeps expanding and to see the innovators in the first wave of Flash development become mentors to a whole new generation. Thank you all for continuing to inspire and challenge audiences and each other with the possibilities for Flash.
We would like to thank everyone at Wiley Publishing who supported us as we researched and revised, week after week. Katharine Dvorak, our project editor, was friendly, professional, and compassionate with our writing schedule — we knew she was working just as hard as we were when we received near-instant replies late at night. A Flash Bible production team can't steer itself — our gratitude goes to Laura Sinise and Aaron Black, our acquisitions editors, and Scott Tullis, our copy editor. Jeremy Petty, our technical editor and dear friend, was instrumental in helping us keep our material honest and effective.
Many of the scripts provided in this book would not be complete without the “instant messenger” help provided by Joey Lott, Paul Newman, Danny Patterson, Bruce Hyslop, Roger Braunstein, Geoff Stearns, and Phillip Kerman. We'd also like to thank Richard Blakely and Jerry Chabolla at Influxis.com for providing the ongoing Flash Media Server hosting for this book's streaming video examples.
Of course, this book about Flash wouldn't even exist without the hard work of the people at Adobe who make it all possible. Many thanks to the developers, engineers, and support staff at Adobe, especially Jen Taylor, Richard Galvan, Mike Downey, Mike Chambers, Erica Norton, Nivesh Rajbhandari, Peter deHaan, and Jen deHaan. We're also indebted, as always, to all our intrepid fellow developers and authors, who helped us to get our bearings in early versions of Flash CS4.
Part I: An Introduction to Flash Web Production
In This Part
Chapter 1: Understanding the Adobe Flash CS4 Blueprint Chapter 2: Exploring Web Technologies Chapter 3: Planning Flash Projects
If you're new to Flash or to multimedia production, this section gets you started on the right foot. If you are a veteran Flash user, this section gives you some perspective on the evolution of Flash and the workflow options available in Adobe Flash CS4.
Chapter 1 provides a comprehensive overview of the strengths and weaknesses of the Flash format and some background on where Flash came from and how it has evolved. Chapter 2 explores the various ways that Flash movies interact with other Web formats and introduces some of the issues that need to be considered when planning for specific audiences. Chapter 3 has expanded coverage of strategies for multimedia project planning, including descriptions of how to create flowcharts, site maps, and functional specification documents.
Chapter 1: Understanding the Adobe Flash CS4 Blueprint
In This Chapter
Exploring the uses of Flash CS4 Identifying Flash file types Introducing the structure of Flash documents
Since its humble beginnings as FutureSplash in 1997, the Flash authoring tool and the Flash platform have matured into a powerful tool for deploying a wide range of media content. With every new version released, the possibilities have increased for imaginative and dynamic content creation — for the Web and beyond. After Adobe acquired Macromedia in 2005, Adobe has expanded Flash capabilities in several Creative Suite products, as well as development tools such as Adobe Flex Builder. The Adobe user interface is consistent across powerhouse applications such as Adobe Photoshop, Adobe Flash, and Adobe Illustrator.
In this chapter, we introduce Flash CS4 and explore the many possibilities available for your productions. We also discuss how Flash compares to or enhances other programs that you may be familiar with.
Flash content can be viewed in a few different ways. The most common method is from within a Web browser, either as an asset within an HTML page or as a Web site completely comprised of a master Flash movie using several smaller Flash movies as loaded SWF assets. The Flash Player is also available as a stand-alone application (known as a projector), which can be used to view movies without needing a Web browser or the plug-in. This method is commonly used for deployment of Flash movies on CD-ROMs, floppy disks, or other offline media formats.
You can learn more about projectors and stand-alones in Chapter 22, “Using the Flash Player and Projector.”
The Key Is Integration
Flash has seen significant development over its 12 years in both capability and design. Consistently with each new release, designers and developers push the technology into new territory. In its current iteration, Flash CS4 enables you to create content that's compatible with Adobe Flash Player 10, one of the largest updates to the Flash Player. There are two sides of the integration coin: designing the user interface and high-end programming with ActionScript 3.0. Flash CS4 continues to satisfy both designers and programmers — all the new authortime visual effects in Flash CS4 and Flash Player 10 are fully programmable with ActionScript, the programming language of Flash.
Flash CS4 Professional, also referred to simply as Flash CS4, adds several enhancements to previous editions:
• One version: You don't have to worry about which version of the Flash authoring tool to purchase — there's only one version! If you haven't upgraded from Flash 8 or earlier, you might be using one of two editions of the Flash authoring tool. If you have Flash CS4, you have access to any feature we discuss in this book (and more!).
• CS4 interface: Flash CS4 sports a completely revised user interface layout, with tools and panels that match the look and feel of other Adobe Creative Suite applications such as a Photoshop and Illustrator. The panels can be docked or stacked, and panels can be reduced to icon-only or icon-and-text views.
• Adobe document import: Because Adobe oversees the development of Photoshop, Illustrator, and Flash, it's much easier to coordinate file format interoperability between the applications. You have more options than ever to faithfully bring Photoshop, Illustrator, and After Effects content into Flash documents. Many of the CS4 tools can now export XFL packages that enable a smooth workflow from tools such as Illustrator and After Effects into Flash.
• Adobe Device Central CS4: Flash CS4 ships with an updated version of Adobe Device Central. This program enables you to set up a Flash, Photoshop, Illustrator, or After Effects document prepped with the proper screen size and attributes for deployment to a wide range of mobile devices. Presets for manufacturers such as Nokia, Samsung, and Motorola determine the frame size, frame rate, FlashLite (or Flash Player) version, and ActionScript version compatible for each device.
• Improved animation and drawing features: It's easier than ever to apply motion tweens to your Flash artwork with the new Motion Editor panel and the Motion Presets panel. Every aspect of your motion tween can be accessed and updated in the Motion Editor panel, sporting a look and feel very similar to the Timeline panel of Adobe After Effects. Flash CS4 also includes a new Deco tool that can draw intricate patterned fills within your artwork.
• Improved font menus: If you've used other Adobe graphics software such as Photoshop and Illustrator, you likely miss the font family lists in past versions of Flash. In Flash CS4, you'll find a consistent font menu across the CS4 product line.
• 3D transformations: You can now control a third dimension, or the Z axis, on two dimensional (2D) artwork created or imported into your Flash document, including video! You can animate the X, Y, and Z axis of objects in the new Motion Editor!
• Inverse kinematics (IK): Adobe added two new tools, the Bone tool and the Bind tool, to create linked segments that respond as a contiguous element. For example, if you want to create an animated frog, you can create the independent pieces of the frog's shape, connect them with the Bone tool, and then animate the entire frog! If you move one connected element in the chain of elements, the whole framework responds.
• Adobe Flash Media Encoder: Adobe did an excellent job retooling the compression settings and options for the Flash Video CS3 Encoder, which is now called the Adobe Media Encoder. Now you can export AVC/H.264 video content compatible with Flash Player 9 Update 3 or later.
• Flash Player detection update: Flash CS4 improves the Flash Player detection capabilities in the Publish Settings' HTML tab. Flash CS4 can create one HTML page that detects a target version of the Flash Player and displays the appropriate content. Geoff Stearns' SWFObject, which we covered in Flash CS3 Professional Bible (Wiley, 2007), is now the standard for Flash Player detection in Flash CS4.
• Authoring for Adobe AIR: You can now directly publish your Flash documents to the new Adobe AIR platform. AIR enables you to run Flash, HTML, and PDF content directly from the desktop, without a Web browser!
• Updated Project panel: The new Project panel in Flash CS4 requires much less work for you to get a set of folders and files ready for easy access in the authoring environment. You no longer need to manually create folder structures and link files to a project file.
• Adobe Soundbooth sample sound library: Flash CS4 ships with over 150 sound-effect audio files from Adobe Soundbooth. You can use these sound effects with your Flash content royalty free.
• Improved Library panel: The Library panel in Flash CS4 is now searchable, and you can now create new symbols in specific folders in the Library panel.
Many enhancements are not directly seen in the authoring environment, though. Flash Player 10 adds the following enhancements, among others:
• Enhanced creative effects: In addition to the 3D treatment of 2D objects mentioned earlier in this chapter, Flash Player 10 features a new custom filter-creation tool, the Adobe Pixel Bender toolkit. This new filter-creation tool, based on the scripting language called Hydra, enables you to build your own filter effects! There's also a completely revamped text layout engine, which can support right-to-left (RTL) languages such as Hebrew and Arabic, vertical text layout, and typographic elements like ligatures.
• Visual performance improvements: Flash Player 10 can offload more heavy graphics processing directly to the video graphics card. This hardware acceleration enables faster compositing of graphics and video content in your Flash files.
• Audio/video enhancements: You can use new transport protocols for real-time streaming video and peer-to-peer connections. Adobe has a new audio codec, Speex, added to Flash Player 10 for better real-time voice communications.
• Enhanced local file access: Previous releases of the Flash Player could only access file bytes but not display or manipulate them back to the local system without using a remote server to communicate and download updated content. Flash Player 10 now enables a user to load a local file and save new content back to the desktop without any server interaction.
If you're targeting a Flash Player 6 audience, you might want to consider targeting Flash Player 10 as well. Why? Flash Player 6 is capable of running Express Install scripts, which enable a Flash movie to automatically update the installed version of the Flash Player. Also, users with Flash Player 7 or later can receive automatic player updates. By default, Flash Player 7 checks Adobe's site every 30 days for new player updates. This process occurs silently in the background and doesn't require the user to upgrade his or her player installation manually. Theoretically, then, within 30 days of the release of any new Flash Player, including Flash Player 10, most browsers that had Flash Player 7, 8, or 9 will then have Flash Player 10.
For a complete list of features in Flash CS4, open the new browser-based help system by choosing Help ⇒ Flash Help, and then selecting Using Flash ⇒ Using Flash CS4 Professional ⇒ Resources ⇒ What's New ⇒ New Features.
Adobe also released new versions of Dreamweaver and Fireworks, as part of the CS4 Web Suite software bundle. The user interfaces for Flash, Dreamweaver, and Fireworks are very similar, each touting a Property inspector, dockable panel sets, and specialized tools to integrate the products with one another.
Although the broad array of Flash work created by Web designers and developers already speaks for itself, the sleek interface and the powerful new features of Flash CS4 surely inspire more challenging, functional, entertaining, informative, bizarre, humorous, beautiful, and fascinating experiments and innovations.
There are more ways to use Flash than there are adjectives to describe them, but here are just a few examples:
• Forms for collecting user information and dynamically loading custom content based on this interaction
• Real-time interaction with multiple users on a forum or support site, including live audio/video feeds of connected parties
• Complex online games with rich graphics and interaction, including multiplayer games
• A video portfolio using Flash Video capabilities and dynamic loading of content
• Animated ID spots and loading screens with built-in download detection
• A practical Web utility, such as a mortgage calculator or a search tool
• Robust chat rooms based on XML and server-socket technology
• An audio interface dynamically pulling in requested songs, using native Flash 8 support for MP3 loading
• Interactive conceptual art experimentations involving several users, 3-D, or recording and playback of user interaction
• Shopping and e-commerce solutions built entirely by using Flash and server-side technology
• Interfaces for kiosks at museums, banks, and shopping centers
• Alternative content or movie attributes based on system capability testing (if a device or desktop doesn't support audio streaming, then a text equivalent of the audio transcript is presented to the user)
• Projectors used for creating slide show presentations in the style of PowerPoint, either on CD-ROM or an alternative storage device
• Broadcast-quality cartoons, advertising, or titling
• Optimized animations for the Web, and for mobile devices such as cellphones or PDAs
• An interface that addresses accessibility issues by modifying certain elements when a screen reader is active
• Flash movies specifically exported for use in digital video projects requiring special effects and compositing
This list is obviously far from complete and is ever expanding with each new release of the program. As you can probably tell from this list, if you can imagine a use for Flash, it can probably be accomplished.
The topography of Flash CS4
Before you attempt to construct interactive projects in Flash, you should be familiar with the structure of the authoring environment. Even if you already know a previous version of Flash, learning this is advisable. That's because with the release of Flash CS4, Adobe has reorganized existing features to the interface and has either moved or improved other features and functionalities. So, to get a firm footing in the new interface, we strongly suggest that you work your way through this book — from the beginning.
Chapter 4, “Interface Fundamentals,” introduces the updated Flash CS4 interface and gives you tips for customizing your workspace and optimizing your workflow.
Moreover, you need to proactively plan your interactive projects before you attempt to author them in Flash. An ounce of preplanning goes a long way during the production process. Don't fool yourself — the better your plan looks on paper, the better it performs when it comes to the final execution.
We detail the foundation for planning interactive Flash projects in Chapter 3, “Planning Flash Projects,” and you will find these concepts reiterated and expanded in chapters that discuss specific project workflows. Chapter 19, “Making Your First Flash CS4 Project,” is a great place to start applying these planning strategies.
We consolidated the overview of interactive planning in the early chapters of the book. In later chapters, we included step-by-step descriptions of real-world projects that allow you to see how all the theory and planning suggestions apply to the development of specific projects.
Chapter 31, “Creating a Game in Flash,” walks you through the logic required to design and script a functional and engaging game. Chapter 33, “Building an Image Gallery Component,” describes the process of creating an entire component from the ground up, utilizing many of the visual effects available in ActionScript.
