<< Click to Display Table of Contents >> Navigation: ThinBASIC Modules > TBASS (Sound Module) > Channels > TBASS_ChannelGetAttributes |
Description
Retrieves the basic playback attributes of a sample, stream or MOD music. Can also get the sample rate of a recording channel.
Syntax
n = TBASS_ChannelGetAttributes(hChannel, Frequency, Volume, Pan)
Returns
Number
If successful, then %TBASS_TRUE is returned, else %TBASS_FALSE is returned. Use TBASS_ErrorGetCode to get the error code.
Parameters
Name |
Type |
Optional |
Meaning |
hChannel |
Numeric |
No |
The channel handle... a HCHANNEL, HMUSIC, HSTREAM, or HRECORD. |
Frequency |
Variable |
No |
The sample rate 100 (min) to 100000 (max) 0 = original rate (when the channel was created) |
Volume |
Variable |
No |
The volume 0 (silent) to 1 (full) |
Pan |
Variable |
No |
The panning position -1 (full left) to +1 (full right), 0 = centre |
Remarks
Frequency, Volume, Pan must be single variables and not expressions. They will receive back relevant values.
Restrictions
See also
Examples