BASS_ASIO_ChannelReset
Resets the attributes of a channel (or all channels).
BOOL BASS_ASIO_ChannelReset(
BOOL input,
int channel,
DWORD flags
);
Parameters
input | Dealing with an input channel? FALSE = an output channel.
|
channel | The input/output channel number... 0 = first, -1 = all channels.
|
flags | The attributes to reset. A combination of the following.
BASS_ASIO_RESET_ENABLE | Disable the channel. This includes mirror channels.
| BASS_ASIO_RESET_JOIN | Unjoin the channel.
| BASS_ASIO_RESET_PAUSE | Unpause the channel.
| BASS_ASIO_RESET_FORMAT | Set the channel's sample format to the native format.
| BASS_ASIO_RESET_RATE | Set the channel's sample rate to the device rate.
| BASS_ASIO_RESET_VOLUME | Set the channel's volume to normal (1.0).
| BASS_ASIO_RESET_JOINED | Also reset any channels that are joined to the specified channel. This can be used in combination with BASS_ASIO_RESET_JOIN to unjoin all channels from the specified one.
|
|
Return value
If successful, then TRUE is returned, else FALSE is returned. Use BASS_ASIO_ErrorGetCode to get the error code.
Error codes
BASS_ERROR_INIT | BASS_ASIO_Init has not been successfully called.
|
BASS_ERROR_ILLPARAM | The input and channel combination is invalid.
|
Remarks
When resetting all channels (channel = -1), the resetting only applies to all channels of the specified type, ie. input or output, not both.
Example
Disable all output channels and remove all joins between them.
BASS_ASIO_ChannelReset(FALSE, -1, BASS_ASIO_RESET_ENABLE | BASS_ASIO_RESET_JOIN);
See also
BASS_ASIO_ChannelEnable, BASS_ASIO_ChannelEnableBASS, BASS_ASIO_ChannelEnableMirror, BASS_ASIO_ChannelJoin, BASS_ASIO_ChannelPause, BASS_ASIO_ChannelSetFormat, BASS_ASIO_ChannelSetRate, BASS_ASIO_ChannelSetVolume