From a12c420c591ef90dd50aabd435a9e995681232a2 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sat, 27 Feb 2016 19:18:57 -0800 Subject: Reorganize the Backends tab and add a PulseAudio section --- utils/alsoft-config/mainwindow.cpp | 26 +++- utils/alsoft-config/mainwindow.ui | 236 +++++++++++++++++++++++++++---------- 2 files changed, 199 insertions(+), 63 deletions(-) (limited to 'utils') diff --git a/utils/alsoft-config/mainwindow.cpp b/utils/alsoft-config/mainwindow.cpp index 63a29714..f1516e4b 100644 --- a/utils/alsoft-config/mainwindow.cpp +++ b/utils/alsoft-config/mainwindow.cpp @@ -306,6 +306,13 @@ MainWindow::MainWindow(QWidget *parent) : connect(ui->enableModulatorCheck, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton())); connect(ui->enableDedicatedCheck, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton())); + connect(ui->pulseAutospawnCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton())); + connect(ui->pulseAllowMovesCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton())); + connect(ui->pulseFixRateCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton())); + + ui->backendListWidget->setCurrentRow(0); + ui->tabWidget->setCurrentIndex(0); + loadConfig(getDefaultConfigName()); } @@ -631,6 +638,10 @@ void MainWindow::loadConfig(const QString &fname) ui->enableModulatorCheck->setChecked(!excludefx.contains("modulator", Qt::CaseInsensitive)); ui->enableDedicatedCheck->setChecked(!excludefx.contains("dedicated", Qt::CaseInsensitive)); + ui->pulseAutospawnCheckBox->setChecked(settings.value("pulse/spawn-server", true).toBool()); + ui->pulseAllowMovesCheckBox->setChecked(settings.value("pulse/allow-moves", false).toBool()); + ui->pulseFixRateCheckBox->setChecked(settings.value("pulse/fix-rate", false).toBool()); + ui->applyButton->setEnabled(false); ui->closeCancelButton->setText(tr("Close")); mNeedsSave = false; @@ -772,7 +783,7 @@ void MainWindow::saveConfig(const QString &fname) const if(ui->emulateEaxCheckBox->isChecked()) settings.setValue("reverb/emulate-eax", "true"); else - settings.setValue("reverb/emulate-eax", QString()/*"false"*/); + settings.remove("reverb/emulate-eax"/*, "false"*/); strlist.clear(); if(!ui->enableEaxReverbCheck->isChecked()) @@ -807,6 +818,19 @@ void MainWindow::saveConfig(const QString &fname) const if(str == QString()) settings.remove(key); } + + if(ui->pulseAutospawnCheckBox->isChecked()) + settings.remove("pulse/spawn-server"/*, "true"*/); + else + settings.setValue("pulse/spawn-server", "false"); + if(ui->pulseAllowMovesCheckBox->isChecked()) + settings.setValue("pulse/allow-moves", "true"); + else + settings.remove("pulse/allow-moves"/*, "false"*/); + if(ui->pulseFixRateCheckBox->isChecked()) + settings.setValue("pulse/fix-rate", "true"); + else + settings.remove("pulse/fix-rate"/*, "false"*/); } diff --git a/utils/alsoft-config/mainwindow.ui b/utils/alsoft-config/mainwindow.ui index a362d845..888546ce 100644 --- a/utils/alsoft-config/mainwindow.ui +++ b/utils/alsoft-config/mainwindow.ui @@ -712,80 +712,176 @@ application or system to determine if it should be used. Backends - + - 170 - 200 - 161 - 21 + 0 + 11 + 111 + 361 - - When checked, allows all other available backends not listed in the priority or disabled lists. - - - Allow Other Backends - - + true + + + General + + + + + PulseAudio + + - - - - 40 - 40 - 191 - 151 - - - - The backend driver list order. Unknown backends and -duplicated names are ignored. - - - QAbstractItemView::InternalMove - - - - - - 40 - 20 - 191 - 20 - - - - Priority Backends: - - - - - - 270 - 40 - 191 - 151 - - - - Disabled backend driver list. - - - + - 270 - 20 - 191 - 20 + 110 + 10 + 411 + 361 - - Disabled Backends: + + 0 + + + + + 20 + 190 + 391 + 21 + + + + When checked, allows all other available backends not listed in the priority or disabled lists. + + + Allow Other Backends + + + true + + + + + + 220 + 30 + 191 + 151 + + + + Disabled backend driver list. + + + + + + 20 + 30 + 191 + 151 + + + + The backend driver list order. Unknown backends and +duplicated names are ignored. + + + QAbstractItemView::InternalMove + + + + + + 230 + 10 + 171 + 20 + + + + Disabled Backends: + + + + + + 30 + 10 + 171 + 20 + + + + Priority Backends: + + + + + + + + 20 + 10 + 141 + 21 + + + + Automatically spawn a PulseAudio server if one +is not already running. + + + AutoSpawn Server + + + true + + + + + + 20 + 40 + 161 + 21 + + + + Allows moving PulseAudio streams to different +devices during playback or capture. Note that the +device specifier and device format will not change +to match the new device. + + + Allow Moving Streams + + + + + + 20 + 70 + 121 + 21 + + + + When checked, fix the OpenAL device's sample +rate to match the PulseAudio device. + + + Fix Sample Rate + + + @@ -1494,6 +1590,22 @@ added by the ALC_EXT_DEDICATED extension. + + backendListWidget + currentRowChanged(int) + backendStackedWidget + setCurrentIndex(int) + + + 69 + 233 + + + 329 + 232 + + + ShowHRTFContextMenu(QPoint) -- cgit v1.2.3