From 7df6b04b086a5cd81030b1203bcedc95a9cd6702 Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Thu, 29 Oct 2015 21:56:33 +0100 Subject: [PATCH] Set the peak meter to red when peaking. --- mainwindow.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/mainwindow.cpp b/mainwindow.cpp index 4dc0608..2888c83 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -100,6 +100,11 @@ void MainWindow::mixer_created(Mixer *mixer) char buf[256]; snprintf(buf, sizeof(buf), "%.1f", peak_db); ui->peak_display->setText(buf); + if (peak_db > -0.1f) { // -0.1 dBFS is EBU peak limit. + ui->peak_display->setStyleSheet("QLabel { background-color: red; color: white; }"); + } else { + ui->peak_display->setStyleSheet(""); + } }); } -- 2.39.5