Learning Flash Media Server 3

Book description

If you're interested in recording and streaming media using Flash Media Server 3 (FMS3) and Adobe's Real-Time Messaging Protocol, this unique 267-page PDF-only book is the perfect primer. It is not a reference, but a systematic guide to developing FMS3 applications using ActionScript 3.0, with chapters that focus on specific aspects of the server and how they work.

FMS3 is very different from regular web servers. Because its open-socket server technology stays connected until users quit the application, you can stream audio, video, text, and other media in real time. FMS3 is also quite different from previous versions, a fact that web developers familiar with Flash Media Server 2 or Flash Communication Server 1.5 will quickly discover.

Don't worry. With Learning Flash Media Server 3 and a little experience with Flash CS3 and ActionScript 3.0, anyone can get up to speed in no time. You'll learn how to install FMS3, organize your development environment with Apache web server, and use the management console before diving into the whys and hows of:

  • Recording and playing back streaming audio and video in VP6 and H.264 formats
  • Using the new Flash Media Encoder to stream and record video
  • Camera and microphone settings
  • Non-persistent client-side remote shared objects
  • Two-way audio-video communications
  • Broadcasting and server-side bandwidth control
  • Working with server-side files: the file class
  • Server-side shared objects
  • Server-side streams
  • Setting up a software load handler using FMS3's new server-side NetStream
  • Bringing in data and working with configuration files

At the heart of every chapter is a core set of code that shows the minimum requirements needed for different procedures. Beyond that, Learning Flash Media Server 3 provides you with plenty of options for using FMS3's different versions -- the full-feature server, the streaming-only server, and the limited-user development server. It's a whole new world of media, and this book puts you right at the doorstep. Ready to enter?

Publisher resources

View/Submit Errata

