Additional check on dbfs value before processing.

pyqt6
Mark Jessop 2021-03-10 18:11:48 +10:30
rodzic 24e2aaf194
commit fe4ff20813
3 zmienionych plików z 9 dodań i 5 usunięć

Wyświetl plik

@ -1 +1 @@
__version__ = "0.1.16"
__version__ = "0.1.17"

Wyświetl plik

@ -577,9 +577,6 @@ def handle_fft_update(data):
_tc = 0.1
_new_max = float((_old_max * (1 - _tc)) + (np.max(_data) * _tc))
# Use same IIR to smooth out dBFS readings a little.
_new_dbfs = float((widgets["audioDbfsValue_float"] * (1 - _tc)) + (_dbfs * _tc))
# Store new max
widgets["spectrumPlotRange"][1] = max(widgets["spectrumPlotRange"][0], _new_max)
@ -587,6 +584,13 @@ def handle_fft_update(data):
widgets["spectrumPlotRange"][0], widgets["spectrumPlotRange"][1] + 20
)
# Ignore NaN values.
if np.isnan(_dbfs):
return
# Use same IIR to smooth out dBFS readings a little.
_new_dbfs = float((widgets["audioDbfsValue_float"] * (1 - _tc)) + (_dbfs * _tc))
# Set dBFS value
if (_new_dbfs>-5.0):
_dbfs_ok = "TOO HIGH"

Wyświetl plik

@ -1,6 +1,6 @@
[tool.poetry]
name = "horusgui"
version = "0.1.16"
version = "0.1.17"
description = ""
authors = ["Mark Jessop <vk5qi@rfhead.net>"]