• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: iPhone interruption with OpenAL?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: iPhone interruption with OpenAL?


  • Subject: Re: iPhone interruption with OpenAL?
  • From: "E. Wing" <email@hidden>
  • Date: Mon, 11 Jan 2010 14:04:19 -0800

The quick answer is no. Assuming iPhone OS 3.0+, you must
suspend/disable the OpenAL context by making the current context NULL.
And if you have an iPod Touch, you can use the Clock.app's alarm
feature to help test interruptions.

FYI, I cover iPhone audio and OpenAL in excruciating detail
(attempting to be the authoritative OpenAL ref) in the book I am
co-authoring:
Beginning iPhone Games Development
http://tinyurl.com/beginningiphonegamesdev
(Hope to be finished and shipping very soon now.)

As to not stray too far from the topic of Cocoa, I also have a simple
example with the book that demonstrates how to use NSInvocation to
queue messages sent to play sounds in OpenAL while the interruption is
in progress with the intent to play them when the interruption ends.

Thanks,
Eric



On 1/10/10, Hank Heijink (Mailinglists) <email@hidden> wrote:
> Check the docs:
>
> http://developer.apple.com/iphone/library/documentation/Audio/Conceptual/AudioSessionProgrammingGuide/HandlingAudioInterruptions/HandlingAudioInterruptions.html
>
> There's a section called "OpenAL and Audio Interruptions" that explains it.
>
> Good luck,
> Hank
>
> On Jan 10, 2010, at 4:23 AM, Chunk 1978 wrote:
>
>> i'm using an interruption listener callback with audiotoolbox to shut
>> off music when a call (or something else) comes in to interrupt the
>> app.  however, i'd simply like to remove all AVFoundation from the
>> code and strictly rely on OpenAL for sound.  will OpenAL automatically
>> pause like the rest of the app when a call comes in?  the reason i'm
>> asking this simple question is because i don't have an iPhone for
>> testing.
>> _______________________________________________
>>
>> Cocoa-dev mailing list (email@hidden)
>>
>> Please do not post admin requests or moderator comments to the list.
>> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>>
>> Help/Unsubscribe/Update your Subscription:
>>
>> This email sent to email@hidden
>>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >iPhone interruption with OpenAL? (From: Chunk 1978 <email@hidden>)
 >Re: iPhone interruption with OpenAL? (From: "Hank Heijink (Mailinglists)" <email@hidden>)

  • Prev by Date: Re: iPhone: CGPathMutable updating?
  • Next by Date: Re: iPhone endInterruption delegate method killing OpenAL
  • Previous by thread: Re: iPhone interruption with OpenAL?
  • Next by thread: [MEET] CocoaHeads-NYC this Thursday, 11/12
  • Index(es):
    • Date
    • Thread