OALAudioSession Class Reference
| Inherits from | NSObject |
|---|---|
| Conforms to | AVAudioSessionDelegate OALSuspendManager |
| Declared in | OALAudioSession.h |
audioSessionCategory
The current audio session category. If this value is explicitly set, the other session properties “allowIpod”, “useHardwareIfAvailable”, “honorSilentSwitch”, and “ipodDucking” may be modified to remain compatible with the category.
@property (nonatomic, readwrite, retain) NSString *audioSessionCategoryDeclared In
OALAudioSession.h
allowIpod
If YES, allow ipod music to continue playing (NOT SUPPORTED ON THE SIMULATOR).
Note: If this is enabled, and another app is playing music, background audio
playback will use the SOFTWARE codecs, NOT hardware.
@property (nonatomic, readwrite, assign) bool allowIpodDiscussion
If allowIpod = NO, the application will ALWAYS use hardware decoding.
See Also
@property useHardwareIfAvailable
Default value: YES
Declared In
OALAudioSession.h
ipodDucking
If YES, ipod music will duck (lower in volume) when the audio session activates.
@property (nonatomic, readwrite, assign) bool ipodDuckingDiscussion
Default value: NO
Declared In
OALAudioSession.h
useHardwareIfAvailable
Determines what to do if no other application is playing audio and allowIpod = YES
(NOT SUPPORTED ON THE SIMULATOR).
@property (nonatomic, readwrite, assign) bool useHardwareIfAvailableDiscussion
If NO, the application will ALWAYS use software decoding. The advantage to this is that
the user can background your application and then start audio playing from another
application. If useHardwareIfAvailable = YES, the user won’t be able to do this.
If this is set to YES, the application will use hardware decoding if no other application
is currently playing audio. However, no other application will be able to start playing
audio if it wasn’t playing already.
Note: This switch has no effect if allowIpod = NO.
See Also
Default value: YES
Declared In
OALAudioSession.h
honorSilentSwitch
If true, mute when backgrounded, screen locked, or the ringer switch is
turned off (NOT SUPPORTED ON THE SIMULATOR).
@property (nonatomic, readwrite, assign) bool honorSilentSwitchDiscussion
Default value: YES
Declared In
OALAudioSession.h
handleInterruptions
If true, automatically handle interruptions.
@property (nonatomic, readwrite, assign) bool handleInterruptionsDiscussion
Default value: YES
Declared In
OALAudioSession.h
audioSessionDelegate
Delegate that will receive all audio session events (WEAK reference).
@property (nonatomic, readwrite, assign) id<AVAudioSessionDelegate> audioSessionDelegateDeclared In
OALAudioSession.h
audioSessionActive
If true, the audio session is active
@property (nonatomic, readwrite, assign) bool audioSessionActiveDeclared In
OALAudioSession.h
)
The preferred I/O buffer duration, in seconds. Lower values give less playback latencey, but use more CPU. (Deprecated: Use AVAudioSession instead.)
@property (nonatomic, readwrite, assign) float preferredIOBufferDuration __OSX_AVAILABLE_BUT_DEPRECATED ( __MAC_NA , __MAC_NA , __IPHONE_2_0 , __IPHONE_6_1 )Declared In
OALAudioSession.h
– forceEndInterruption
Force an interrupt end. This can be useful in cases where a buggy OS fails to end an interrupt.
- (void)forceEndInterruptionDiscussion
Be VERY CAREFUL when using this!
Declared In
OALAudioSession.h