Mpeg Advance Xtra MPEG ADVANCE XTRA HELP: SPRITE FUNCTIONS  
 

The following sprite functions can be called from scripting to control playback of Mpeg Advance Xtra sprites. The sprite must be present in the score, and the function should be targeted at the sprite channel number.

 

sprite(x).play() - Used to start or resume playback of a Media file. Playback is usually started automatically when the sprite is loaded, unless the "Paused at Start" option is checked.

Example:

sprite(1).play()

 

 

sprite(x).pause() - Used to pause playback of a Media file.

Example:

sprite(1).pause()

 

 

sprite(x).seek(time) - Seeks the video to a different time in the Media file, and pauses the video. Time should be expressed in milliseconds.

Example:

sprite(1).seek(15000)

 

 

sprite(x).stepForward() - Moves the video playback position one frame forward.

Example:

sprite(1).stepForward()

 

 

sprite(x).stepBack() - Moves the video playback position one frame backward.

Example:

sprite(1).stepBack()

 

 

sprite(x).playsegment(starttime, endtime) - Plays a segment of the Media file. Please note that using this option actually limits access to the times of the stream that falls outside the playback segment boundaries. You should use another playSegment() command to seek to a different time on the stream.

Example:

sprite(2).playSegment(10000, 25000)

 

 

sprite(x).isPastCuePoint(cuepointindex) - Returns TRUE if the cue point indicated has already passed, FALSE otherwise. The Xtra only supports this function used with cuepoint indexes, not names.

Lingo example:

sprite(1).isPastCuePoint(2)

put the result

-- 1