tip: media playback component

Available only in Flash MX 2004 Professional.

I find that many components are quite hard to figure out. The documentation helps you get some things right, but not everything. My biggest problem with the Media Playback component was getting my video to be the right size. This does not happen automatically.

I had a 320 x 240 FLV video named "dancers.flv" in the same folder with the SWF. I dragged the Media Playback component out of the Components panel and onto the Stage.

(1) The first crucial step: Open the Component Inspector and enter the URL of the FLV file. In this case, the URL is:

dancers.flv

The component on the Stage must be selected (click it once) for the Component Inspector to work properly. If you can't find it, go to Window menu > Development Panels > Component Inspector.

> See the Component Inspector (pop-up image).

So I tested my movie, and the video was teensy tiny. Nowhere near its real size of 320 x 240.

(2) So, back into Flash. Use the Properties panel to change the W and H of the Media Playback component. (The default is 300.1 x 200.0.) Add at least 16 pixels to W and H for the borders, and also 70 pixels for the contol bar (add to H). Thus a 320 x 240 video needs a 336.1 x 326 playback component. Now the video is its full size.

> See the video in the Media Playback component (pop-up).

The video quality in this example is not great, because I compressed the video a lot (the FLV is 6.3 MB). Flash can handle very good quality video. The tradeoff is in file size.

> More tips