| Index: webrtc/modules/audio_device/ios/voice_processing_audio_unit.h
|
| diff --git a/webrtc/modules/audio_device/ios/voice_processing_audio_unit.h b/webrtc/modules/audio_device/ios/voice_processing_audio_unit.h
|
| index 2f881e77fcdcbb963a95e0a75846cd8bc807090b..73f1f71b5ffb487a32b4d152f15fbc4826f73016 100644
|
| --- a/webrtc/modules/audio_device/ios/voice_processing_audio_unit.h
|
| +++ b/webrtc/modules/audio_device/ios/voice_processing_audio_unit.h
|
| @@ -33,6 +33,9 @@ class VoiceProcessingAudioUnitObserver {
|
| UInt32 num_frames,
|
| AudioBufferList* io_data) = 0;
|
|
|
| + // Callback function called when the sample rate changes.
|
| + virtual void OnSampleRateChange(float sample_rate) = 0;
|
| +
|
| protected:
|
| ~VoiceProcessingAudioUnitObserver() {}
|
| };
|
| @@ -107,6 +110,11 @@ class VoiceProcessingAudioUnit {
|
| UInt32 bus_number,
|
| UInt32 num_frames,
|
| AudioBufferList* io_data);
|
| + static void OnSampleRateChange(void* in_ref_con,
|
| + AudioUnit audio_unit,
|
| + AudioUnitPropertyID property_id,
|
| + AudioUnitScope scope,
|
| + AudioUnitElement element);
|
|
|
| // Notifies observer that samples are needed for playback.
|
| OSStatus NotifyGetPlayoutData(AudioUnitRenderActionFlags* flags,
|
| @@ -120,6 +128,11 @@ class VoiceProcessingAudioUnit {
|
| UInt32 bus_number,
|
| UInt32 num_frames,
|
| AudioBufferList* io_data);
|
| + // Notifies observer that sample rate has changed.
|
| + void NotifySampleRateChange(AudioUnit audio_unit,
|
| + AudioUnitPropertyID property_id,
|
| + AudioUnitScope scope,
|
| + AudioUnitElement element);
|
|
|
| // Returns the predetermined format with a specific sample rate. See
|
| // implementation file for details on format.
|
|
|