leremjs
leremjs

Reputation: 1069

Audio Graph render callback stops being called after audio session interruption

I am using Audio Unit Processing Graph Services on iOS to create a small graph of audio units to output audio. I set a render callback, and feed audio data into the graph when the callback is called.

This works fine until my audio session is interrupted (e.g by a phone call or alarm); at that point the callback stops, and never is called again, even after the interruption finishes.

I tried calling AUGraphStart() again on the graph, but that doesn't seem to help. Any ideas?

Upvotes: 4

Views: 990

Answers (1)

leremjs
leremjs

Reputation: 1069

It turns out that you need to explicitly stop the graph with AUGraphStop() in the interruption callback; otherwise the call to AUGraphStart() will not have any effect.

Upvotes: 6

Related Questions