Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(956)

Unified Diff: media/renderers/audio_renderer_impl.cc

Issue 2858393002: media: Increase the default audio buffer size for encrypted streams (Closed)
Patch Set: Fix another chromecast usage of AudioRendererAlgorithm Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/renderers/audio_renderer_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/renderers/audio_renderer_impl.cc
diff --git a/media/renderers/audio_renderer_impl.cc b/media/renderers/audio_renderer_impl.cc
index 25f4ef34d83c294bfddd2ee7543e81672291036f..bc06582e02e1d32d06947ea1273ba275c2920fb8 100644
--- a/media/renderers/audio_renderer_impl.cc
+++ b/media/renderers/audio_renderer_impl.cc
@@ -47,6 +47,7 @@ AudioRendererImpl::AudioRendererImpl(
last_audio_memory_usage_(0),
last_decoded_sample_rate_(0),
last_decoded_channel_layout_(CHANNEL_LAYOUT_NONE),
+ is_encrypted_(false),
playback_rate_(0.0),
state_(kUninitialized),
create_audio_decoders_cb_(create_audio_decoders_cb),
@@ -454,6 +455,8 @@ void AudioRendererImpl::Initialize(DemuxerStream* stream,
last_decoded_channel_layout_ =
stream->audio_decoder_config().channel_layout();
+ is_encrypted_ = stream->audio_decoder_config().is_encrypted();
+
audio_clock_.reset(
new AudioClock(base::TimeDelta(), audio_parameters_.sample_rate()));
@@ -492,7 +495,7 @@ void AudioRendererImpl::OnAudioBufferStreamInitialized(bool success) {
// We're all good! Continue initializing the rest of the audio renderer
// based on the decoder format.
algorithm_.reset(new AudioRendererAlgorithm());
- algorithm_->Initialize(audio_parameters_);
+ algorithm_->Initialize(audio_parameters_, is_encrypted_);
ConfigureChannelMask();
ChangeState_Locked(kFlushed);
« no previous file with comments | « media/renderers/audio_renderer_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698