Search Issue Tracker
Fixed in 5.5.0
Votes
65
Found in
5.3.6p4
Issue ID
828762
Regression
Yes
[iOS] Sound volume of music playing on the device gets quiet after launching a Unity app
When a Unity app is launched, any audio playing on the device (iTunes, Spotify, etc.) gets quiet, even when the app is not playing any sounds. This issue does not occur when 'Disable Unity Audio' is checked in Edit > Project Settings > Audio. When the app goes back to background or is exited, the sound goes back to normal.
Steps to reproduce:
1) Create a new project.
2) Build for iOS.
3) Play music on a device.
4) Launch the build on the device.
As soon as the app starts, the sound volume is halved.
Reproduced on:
5.5.0b2, 5.4.0p4, 5.3.6p4
Did not reproduce:
5.2.4f1
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
- "Unsupported texture format R16 for a swizzle" error and texture is not correctly rendered when using texture Swizzle and reimporting texture asset
- Tab order is incorrect after re-ordering
- [Ubuntu] Red squares instead of ticks in dropdown options
- Multiple simultaneous input with the touch screen sometimes leaves button in not default state
- Crash on ShowDelayedContextMenu(bool) when changing the Size options of a Visual Element in the UIToolkit Inspector
TimberX
Nov 10, 2016 20:02
Hi @lanestp ,
Thanks for the plugin code, and it works on my iPhone6 on iOS 10.0.2, I also got the error the same with @ALECT when it runs on some other devices. But thanks for the code!
Morgan
Nov 08, 2016 18:18
Thanks again, Lanestp! I'll give it a day or two more in hopes of an official fix, and then I'll give that a try!
alect
Nov 07, 2016 18:46
@lanestp your code workaround seems to work great on my iPhone 5S running 10.0.1, but on my iPad Mini 2 running 9.3.2 I get the following error and no audio plays at all (this error does not appear and audio works fine without the AudioFix plugin):
ERROR: [0x19faba000] AVAudioSessionUtilities.h:111: GetProperty: AudioSessionGetProperty ('aiav') failed with error: '!ini'
ERROR: [0x19faba000] AVAudioSessionUtilities.h:124: GetProperty_DefaultToZero: AudioSessionGetProperty ('aiav') failed with error: '!ini'
FMOD failed to initialize the output device, attempting to initialize the null output.
I'm not super familiar with what your code is doing, so I was wondering if you have any insights about how to fix that? Thanks either way!
lanestp
Nov 04, 2016 02:42
Morgan - inside your project directory inside assets Create a Plugins directory and inside that creat an iOS directory
http://wiki.unity3d.com/index.php/Special_Folder_Names_in_your_Assets_Folder
Morgan
Nov 03, 2016 14:53
p2 and p3 have been released, still with no fix apparently. Any further details on a workaround would be great!
Morgan
Oct 24, 2016 16:33
Patch 5.4.2p1 is out but no mention of this being fixed :( It's over a year since I've been able to ship an update to my app due to one shipstopper bug overlapping another :(
Morgan
Oct 21, 2016 21:35
Thanks, LaneSTP! What's the path to Plugins/iOS? Maybe I need to create it? (There's no Plugins folder in either the Unity project or the Xcode project.)
Any need to then call/reference/select the created file? Or is its existence enough?
lanestp
Oct 21, 2016 02:15
For everyone trying to fix this issue just create a AudioFix.mm file in Plugins/iOS/ and copy paste the code in there
lEscargotl
Oct 12, 2016 22:42
@lanestp I guess you need to buy the UIKit plugin ($25) for that fix?
lEscargotl
Oct 12, 2016 22:14
@lanestp Can you explain what "Just include this code in your plugin." means? If I copy-paste that code, where should it go?