| Index: media/audio/audio_output_controller.h
|
| diff --git a/media/audio/audio_output_controller.h b/media/audio/audio_output_controller.h
|
| index 3dae719856508cd6a25e28dc22cd84305a35dd58..73fb014ecc09d700a8dbd94b4a241adb16533480 100644
|
| --- a/media/audio/audio_output_controller.h
|
| +++ b/media/audio/audio_output_controller.h
|
| @@ -158,6 +158,21 @@ class MEDIA_EXPORT AudioOutputController
|
| // to being called.
|
| virtual void OnDeviceChange() OVERRIDE;
|
|
|
| + // Accessor to audio output parameters.
|
| + const AudioParameters& params() const { return params_; }
|
| +
|
| + // Stops the normal audio output stream and creates an AudioSourceCallback to
|
| + // provide audio data to some other destination. The given object will always
|
| + // return data when OnMoreData() is invoked, even if the underlying
|
| + // implementation is paused/stopped. AudioOutputController retains ownership
|
| + // of the returned object.
|
| + AudioOutputStream::AudioSourceCallback* Divert();
|
| +
|
| + // Restores normal audio output behavior for the current playback state.
|
| + // |asc| is the pointer returned by the previous call to Divert() and becomes
|
| + // invalid once this method is called.
|
| + void Revert(AudioOutputStream::AudioSourceCallback* asc);
|
| +
|
| protected:
|
| // Internal state of the source.
|
| enum State {
|
| @@ -228,7 +243,7 @@ class MEDIA_EXPORT AudioOutputController
|
| // Number of times left.
|
| int number_polling_attempts_left_;
|
|
|
| - AudioParameters params_;
|
| + const AudioParameters params_;
|
|
|
| // Used to post delayed tasks to ourselves that we can cancel.
|
| // We don't want the tasks to hold onto a reference as it will slow down
|
|
|