From 349187df4c74e1296b1a175142531054c993211d Mon Sep 17 00:00:00 2001 From: Nodeful Date: Mon, 12 Jul 2021 01:25:49 +0300 Subject: [PATCH] fix incorrect balance calculation on startup --- native/app/Source/Application.swift | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/native/app/Source/Application.swift b/native/app/Source/Application.swift index 9f00503..a4cc4e7 100644 --- a/native/app/Source/Application.swift +++ b/native/app/Source/Application.swift @@ -284,7 +284,13 @@ class Application { } if (selectedDevice!.outputBalanceSupported) { - balance = Double(selectedDevice!.virtualMasterBalance(direction: .playback)!) + balance = Utilities.mapValue( + value: Double(selectedDevice!.virtualMasterBalance(direction: .playback)!), + inMin: 0, + inMax: 1, + outMin: -1, + outMax: 1 + ) } Application.dispatchAction(VolumeAction.setBalance(balance, false))