play

Parent Previous Next

play

y = play ( x,repeat[=1],devID[=""] )
y = play ( handle,x,repeat[=1],devID[=""] )
y = handle.play ( x,repeat[=1],devID[=""] )

Audio playback

arg

type

Description

Unit or Value scale

handle

HAUD

handle to audio playback


x

AUD

audio signal


repeat

SCAL

number of repeats


devID

TXT

string identifier of the playback device (NOT YET IMPLEMENTED--as of AUXLAB 1.44)


Outputs

  • y is either an audio handle, either newly created or existing. y is -1 if the playback fails or the specified handle is invalid.

Notes

  • If devID is not specified, the default device or the last device selected for playback will be used.
  • If play is called for the audio handle, handle is queued in the back of the playback list and played when the existing list is exhausted.
    If play is called for an audio signal, a new audio handle is generated.

Examples

  • To play x (and don't care about asynchronous playing),
    play(x)
  • To play x and, then, y in sequence
    h=play(x)
    h.play(y) while x is played.
    If h.play(y) is given after playing x is done, it doesn't play and returns -1

See Also

pause | resume | status | stop | qstop

Created with the Personal Edition of HelpNDoc: Full-featured Kindle eBooks generator