ActionScript 3 version of the ccPlayer
In addition to the CCforFlashAS3 component, NCAM has created a flexible video player which incorporates the CCforFlashAS3 component. If you are not handy with Flash programming but want to embed a FLV player on your Web page, using ccPlayerAS3.swf may be sufficient. To see how it all gets wired, open ccPlayerAS3.html in a text editor and pay particular attention to the <object> and <embed> sections.
Use the sample html file, ccPlayerAS3.html; shown in the image below, as a guide to create a Web page containing a captioned Flash Video file.
In particular, note the parameters that are passed into the movie <object> and src <embed> parameters. The fourteen parameters, in addition to the SWF name, are:
Also note: If you wish to allow for full-screen display, you'll need to include the "allowFullScreen" parameter to the <embed> and <object> tags.
With this version of ccPlayerAS3, the height of the player changes based on the height of the video. While this is done automatically when the player receives the height from the video's metadata, it may be more desirable to have the height set before the video is loaded. This eliminates the visual resizing done after the player is launched. To do this, identify both the height and width of the video using the ccVideoHeight and ccVideoWidth parameters.
In instances where the video height is smaller than the maximum of 360 pixels, the height of the player's footprint can be reduced. (The width will always be 480 pixels.) In order to do this, the Flash movie cannot be set to scale in the html page. The height of the Flash content that is visible on the Web page is set in the <object> and <embed> tags. To determine the desired height for the player, take the video height and add 52 pixels for the captions and 52 pixels for the controls. If the movie does not contain captions, only add in the 52 pixels for the controls. For example, if a widescreen video (480 px x 270px) is being displayed with captions, the height that would be entered in the <object> and <embed> tags would be 374 (270 pixels for video + 52 pixels for captions + 52 pixels for controls). The maximum height of ccPlayerAS3 is 464 pixels.
For information on how to author captions for use with ccPlayerAS3, please refer to Authoring Captions for Flash.
Various accessibility features have been built into the ccPlayerAS3. Currently, in order to access the keyboard and screen-reader features, the user needs to be using the Internet Explorer browser on the PC. The accessibility features that have been included are:
Closed captioning is available if captions have been provided with the video. Captions can be provided in an external file using either the DFXP or QTtext formats or embedded within the video using a tool such as Captionate. When captions are available, a CC button is displayed allowing viewers to hide or show the captions. If captions are not available, the button is disabled.
All of the buttons have been given labels for use with screen readers. They include:
Note: When the Search, Language, or Instructions windows are open, the video is paused. When the windows are closed, the video resumes playing, if the video was playing prior to the window being opened.
In order to use the keyboard shortcuts, the playback controls in the Flash Player movie need to have focus. This is done by tabbing into the Flash movie until one of the buttons in the control area is highlighted, such as the Play/Pause button. Screen-reader users will need to have the virtual pc cursor mode off to access the keyboard shortcuts.
The following keyboard shortcuts are available:
While the search window is open, ccPlayerAS3 limits tabbing to only the contents inside the window. There are three objects in this window: the search edit text box for the search term, the search activation button, and the close search window button. In our JAWS testing, it was noted that if the user tabbed past the close search window button, the next button outside of the window was read, even though the focus had returned to the search edit text box. If this occurs, shift-tab will correctly speak the contents of the window.
When the caption language window is opened, the focus goes to the language that is currently being played in the captions. If additional languages are available, these languages can be found by using the up and down arrow keys. In this window, the tab key serves to select the currently-highlighted language. The escape key will close the window without changing the current language.
In order to read the instructions, the screen-reader must be in virtual pc cursor mode. The instructions appear after the the close instructions window button.
Users of JAWS 9 will notice that dynamically-changing text will be read when the change occurs. This will be most noticeable each time a new caption appears. If this occurs, use the hide captions button to hide the caption display.
The video playback controls in the full-screen mode are not accessible to keyboard and screen-reader users. Keyboard control is limited to exiting the full-screen mode using the Escape key. Note that full-screen mode does not function properly unless the virtual pc cursor in JAWS is off. The full-screen mode has not been tested with Window-Eyes.
Accessibility in Full-screen mode – The video playback controls in the full-screen mode are not accessible to keyboard and screen-reader users. Keyboard control is limited to exiting the full-screen mode using the Escape key. Note that full-screen mode does not function properly unless the virtual pc cursor in JAWS is off. The full-screen mode has not been tested with Window-Eyes.
For technical support, please use the public CC for Flash listserv. To subscribe send an e-mail to requests AT mail4 DOTwgbh DOT org with the words subscribe CCforFlash in the subject.