开发者

iOS Background Audio Icon

I've followed the API Docs and WWDC Videos exactly, to play audio in the background via an Audio开发者_开发知识库 Session (using the AudioQueue services). It all works just fine, but there is no "Play" indicator displayed in the Status Bar.

Do i have to set this separately or is it a Bug?


I think this was done by the Audio Session:

// before instantiating the playback audio queue object, 
//  set the audio session category
UInt32 sessionCategory = kAudioSessionCategory_MediaPlayback;
AudioSessionSetProperty (
                         kAudioSessionProperty_AudioCategory,
                         sizeof (sessionCategory),
                         &sessionCategory
                         );

// activate the audio session immmediately before playback starts
AudioSessionSetActive (true);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