mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
Prettified Code!
This commit is contained in:
parent
2f468d21c7
commit
e7ebff3f11
1 changed files with 10 additions and 2 deletions
|
@ -1940,7 +1940,11 @@ ipcRenderer.on("action-update-tnc-state", (event, arg) => {
|
|||
}
|
||||
// dbfs
|
||||
// https://www.moellerstudios.org/converting-amplitude-representations/
|
||||
if (arg.dbfs_level.length != 0 && !isNaN(arg.dbfs_level) && dbfs_level_raw != arg.dbfs_level) {
|
||||
if (
|
||||
arg.dbfs_level.length != 0 &&
|
||||
!isNaN(arg.dbfs_level) &&
|
||||
dbfs_level_raw != arg.dbfs_level
|
||||
) {
|
||||
dbfs_level_raw = arg.dbfs_level;
|
||||
dbfs_level = Math.pow(10, arg.dbfs_level / 20) * 100;
|
||||
|
||||
|
@ -1955,7 +1959,11 @@ ipcRenderer.on("action-update-tnc-state", (event, arg) => {
|
|||
// noise / strength
|
||||
// https://www.moellerstudios.org/converting-amplitude-representations/
|
||||
|
||||
if (arg.strength.length != 0 && !isNaN(arg.strength) && noise_level_raw != arg.strength) {
|
||||
if (
|
||||
arg.strength.length != 0 &&
|
||||
!isNaN(arg.strength) &&
|
||||
noise_level_raw != arg.strength
|
||||
) {
|
||||
//console.log(arg.strength);
|
||||
noise_level_raw = arg.strength;
|
||||
noise_level = Math.pow(10, arg.strength / 20) * 100;
|
||||
|
|
Loading…
Reference in a new issue