play-sound in Miscellaneous
(play-sound -> boolean
filename async?)
filename : string
async? : boolean
Plays a sound file. If async? is false, the function does not
return until the sound completes. Otherwise, it returns immediately.
The result is #t if the sound plays successfully, #f
otherwise.
Under Windows, only .wav files are supported.
Under X, the function invokes an external sound-playing program; under
Linux, the default is the play program. Under Solaris, the
default is audioplay. Other X platforms do not have a
default. For any X platform, a play command can be defined through
the '|MrEd:playcmd| preference preference (see
Preferences). The command string is
formatted with the input filename -- so the command string
should contain a ``~s'' where the filename should be
substituted -- then executed as a shell command.
Under Mac OS, Quicktime is used to play sounds; most sound formats (.wav, .aiff, .mp3) are supported in recent versions of Quicktime. In order to play .wav files, Quicktime 3.0 (compatible with OS 7.5 and up) is required.