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

Unified Diff: media/filters/chunk_demuxer.h

Issue 10829108: Cap sourceBuffered() on duration and truncate duration on EoS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Updated test Created 8 years, 5 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
Index: media/filters/chunk_demuxer.h
diff --git a/media/filters/chunk_demuxer.h b/media/filters/chunk_demuxer.h
index fb53bca5596dc83392bb362a440151f4376f21be..26741acc76ef6ccf8f15fb34353dba8458ffd2fd 100644
--- a/media/filters/chunk_demuxer.h
+++ b/media/filters/chunk_demuxer.h
@@ -143,9 +143,16 @@ class MEDIA_EXPORT ChunkDemuxer : public Demuxer {
const StreamParser::BufferQueue& buffers,
const scoped_refptr<ChunkDemuxerStream>& stream);
+ // Decreases |duration_| if the buffered region is less than |duration_| when
+ // EoS is called.
acolwell GONE FROM CHROMIUM 2012/08/01 17:09:45 nit: Spell out EndOfStream() here. You've got the
vrk (LEFT CHROMIUM) 2012/08/02 18:23:00 Done.
+ void DecreaseDurationIfNecessary();
+
// Sets |duration_| to |new_duration| and notifies |host_|.
void UpdateDuration(base::TimeDelta new_duration);
+ // Returns the ranges representing the buffered data in the demuxer.
+ Ranges<base::TimeDelta> GetBufferedRanges() const;
+
mutable base::Lock lock_;
State state_;

Powered by Google App Engine
This is Rietveld 408576698