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

Unified Diff: webkit/glue/media/buffered_data_source.h

Issue 8294025: Merge 105121 - Numerous fixes to audio/video buffered resource loading. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/874/src/
Patch Set: '' Created 9 years, 2 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/filters/file_data_source.cc ('k') | webkit/glue/media/buffered_data_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/media/buffered_data_source.h
===================================================================
--- webkit/glue/media/buffered_data_source.h (revision 105891)
+++ webkit/glue/media/buffered_data_source.h (working copy)
@@ -50,6 +50,7 @@
virtual bool GetSize(int64* size_out);
virtual bool IsStreaming();
virtual void SetPreload(media::Preload preload);
+ virtual void SetBitrate(int bitrate);
// webkit_glue::WebDataSource implementation.
virtual void Initialize(const std::string& url,
@@ -66,6 +67,8 @@
int64 first_byte_position, int64 last_byte_position);
private:
+ friend class BufferedDataSourceTest2;
+
// Posted to perform initialization on render thread and start resource
// loading.
void InitializeTask();
@@ -89,6 +92,9 @@
// This task saves the preload value for the media.
void SetPreloadTask(media::Preload preload);
+ // Tells |loader_| the bitrate of the media.
+ void SetBitrateTask(int bitrate);
+
// Decides which DeferStrategy to used based on the current state of the
// BufferedDataSource.
BufferedResourceLoader::DeferStrategy ChooseDeferStrategy();
@@ -211,6 +217,12 @@
// Number of cache miss retries left.
int cache_miss_retries_left_;
+ // Bitrate of the content, 0 if unknown.
+ int bitrate_;
+
+ // Current playback rate.
+ float playback_rate_;
+
scoped_refptr<media::MediaLog> media_log_;
DISALLOW_COPY_AND_ASSIGN(BufferedDataSource);
« no previous file with comments | « media/filters/file_data_source.cc ('k') | webkit/glue/media/buffered_data_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698