aboutsummaryrefslogtreecommitdiffstats
path: root/utils/alsoft-config
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2017-04-26 19:27:50 -0700
committerChris Robinson <[email protected]>2017-04-26 19:27:50 -0700
commit8f56c9522e65405d591ee2eacdcbf9e29caab9fe (patch)
tree8a9683a9f43d5d7504db22b1dacc89bd2c3c3d5a /utils/alsoft-config
parentca5c732261bfacdb4702fcc253b3ef0dad357a35 (diff)
Document the output-limiter config option
Expose it in alsoft-config as well.
Diffstat (limited to 'utils/alsoft-config')
-rw-r--r--utils/alsoft-config/mainwindow.cpp16
-rw-r--r--utils/alsoft-config/mainwindow.ui29
2 files changed, 41 insertions, 4 deletions
diff --git a/utils/alsoft-config/mainwindow.cpp b/utils/alsoft-config/mainwindow.cpp
index 26d05f8f..d46bb029 100644
--- a/utils/alsoft-config/mainwindow.cpp
+++ b/utils/alsoft-config/mainwindow.cpp
@@ -328,6 +328,7 @@ MainWindow::MainWindow(QWidget *parent) :
connect(ui->stereoEncodingComboBox, SIGNAL(currentIndexChanged(QString)), this, SLOT(enableApplyButton()));
connect(ui->ambiFormatComboBox, SIGNAL(currentIndexChanged(QString)), this, SLOT(enableApplyButton()));
+ connect(ui->outputLimiterCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton()));
connect(ui->decoderHQModeCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton()));
connect(ui->decoderDistCompCheckBox, SIGNAL(stateChanged(int)), this, SLOT(enableApplyButton()));
@@ -641,6 +642,13 @@ void MainWindow::loadConfig(const QString &fname)
updatePeriodCountSlider();
}
+ if(settings.value("output-limiter").isNull())
+ ui->outputLimiterCheckBox->setCheckState(Qt::PartiallyChecked);
+ else
+ ui->outputLimiterCheckBox->setCheckState(
+ settings.value("output-limiter").toBool() ? Qt::Checked : Qt::Unchecked
+ );
+
QString stereopan = settings.value("stereo-encoding").toString();
ui->stereoEncodingComboBox->setCurrentIndex(0);
if(stereopan.isEmpty() == false)
@@ -896,6 +904,14 @@ void MainWindow::saveConfig(const QString &fname) const
settings.setValue("stereo-encoding", getValueFromName(stereoEncList, ui->stereoEncodingComboBox->currentText()));
settings.setValue("ambi-format", getValueFromName(ambiFormatList, ui->ambiFormatComboBox->currentText()));
+ Qt::CheckState limiter = ui->outputLimiterCheckBox->checkState();
+ if(limiter == Qt::PartiallyChecked)
+ settings.setValue("output-limiter", QString());
+ else if(limiter == Qt::Checked)
+ settings.setValue("output-limiter", QString("true"));
+ else if(limiter == Qt::Unchecked)
+ settings.setValue("output-limiter", QString("false"));
+
settings.setValue("decoder/hq-mode",
ui->decoderHQModeCheckBox->isChecked() ? QString("true") : QString(/*"false"*/)
);
diff --git a/utils/alsoft-config/mainwindow.ui b/utils/alsoft-config/mainwindow.ui
index a527cfd5..153bcc04 100644
--- a/utils/alsoft-config/mainwindow.ui
+++ b/utils/alsoft-config/mainwindow.ui
@@ -129,7 +129,7 @@ to stereo output.</string>
<x>380</x>
<y>20</y>
<width>91</width>
- <height>21</height>
+ <height>29</height>
</rect>
</property>
<property name="toolTip">
@@ -236,9 +236,9 @@ otherwise be suitable for speakers.</string>
<property name="geometry">
<rect>
<x>-11</x>
- <y>200</y>
+ <y>180</y>
<width>551</width>
- <height>181</height>
+ <height>201</height>
</rect>
</property>
<property name="title">
@@ -483,6 +483,27 @@ receiver.</string>
</rect>
</property>
</widget>
+ <widget class="QCheckBox" name="outputLimiterCheckBox">
+ <property name="geometry">
+ <rect>
+ <x>30</x>
+ <y>160</y>
+ <width>231</width>
+ <height>20</height>
+ </rect>
+ </property>
+ <property name="toolTip">
+ <string>Applies a gain limiter on the final mixed output. This reduces the
+volume when the output samples would otherwise be clamped,
+avoiding excessive clipping noise.</string>
+ </property>
+ <property name="text">
+ <string>Enable Gain Limiter</string>
+ </property>
+ <property name="tristate">
+ <bool>true</bool>
+ </property>
+ </widget>
</widget>
<widget class="QGroupBox" name="groupBox_4">
<property name="geometry">
@@ -2107,7 +2128,7 @@ added by the ALC_EXT_DEDICATED extension.</string>
<x>160</x>
<y>20</y>
<width>123</width>
- <height>21</height>
+ <height>29</height>
</rect>
</property>
<property name="sizeAdjustPolicy">