mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 01:03:57 +02:00
Merge pull request #4598 from sethalves/fix-linux-audio
avoid repeatedly calling QAudioDeviceInfo::availableDevices on linux
This commit is contained in:
commit
f51a259909
1 changed files with 4 additions and 0 deletions
|
@ -1281,6 +1281,9 @@ qint64 AudioClient::AudioOutputIODevice::readData(char * data, qint64 maxSize) {
|
|||
}
|
||||
|
||||
void AudioClient::checkDevices() {
|
||||
# ifdef Q_OS_LINUX
|
||||
// on linux, this makes the audio stream hiccup
|
||||
# else
|
||||
QVector<QString> inputDevices = getDeviceNames(QAudio::AudioInput);
|
||||
QVector<QString> outputDevices = getDeviceNames(QAudio::AudioOutput);
|
||||
|
||||
|
@ -1290,6 +1293,7 @@ void AudioClient::checkDevices() {
|
|||
|
||||
emit deviceChanged();
|
||||
}
|
||||
# endif
|
||||
}
|
||||
|
||||
void AudioClient::loadSettings() {
|
||||
|
|
Loading…
Reference in a new issue