Retrieves the type of input of a recording input source.
Namespace: Un4seen.Bass
Assembly: Bass.Net (in Bass.Net.dll) Version: 2.4.17.5
Syntax
Parameters
- input
- Type: SystemInt32
The input to get the settings of... 0 = first, -1 = master.
Return Value
Type: BASSInputTypeOne of the BASSInputType values (BASS_INPUT_TYPE_ERROR on error).
Remarks
ERROR CODE | Description |
---|---|
BASS_ERROR_INIT | BASS_RecordInit(Int32) has not been successfully called - there are no initialized. |
BASS_ERROR_ILLPARAM | input is invalid. |
BASS_ERROR_UNKNOWN | Some other mystery problem! |
Platform-specific
The input type information is only available on Windows. There is no "what you hear" type of input defined; if the device has one, it will typically come under BASS_INPUT_TYPE_ANALOG or BASS_INPUT_TYPE_UNDEF.
On OSX, there is no master input (-1), and only the currently enabled input has its volume setting available (if it has a volume control).
Examples
Bass.BASS_RecordInit(-1); // init the default device int mic = -1; BASSInputType flags; for (int n=0; (flags=Bass.BASS_RecordGetInputType(n)) != BASSInputType.BASS_INPUT_TYPE_ERROR; n++) { if ( (flags & BASSInputType.BASS_INPUT_TYPE_MASK) == BASSInputType.BASS_INPUT_TYPE_MIC ) { // found the mic! mic = n; break; } } if (mic != -1) Console.WriteLine( "Found a MIC at input {0}", mic ); else Console.WriteLine( "No MIC found!" );
See Also