Retrieves all a sample's existing channels.
Namespace: Un4seen.Bass
Assembly: Bass.Net (in Bass.Net.dll) Version: 2.4.17.5
Syntax
Parameters
- handle
- Type: SystemInt32
Handle of the sample.
Return Value
Type: Int32If successful, the array of existing channels is returned (which might have zero elements), else is returned. Use BASS_ErrorGetCode to get the error code.
Remarks
If you need to determine whether a particular sample channel still exists, it is simplest to just try it in a function call, eg. BASS_ChannelGetAttribute(Int32, BASSAttribute, Single).
ERROR CODE | Description |
---|---|
BASS_ERROR_HANDLE | handle is not a valid sample handle. |
Examples
int[] chans = Bass.BASS_SampleGetChannels(handle); if (chans != null) { // go through them all and... for (int a=0; a<chans.Length; a++) { // set the sample rate to 10000 Bass.BASS_ChannelSetAttribute(chans[a], BASSAttribute.BASS_ATTRIB_FREQ, 10000f); } }
See Also