| Index: media/audio/audio_output_resampler.h
|
| diff --git a/media/audio/audio_output_resampler.h b/media/audio/audio_output_resampler.h
|
| index 7f5ea212bf9b7a2af56c8ede3c4912a598aa368a..cd2f1ddffcbbdca2c7396c93a099cf0d32514678 100644
|
| --- a/media/audio/audio_output_resampler.h
|
| +++ b/media/audio/audio_output_resampler.h
|
| @@ -32,6 +32,14 @@ class MultiChannelResampler;
|
| // and redirecting to the appropriate resampling or FIFO callback which passes
|
| // through to the original callback only when necessary.
|
| //
|
| +// AOR will automatically fall back from AUDIO_PCM_LOW_LATENCY to
|
| +// AUDIO_PCM_LINEAR if the output device fails to open at the requested output
|
| +// parameters.
|
| +// TODO(dalecurtis): Ideally the low latency path will be as reliable as the
|
| +// high latency path once we have channel mixing and support querying for the
|
| +// hardware's configured bit depth. Monitor the UMA stats for fallback and
|
| +// remove fallback support once it's stable. http://crbug.com/148418
|
| +//
|
| // Currently channel downmixing and upmixing is not supported.
|
| // TODO(dalecurtis): Add channel remixing. http://crbug.com/138762
|
| class MEDIA_EXPORT AudioOutputResampler
|
| @@ -66,6 +74,9 @@ class MEDIA_EXPORT AudioOutputResampler
|
| friend class base::RefCountedThreadSafe<AudioOutputResampler>;
|
| virtual ~AudioOutputResampler();
|
|
|
| + // Used to initialize the FIFO and resamplers.
|
| + void Initialize();
|
| +
|
| // Called by MultiChannelResampler when more data is necessary.
|
| void ProvideInput(AudioBus* audio_bus);
|
|
|
| @@ -98,9 +109,8 @@ class MEDIA_EXPORT AudioOutputResampler
|
| // regard to buffering and resampling.
|
| double io_ratio_;
|
|
|
| - // Helper values for determining playback delay adjustment.
|
| - int input_bytes_per_frame_;
|
| - int output_bytes_per_frame_;
|
| + // Used by AudioOutputDispatcherImpl; kept so we can reinitialize on the fly.
|
| + base::TimeDelta close_delay_;
|
|
|
| // Last AudioBuffersState object received via OnMoreData(), used to correct
|
| // playback delay by ProvideInput() and passed on to |source_callback_|.
|
| @@ -110,6 +120,9 @@ class MEDIA_EXPORT AudioOutputResampler
|
| // or FIFO buffers which have not been sent to the audio device.
|
| int outstanding_audio_bytes_;
|
|
|
| + // AudioParameters used to setup the output stream.
|
| + AudioParameters output_params_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(AudioOutputResampler);
|
| };
|
|
|
|
|