Mpeg Advance Xtra MPEG ADVANCE XTRA HELP: SPRITE PROPERTIES  
 

The Sprite properties are only accessible when a Mpeg Advance Xtra sprite is being displayed on the stage.

 

Image - Gets the current video frame as an image object, ready to be used with imaging Lingo functions. The image of sprite is only available on Windows if the canImageOffScreen() member function returns true and the sprite is playing in non-dts mode.

Example:

myimg = sprite(1).image

 

 

Currenttime - The current position of the Media file, in milliseconds.

Lingo example:

put sprite(1).currenttime

-- 22345

 

 

Rate - The playback rate Media file. The Xtra supports rates between 0 and 2 (reverse playback is not supported.) The movierate can also be used to play or pause the media, setting it to 1 or 0.

Lingo example:

put sprite(1).rate

-- 1

 

 

Movietime - The current position of the Media file, in milliseconds. This has the same value as the currenttime of sprite property.

Lingo example:

put sprite(1).movietime

-- 22345

 

 

Movierate - The playback rate Media file. This has the same value as the rate of sprite property.

Example:

sprite(1).movierate = 0.5

 

 

Mediabusy - Indicates whether the Media file is playing. Possible values are 0 (FALSE) and 1 (TRUE).

Lingo example:

put sprite(1).mediabusy

-- 1

 

 

MostRecentCuePoint - The index of the last cue point passed. Consult Director's documentation for additional info on this property.

Lingo example:

put the mostrecentcuepoint of sprite 1

-- 2

 

 

Duration - The duration of the Media file, in milliseconds. Can only be retrieved, not set.

Lingo example:

put sprite(1).duration

-- 100000

 

 

Volume - The current volume of the Media file, in a linear scale from 0 to 255. Can be tested and set.

Example:

sprite(1).volume = 128

 

 

Visible - Hides or shows the sprite window. Can be tested and set, and is useful to prevent black flashes at the beginning or end of media playback on Windows.

Example:

sprite(1).visible = false