Search Issue Tracker
By Design
Votes
0
Found in
2020.3.41f1
2021.3.12f1
2022.1.20f1
2022.2.0b12
2023.1.0a15
Issue ID
UUM-17382
Regression
No
[Mobile] Audio volume isn't adjusted when using AudioMixer.SetFloat method
Reproduction steps:
1. Open the attached “IN-20106.zip“ project
2. Build and Run for Android
3. Adjust the top “Music Volume“ slider to the left side
Expected result: Music volume is lowered
Actual result: Music volume isn’t changing
Reproducible with: 2020.3.41f1, 2021.3.12f1, 2022.1.20f1, 2022.2.0b12, 2023.1.0a15
Reproducible with these devices:
Huawei - (ELS-NX9), Android 10, CPU: HiSilicon Kirin 990 5G, GPU: Mali-G76
Samsung Galaxy Z Flip3 5G (SM-F711B), Android 12, CPU: Snapdragon 888, GPU: Adreno (TM) 660
Samsung Galaxy S22 (SM-S901B), Android 12, CPU: Exynos 2200, GPU: Ltd.
VLNQA00494 - iPhone 14 Pro Max, 16.0 iOS
VLNQA00358 - iPhone 12, 14.1 iOS
VLNQA00392 - iPad (9th generation), 15.0 iOS
VLNQA00310 - iPad Pro 12.9", 13.4.1 iOS
Not reproducible with: Windows Standalone Player (Mono and IL2CPP)
Tested with: Windows 10
Comments (1)
-
Vintecus
May 19, 2023 16:30
Seems to still be an ongoing issue as my audioMixer works in editor as well but not on android build. The work around I used was to link my sliders to the audiosources individually on my audiomanager class. The on value changed of the slider would update the audiosource volume sliders. Hope this helps
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Unity CIL Linker fails on Player build when persistent listeners have "<" and ">" in their XML attribute names
- ”Lighting data asset ‘LightingData’ is incompatible with the current Unity version…” warnings are thrown when saving Indoors (URP) and Outdoors (URP) Scenes as Scene Templates
- [iOS] The screen blinks when transitioning from custom to Unity splash screen
- [macOS] ”Ignoring depth surface load action as it is memoryless” warnings are thrown when taking Game View Snapshot
- UI Builder Inspector scrolls back up when changes on an expanded but not fully displayed Inspector tab are saved
Resolution Note:
AudioMixer.SetFloat does appear to be working as expected.
In the repro project, the problem is with the volume calculation in AudioManager.SetMusicVolume. The musicSlider is returning a negative value and then the log of that negative value is being taken, which is undefined. I think the confusion is that the results in the Editor are different than on Android, but I think this makes some sense because we are in undefined territory.