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

Unified Diff: media/filters/source_buffer_stream.cc

Issue 2102323002: MSE: Experimental support for new abort and duration behavior (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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/source_buffer_stream.h ('k') | media/filters/source_buffer_stream_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/source_buffer_stream.cc
diff --git a/media/filters/source_buffer_stream.cc b/media/filters/source_buffer_stream.cc
index 61b2501330e28a359608eee6a9a3705b5454fc46..608253b2d87bc5fa38873fbc36a6a6b26f9d7203 100644
--- a/media/filters/source_buffer_stream.cc
+++ b/media/filters/source_buffer_stream.cc
@@ -1401,6 +1401,15 @@ Ranges<base::TimeDelta> SourceBufferStream::GetBufferedTime() const {
return ranges;
}
+base::TimeDelta SourceBufferStream::GetHighestPresentationTimestamp() const {
+ if (ranges_.empty())
+ return base::TimeDelta();
+
+ // TODO(wolenetz): Report actual highest PTS here, not DTS cast to PTS. See
+ // https://crbug.com/398130.
+ return ranges_.back()->GetEndTimestamp().ToPresentationTime();
+}
+
base::TimeDelta SourceBufferStream::GetBufferedDuration() const {
if (ranges_.empty())
return base::TimeDelta();
« no previous file with comments | « media/filters/source_buffer_stream.h ('k') | media/filters/source_buffer_stream_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698