mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-26 09:48:45 -05:00
Audio: list available devices to console in debug mode
This commit is contained in:
parent
15bc1e2149
commit
863c7e15ef
@ -58,6 +58,14 @@ AudioDeviceManager::AudioDeviceManager()
|
||||
{
|
||||
m_inputDevicesInfo = QAudioDeviceInfo::availableDevices(QAudio::AudioInput);
|
||||
m_outputDevicesInfo = QAudioDeviceInfo::availableDevices(QAudio::AudioOutput);
|
||||
|
||||
for (int i = 0; i < m_inputDevicesInfo.size(); i++) {
|
||||
qDebug("AudioDeviceManager::AudioDeviceManager: input device #%d: %s", i, qPrintable(m_inputDevicesInfo[i].deviceName()));
|
||||
}
|
||||
|
||||
for (int i = 0; i < m_outputDevicesInfo.size(); i++) {
|
||||
qDebug("AudioDeviceManager::AudioDeviceManager: output device #%d: %s", i, qPrintable(m_outputDevicesInfo[i].deviceName()));
|
||||
}
|
||||
}
|
||||
|
||||
AudioDeviceManager::~AudioDeviceManager()
|
||||
|
@ -94,7 +94,7 @@ bool AudioInput::start(int device, int rate)
|
||||
|
||||
if (m_audioFormat.sampleSize() != 16)
|
||||
{
|
||||
qWarning("AudioInput::start: Audio device ( %s ) failed", qPrintable(devInfo.defaultInputDevice().deviceName()));
|
||||
qWarning("AudioInput::start: Audio device '%s' failed", qPrintable(devInfo.defaultInputDevice().deviceName()));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -106,7 +106,7 @@ bool AudioOutput::start(int device, int rate)
|
||||
|
||||
if (m_audioFormat.sampleSize() != 16)
|
||||
{
|
||||
qWarning("AudioOutput::start: Audio device ( %s ) failed", qPrintable(devInfo.defaultOutputDevice().deviceName()));
|
||||
qWarning("AudioOutput::start: Audio device '%s' failed", qPrintable(devInfo.defaultOutputDevice().deviceName()));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user