|
This looks like standard iOS behaviour, but is very annoying in my use case. I have multiple iPad's synched in a music app. If I plug or unplug headphones on a device, it will fall out of sync, as if the app was briefly paused... Any way I could get around that? Thanks for your help!
(comments are locked)
|
|
Seeing as this is most likely an iOS issue, I would include a work around in your app. For example, if the user(s) notice a problem with audio being out of sync, provide a button that they can press that will send out an RPC call to all connected devices that pauses it, then restarts it all together on the right track. Another possibility (and a less intrusive one to the UI) is see if you can find a way to detect the issue when it occurs and have the program resolve it on its own. If all else fails, you'll probably have to head over to Apple's developer site and submit a bug report. In the end, it may not get fix but it might get some notice to it. EDIT: This is not a bug so much as a result of Apple's software at work. It pauses it completely briefly. [See this thread.][1] [1]: https://discussions.apple.com/thread/3287523?start=0&tstart=0 It is unlikely that it will be fixed. Thanks for your input. As the app is meant for a musical performance, I can't pause every connected device and restart... What I need is an event like OnMiniJackConnect(). Does it even exist? If not, my hacky idea is to have a silent click looping in the background, and to check every few frames if it has fallen out of sync against realTimeSinceStartup... Not very elegant.
Jul 04 '12 at 04:48 AM
gregzo
You can have a look at the reference manual under Unity3D's document section of the site (link below) if there is any component that exists within Unity related to that, it will be shown and explained there. Otherwise I'm not sure what to do.
Jul 04 '12 at 05:53 PM
Morley Insane
After a quick Google, it appears that this is a known "occurrence" (I avoid the word "issue" because it isn't technically a bug, just a result of software working the way it should. See link below.) https://discussions.apple.com/thread/3287523?start=0&tstart=0 Make sure you don't run the check every frame or even every few frames. I would think every 10-20 frames would be appropriate, as queries could take a while and, unless a separate thread was created for this function, it could cause ever-so-slightly noticeable delays.
Jul 04 '12 at 06:01 PM
Morley Insane
Thanks a lot, thumbs up for your efforts. But... Had seen the discussion you link to. It mentions a delay, which is not a precise description of what is happening: if the OS simply waited a bit before it routed the audio to the minijack, I wouldn't be experiencing the out of sync issue. The audio is actualy paused during the delay, which is the true bummer to me. Example : two devices running a metronome at 60 bpm in sync, plug and unplug headphones: sync destroyed... Will implement the check, every half second should do.
Jul 04 '12 at 07:32 PM
gregzo
Sorry about the inaccuracies. I see now more fully, thanks. Hope your implementation works out. Might want to post a message somewhere in-app notifying user as well. Hope this helped.
Jul 05 '12 at 12:12 AM
Morley Insane
(comments are locked)
|

Nobody on this? Am I the only one to get annoyed by this issue? Help, compassion, mockery, anything!