Playing external flv or f4v files dynamically, Behaviors used in video playback – Adobe Flash Professional CC 2014 v.13.0 User Manual
Page 371
Controlling external video playback with ActionScript
Playing external FLV or F4V files dynamically
Behaviors used in video playback
The FLVPlayback component
Media components (Flash Player 6 and 7)
Playing external FLV or F4V files dynamically
An alternative to importing video into the Flash Professional authoring environment is to use either the FLVPlayback component or ActionScript to
dynamically play external FLV or F4V files in Flash Player. You can also use the FLVPlayback component and ActionScript together.
You can play FLV or F4V files posted as HTTP downloads or as local media files. To play back an external FLV or F4V file, post an FLV or F4V
file to a URL (either an HTTP site or a local folder) and add either the FLVPlayback component or ActionScript code to the Flash Professional
document to access the file and control playback during runtime.
Using external FLV or F4V files provides the following capabilities that are not available when using imported video:
You can use longer video clips without slowing down playback. External FLV or F4V files are played using cached memory, which means
that large files are stored in small pieces and accessed dynamically; they do not require as much memory as embedded video files.
An external FLV or F4V file can have a different frame rate from the Flash Professional document in which it plays. For example, you can set
the Flash Professional document frame rate to 30 fps and the video frame rate to 21 fps, which gives you greater control in ensuring smooth
video playback.
With external FLV or F4V files, Flash Professional document playback does not have to be interrupted while the video file is loading.
Imported video files can sometimes interrupt document playback to perform certain functions (for example, to access a CD-ROM drive). FLV
or F4V files can perform functions independently of the Flash Professional document, and so do not interrupt playback.
Captioning video content is easier with external FLV or F4V files because you can use callback functions to access metadata for the video.
For more information on playing back FLV or F4V files, see “Playing back external FLV files dynamically” in
in the ActionScript 3.0 Developer’s Guide.
Additional resources
The following resources are available with additional information about video and ActionScript:
Video tutorials:
(Creativecow.com)
(Creativecow.com)
Articles:
Behaviors used in video playback
Video behaviors provide one way to control video playback. Behaviors are prewritten ActionScript scripts that you add to a triggering object to
control another object. Behaviors add the power, control, and flexibility of ActionScript coding to your document without having to create the
ActionScript code. Video behaviors play, stop, pause, rewind, fast-forward, show, and hide a video clip.
To control a video clip with a behavior, use the Behaviors panel to apply the behavior to a triggering object, such as a movie clip. Specify the event
that triggers the behavior (such as releasing the movie clip), select a target object (the video that is affected by the behavior), and when
necessary, select settings for the behavior, such as the number of frames to rewind.
Note: The triggering object must be a movie clip. You cannot attach video playback behaviors to button symbols or button components.
The following behaviors in Flash Professional control embedded video:
Behavior
Purpose
Parameters
Play Video
Plays a video in the current document.
Instance name of target video
Stop Video
Stops the video.
Instance name of target video
364