Green Thomas foundation The basics of creating and deploying Flash video How to use the new HD features of the Flash Player to deliver full-screen, DVD-quality video to a web page How to master several amazing video effects such as green screen superimposing, video walls, and interactive video How to bring your users into the action through webcams… and much more Foundation Flash CS3 Video D o you want to master Flash video and create awesome, interactive, video-based web applications? This might just be the book for you Flash CS3 Professional has kicked out the jams on video creativity and broadened the ability to deliver on-demand video to everything from your computer to your cell phone Couple this with the ability to deliver DVD-quality video to a web page, and you can see things have greatly changed… for the better This book provides you with a solid grounding in the fundamentals of what is fast becoming one of the most important areas of web growth As you move through the book, you will be introduced to some of the coolest web video techniques available Using a series of creative projects and exercises that build upon each other, you will be creating web video projects that range from the simple to the complex The only thing you need to begin is a basic understanding of the Flash interface You start with the basics: creating a code-free video application using a digital video You finish by creating a full-screen, DVD-quality video that plays on a typical web page Between those two projects, you will also discover how to create your own custom video player, an alpha channel video that’s used in some spectacular projects, and video projects in which your only asset in the Flash movie is an ActionScript 3.0 code block You will also get the chance to turn your creativity loose with filters and blend effects, develop interactive videos that react to mouse input, create some stunning masking effects, and explore how cue points and XML can combine to create captioned video and event triggers Flash CS3 Video Also Available In this book, you’ll learn: Foundation Flash CS3 Video Tom Green Adam Thomas Best of all, you will discover something that we experienced during the writing of this book: Flash video is incredibly fun! ISBN-13: 978-1-59059-956-3 ISBN-10: 1-59059-956-X 54499 SHELVING CATEGORY Flash US $44.99 Mac/PC compatible www.friendsofed.com 781590 599563 this print for reference only—size & color not accurate Master the latest techniques for creating, manipulating and delivering Flash video Learn how to play HD video on your web site Discover how to deliver Flash video to a cell phone spine = 0.761" 400 page count 956xFM.qxd 3/3/08 4:19 PM Page i Foundation Flash CS3 Video Tom Green Adam Thomas 956xFM.qxd 3/3/08 4:19 PM Page ii Foundation Flash CS3 Video Copyright © 2008 by Tom Green and Adam Thomas All rights reserved No part of this work may be reproduced or transmitted in any form or by any means, electronic or mechanical, including photocopying, recording, or by any information storage or retrieval system, without the prior written permission of the copyright owner and the publisher ISBN-13 (pbk): 978-1-59059-956-3 ISBN-10 (pbk): 1-59059-956-X ISBN-13 (electronic): 978-1-4302-0578-4 ISBN-10 (electronic): 1-4302-0578-4 Printed and bound in the United States of America Trademarked names may appear in this book Rather than use a trademark symbol with every occurrence of a trademarked name, we use the names only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark Distributed to the book trade worldwide by Springer-Verlag New York, Inc., 233 Spring Street, 6th Floor, New York, NY 10013 Phone 1-800-SPRINGER, fax 201-348-4505, e-mail orders-ny@springer-sbm.com, or visit www.springeronline.com For information on translations, please contact Apress directly at 2855 Telegraph Avenue, Suite 600, Berkeley, CA 94705 Phone 510-549-5930, fax 510-549-5939, e-mail info@apress.com, or visit www.apress.com Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use eBook versions and licenses are also available for most titles For more information, reference our Special Bulk Sales—eBook Licensing web page at http://www.apress.com/info/bulksales The information in this book is distributed on an “as is” basis, without warranty Although every precaution has been taken in the preparation of this work, neither the author(s) nor Apress shall have any liability to any person or entity with respect to any loss or damage caused or alleged to be caused directly or indirectly by the information contained in this work The source code for this book is freely available to readers at www.friendsofed.com in the Downloads section Credits Lead Editor Ben Renow-Clarke Production Editor Liz Berry Technical Reviewer David Stiller Compositor Dina Quan Editorial Board Clay Andres, Steve Anglin, Ewan Buckingham, Tony Campbell, Gary Cornell, Jonathan Gennick, Matthew Moodie, Joseph Ottinger, Jeffrey Pepper, Frank Pohlmann, Ben Renow-Clarke, Dominic Shakeshaft, Matt Wade, Tom Welsh Proofreader April Eddy Project Manager Richard Dal Porto Copy Editor Nancy Sixsmith Associate Production Director Kari Brooks-Copony Indexer Becky Hornyak Artist Kinetic Publishing Services, LLC Cover Image Designer Corné van Dooren Interior and Cover Designer Kurt Krames Manufacturing Director Tom Debolski 956xFM.qxd 3/3/08 4:19 PM Page iii To Lindsay Green (my daughter and best friend in the universe) and her husband-to-be, Phil Darling May your marriage be as joyful and adventurous as the one I have with your mother, Keltie —Tom Green To my Dad and Grandpa; I pray I can be half the husband and father you exemplified —Adam Thomas 956xFM.qxd 3/3/08 4:19 PM Page iv 956xFM.qxd 3/3/08 4:19 PM Page v CONTENTS AT A GLANCE About the Authors About the Technical Reviewer Introduction Chapter Editing Video for Flash Chapter Creating a Custom Player 25 45 67 Chapter “Talking Head” Video and Alpha Channels Chapter Adding Filters and Blend Effects to Flash Video Chapter Masking Video xix Chapter Alternative FLV-Creation Tools xv xvii Chapter Creating and Playing Flash Video 109 147 173 Chapter Flash Video Tricks, Tips, and Special Effects Chapter Playing with Multiple Videos 211 247 Chapter 10 The Camera Object and Flash Video Chapter 11 Cue Points and Captions in Flash Video Chapter 12 Going Small and Going Big with Flash Video Index xiii About the Cover Image Designer Acknowledgments xi 275 301 329 361 v 956xFM.qxd 3/3/08 4:19 PM Page vi 956xFM.qxd 3/3/08 4:19 PM Page vii CONTENTS About the Authors About the Technical Reviewer Introduction xiii About the Cover Image Designer Acknowledgments xi xvii xix Chapter Creating and Playing Flash Video xv Before you import Importing a video with the Flash Import Video Wizard Using the Flash CS3 Video Encoder 10 Playing an FLV file in Flash CS3 Professional 16 So your clients saw YouTube and now they want online video 21 What you’ve learned 23 Chapter Editing Video for Flash Nonlinear editing Windows Movie Maker Working with clips Editing in Movie Maker Exporting Apple iMovie Editing in iMovie Working with iMovie clips Adding and adjusting audio Exporting your movie What you’ve learned 25 Chapter Alternative FLV-Creation Tools 28 29 31 32 35 36 38 39 41 42 43 45 Data rate 46 Using Flix Pro 49 Using Sorenson Squeeze 4.5 55 vii 956xFM.qxd 3/3/08 4:19 PM Page viii CONTENTS Previewing your work Adobe Media Player Adobe Bridge CS3 What you’ve learned Chapter Creating a Custom Player 60 61 62 63 67 The FLVPlayback component and buffering 68 Creating a custom video controller 71 Adding the components at runtime 74 A word about skinning the components 75 Creating a custom video player 76 Connecting the Video object to a web server 79 Adding playback controls to a streaming video 82 Adding a Playing Progress bar and a timer to a streaming video 84 Your turn: Creating your own custom player 89 Preparing to move from Fireworks to Flash 91 Fireworks symbols and Flash symbols 93 Wiring up the custom player with ActionScript 3.0 95 Controlling the volume level of a video 100 Showing the loading and playing progress of an FLV file 102 What you’ve learned 105 Chapter “Talking Head” Video and Alpha Channels Creating an Alpha channel video with Adobe Premiere Pro CS3 Creating an Alpha channel video with Adobe After Effects CS3 Creating an FLV file directly out of After Effects CS3 Creating an Alpha channel video in Final Cut Pro Creating an FLV file with an Alpha channel Playing with Alpha channel video in Flash Trimming video Video-on-video Alpha channel video and scrollable text Reflections on an Alpha video theme Alpha video and HTML What you’ve learned 109 Chapter Adding Filters and Blend Effects to Flash Video Video trick #1: The “point-of-light” effect Video trick #2: The “ghost-in-the-machine” effect Video trick #3: Somebody fix the dang color! Filters and Flash video Applying filters and blends through ActionScript Using buttons to turn filters on and off Your turn: Using buttons to turn blend modes on and off What you’ve learned viii 111 116 125 126 130 132 133 135 136 136 140 143 147 148 149 150 151 157 160 166 170 ... used by Flash CS3 Importing a video into Flash using the Video Import Wizard Encoding a video using the Flash CS3 Video Encoder Using the Flash CS3 FLVPlayback component to play video Files used...956xFM.qxd 3/3/08 4:19 PM Page i Foundation Flash CS3 Video Tom Green Adam Thomas 956xFM.qxd 3/3/08 4:19 PM Page ii Foundation Flash CS3 Video Copyright © 2008 by Tom Green and Adam Thomas All... using the standalone Flash CS3 Video Encoder When you installed Flash CS3 Professional onto your computer you also installed a separate application called the Flash CS3 Video Encoder The Encoder