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

Unified Diff: media/blink/multibuffer_data_source.cc

Issue 2689323002: Media: Delete Pause-To-Buffer. (Closed)
Patch Set: Rebase. Created 3 years, 9 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/blink/multibuffer_data_source.h ('k') | media/blink/multibuffer_data_source_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/multibuffer_data_source.cc
diff --git a/media/blink/multibuffer_data_source.cc b/media/blink/multibuffer_data_source.cc
index 91d61231eb86a3f643c1e0b048c8ba38b156a861..c882fae9e32c6075f55ec8188086a1398b34377f 100644
--- a/media/blink/multibuffer_data_source.cc
+++ b/media/blink/multibuffer_data_source.cc
@@ -122,7 +122,6 @@ MultibufferDataSource::MultibufferDataSource(
frame_(frame),
stop_signal_received_(false),
media_has_played_(false),
- buffering_strategy_(BUFFERING_STRATEGY_NORMAL),
single_origin_(true),
cancel_on_defer_(false),
preload_(AUTO),
@@ -249,13 +248,6 @@ void MultibufferDataSource::SetPreload(Preload preload) {
UpdateBufferSizes();
}
-void MultibufferDataSource::SetBufferingStrategy(
- BufferingStrategy buffering_strategy) {
- DCHECK(render_task_runner_->BelongsToCurrentThread());
- buffering_strategy_ = buffering_strategy;
- UpdateBufferSizes();
-}
-
bool MultibufferDataSource::HasSingleOrigin() {
DCHECK(render_task_runner_->BelongsToCurrentThread());
// Before initialization completes there is no risk of leaking data. Callers
@@ -580,18 +572,6 @@ void MultibufferDataSource::UpdateBufferSizes() {
if (!reader_)
return;
- if (!assume_fully_buffered()) {
- // If the playback has started and the strategy is aggressive, then try to
- // load as much as possible, assuming that the file is cacheable. (If not,
- // why bother?)
- bool aggressive = (buffering_strategy_ == BUFFERING_STRATEGY_AGGRESSIVE);
- if (media_has_played_ && aggressive && url_data_ &&
- url_data_->range_supported() && url_data_->cacheable()) {
- reader_->SetPreload(1LL << 40, 1LL << 40); // 1 Tb
- return;
- }
- }
-
// Use a default bit rate if unknown and clamp to prevent overflow.
int64_t bitrate = clamp<int64_t>(bitrate_, 0, kMaxBitrate);
if (bitrate == 0)
« no previous file with comments | « media/blink/multibuffer_data_source.h ('k') | media/blink/multibuffer_data_source_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698