SndDisposeChannel
SndDisposeChannel Disposes of a specified channel
#include <Sound.h> Sound Manager
OSErr SndDisposeChannel(chan, quietNow );
SndChannelPtr chan; a pointer to a sound channel
Boolean quietNow 0=await completion; 1=immediate return
returns Error Code; 0=no error
The SndDisposeChannel function disposes of the channel specified in the
chan parameter and releases all memory allocated by the Sound Manager
for that channel. If your application created its own sound-channel record in
memory or installed a sound as a voice, the Sound Manager does not dispose of
that memory.
chan a pointer to a sound channel
quietNow SndDisposeChannel can dispose of a channel immediately or wait
until the queued commands are processed. If quietNow is set to TRUE,
a flushCmd command and then a quietCmd command are sent to the
channel. This removes all commands, stops any sound in progress,
and closes the channel. If quietNow is FALSE,
Sound Manager issues a quietCmd command only and waits until
the quietCmd command is received by the synthesizer before
disposing of the channel
Returns: an operating system Error Code.
noErr (0) No error
badChannel (-205) Channel is corrupt or unusable