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

Unified Diff: media/filters/file_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/ffmpeg_demuxer_unittest.cc ('k') | media/filters/file_data_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/file_data_source.h
===================================================================
--- media/filters/file_data_source.h (revision 105891)
+++ media/filters/file_data_source.h (working copy)
@@ -18,6 +18,7 @@
class MEDIA_EXPORT FileDataSource : public DataSource {
public:
FileDataSource();
+ FileDataSource(bool disable_file_size);
virtual ~FileDataSource();
PipelineStatus Initialize(const std::string& url);
@@ -32,6 +33,7 @@
virtual bool GetSize(int64* size_out);
virtual bool IsStreaming();
virtual void SetPreload(Preload preload);
+ virtual void SetBitrate(int bitrate);
private:
// Only allow factories and tests to create this object.
@@ -42,12 +44,19 @@
FRIEND_TEST_ALL_PREFIXES(FileDataSourceTest, ReadData);
FRIEND_TEST_ALL_PREFIXES(FileDataSourceTest, Seek);
+ // Informs the host of changes in total and buffered bytes.
+ void UpdateHostBytes();
+
// File handle. NULL if not initialized or an error occurs.
FILE* file_;
// Size of the file in bytes.
int64 file_size_;
+ // True if the FileDataSource should ignore its set file size, false
+ // otherwise.
+ bool disable_file_size_;
+
// Critical section that protects all of the DataSource methods to prevent
// a Stop from happening while in the middle of a file I/O operation.
// TODO(ralphl): Ideally this would use asynchronous I/O or we will know
« no previous file with comments | « media/filters/ffmpeg_demuxer_unittest.cc ('k') | media/filters/file_data_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698