Table of contents

  1. Adobe Developer Library
  2. 1. Getting Started with Flash Media Server 3
    1. The New Flavors for Flash Media Server 3
    2. What Is a Media Server?
      1. Enter RTMP
      2. Special Languages and Documentation
    3. Installing FMS3
      1. Installation Steps for Windows
      2. Installation Steps for Linux
    4. Organizing Your Development Environment
      1. Server-Side Files
      2. Client-Side Files
      3. Setting Up with a Macintosh
    5. Testing FMS3 Connections
      1. Same computer:
      2. Different computers:
    6. Using the FMS3 Administration Console
    7. Using This Book
      1. Flash and ActionScript 3.0
      2. Client-Side and Server-Side ActionScript
  3. 2. Recording and Playing Back Streaming Audio and Video
    1. Streaming and Broadcasting
    2. Minimalist Project
      1. Camera and Microphone
      2. Minimum Code to Record FLV File
      3. Flash Media Encoder 2 for FMSS Users
      4. Minimum Code to Stream FLV
        1. Playing FLV Files
        2. Metadata
        3. Build Your Own FLV Player
      5. Playback Using the FLVPlayer Component
    3. Combined Record and Playback Application
  4. 3. Setting Your Camera and Microphone
    1. Camera and Microphone Methods for Setting Parameters
      1. Instantiating Camera and Microphone Objects
      2. Default Camera and Microphone Settings
    2. Minimalist Project
      1. Minimum Code to Set Up Camera and Microphone and Display Results
      2. Setting Decisions
      3. Microphone Bandwidth Usage and Rate Settings
      4. Microphone Settings and Latency
    3. Dynamically Testing Your Camera and Microphone Settings
    4. Key Considerations
    5. Adjusting Camera and Audio with Flash Media Encoder
  5. 4. Nonpersistent Client-Side Remote Shared Objects
    1. Sharing Data on Multiple Connections
      1. Persistent and Nonpersistent Shared Objects
      2. Uses of Nonpersistent Remote Shared Objects
    2. Instantiating Remote Shared Objects
      1. Setting Up Shared Object Storage: Slots
      2. Inspecting a Shared Object
        1. The SyncEvent Class
        2. The changeList Property
      3. Syncing Shared Objects
    3. Minimalist Project for Shared Movie Clip
    4. Minimalist Project for Shared Text
    5. Minimalist Project for Shared Function
    6. An Upgraded Text Chat
      1. Chatter Considerations
      2. A Better Chat Application
  6. 5. Two-Way Audio-Video Communications
    1. Face-to-Face Communication
    2. The NetStream Bundle
    3. The NetStream Class and Live Streams
    4. The World’s Easiest Two-Way A/V Chat Application
    5. A Better Two-Way Chat Application
      1. Keeping Track of Users
        1. The Application Class
        2. The Client Class
      2. The Server-Side Script
      3. The Client-Side Strategy
        1. The Responder Class
        2. Responder Callback Function
      4. The Client-Side Applications
    6. Four-Way Conference Application
      1. Two Equals Two: Four Equals Twelve
      2. Positioning the Clients and their Streams
      3. Building the Conference Application
    7. Moving On to More Server-Side Applications
  7. 6. Broadcasting and Server-Side Bandwidth Control
    1. Casting Many Streams
    2. Switching Cameras
      1. Selecting a Camera
      2. Two-Camera Switch
    3. The Minimum Studio
      1. Utility Stream Class
      2. The Basic Broadcast Studio
      3. The Minimum TV
    4. Introduction to the Server Side
      1. Using SSAS
      2. Setting Server-Side Client Bandwidth Limits
      3. Launching a Server Action from the Client Side
    5. Dynamic Camera, Microphone, and Bandwidth Controls
    6. Bandwidth Checker
      1. Setting Up the Client Class
    7. Conclusion
  8. 7. Working With Server-Side Files: The File Class
    1. Recording Data
    2. The File Class
      1. Creating a File Class Instance
      2. Writing to a File
      3. Reading a File
      4. Minimal Client-Side Write and Read File Data
      5. Deleting Files
    3. Client-Side Formatting
    4. Server-Side Formatting
      1. Server-Side Data Initiation
    5. Beggar’s Database
  9. 8. Server-Side Shared Objects
    1. What Are Server-Side Shared Objects?
    2. Working with Server-Side Shared Objects
      1. Making a Minimalist Room List: Server-Side Class
      2. Making a Room List: Client-Side Retrieval
    3. Removing Users
      1. Client Removal Made Easy
      2. Client-Side Removal Module
    4. Persistent Server-Side Shared Object
      1. Minimalist Server-Side Shared Object
      2. Adding Properties and Slots to Server-Side Shared Objects
      3. Sending Persistent Server-Side Shared Object Data to the Client Side
        1. Sending Shared Object Data
        2. Catching Sends
      4. Creating the Minimalist Application
    5. The Idea Factory
      1. Multiple Server-Side Properties
      2. Client-Side Modules
      3. Deleting Persistent Shared Objects
  10. 9. Server-Side Streams
    1. Stream Management
    2. Anatomy of Stream.play( )
      1. Start, Length, and Reset Parameters
    3. Playing MP3 Files
      1. Selecting FLV Files to Play with Server-Side Script
      2. Client Names One Stream, Can Choose Many Streams
      3. Simultaneous Live and Recorded Streams
    4. Changing Streams
      1. Server-Side Code
      2. Control Module
      3. Viewer Module
      4. Reporter Module
    5. Server-Side NetStream Class
      1. Publishing the Client-Side Stream
      2. Playing the Stream from Multiple Servers
  11. 10. Bringing in Data and Working with Configuration Files
    1. Cue Points, Metadata, and Stream Completion
    2. Server-Side LoadVars Class
      1. FMS 3.0 Server-Side LoadVars Class Properties
      2. Passing Name-Value Pairs
    3. Minimalist Example Using Server-Side LoadVars( )
      1. Server Side LoadVars
      2. Client Side Bandwidth Selector
    4. Server-Side XML Class
      1. Client-Side and Server-Side XML Class
      2. Placing Data in an XML File
      3. Loading Into and Extracting Data from the XML File
      4. Minimalist Example Using Server-Side XML Class
    5. Using the Configuration Files
      1. Mapping the Config Files
      2. Changing XML and ini Files
        1. FMS.ini
        2. Server.xml
        3. Users.xml
        4. Logger.xml
        5. Adaptor.xml
        6. Vhost.xml
        7. Application.xml
    6. Doing More with Flash Media Server 3
  12. About the Author
  13. Copyright

Product information

  • Title: Learning Flash Media Server 3
  • Author(s): William Sanders
  • Release date: March 2008
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9780596515904