XML with Audio file cue points and UTF-8 extended character set


A continuing "work in progress," an example of using XML to drive structure / content in a Flash application.

Text is fed from file "rent.xml," which contains pointer to "rent.mp3" as an attribute of one of the Title XML firstChild elements.

Lyrics are imported as "lyric" elements in the XML file, with attributes "singer" and "cue" providing information on the placement of the lyrics on screen with cuePoint information for the Flash media player embedded onstage.

There are eight elements (rentActor1 - rentActor8) available for mouse handling and manipulation. The rentActor4 and rentActor6 are disabled. Global sizing between 50% and 100% are controlled by clicking on rentActor2 (shrinking) and rentActor7 (unshrinking). The rentActor elements 1, 3, 5, and 8 can be dragged and restaged on the screen.

Action begins with a display of the background MovieClip, followed by a raise in _alpha values of the rentActor MovieClip objects onscreen. The XML load is complete when the <songtitle> element displays in the main textArea.

After the sound Object concludes, the 8 rentActor elements fade to an _alpha of 0.