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

Unified Diff: media/base/filters.h

Issue 9155003: Fix media timeline so that thumb never exceeds buffered data (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase ToT, again Created 8 years, 11 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/base/filter_host.h ('k') | media/base/mock_filter_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/filters.h
diff --git a/media/base/filters.h b/media/base/filters.h
index 49927237ad4e6072e17fa5121f60cbacbfe0bafd..5600edaec18b2451d7d58fc1b0a81a9bf90e077b 100644
--- a/media/base/filters.h
+++ b/media/base/filters.h
@@ -204,11 +204,16 @@ class MEDIA_EXPORT AudioDecoder : public Filter {
class MEDIA_EXPORT VideoRenderer : public Filter {
public:
+ // Used to update the pipeline's clock time. The parameter is the time that
+ // the clock should not exceed.
+ typedef base::Callback<void(base::TimeDelta)> VideoTimeCB;
+
// Initialize a VideoRenderer with the given VideoDecoder, executing the
// callback upon completion.
virtual void Initialize(VideoDecoder* decoder,
const PipelineStatusCB& callback,
- const StatisticsCallback& stats_callback) = 0;
+ const StatisticsCallback& stats_callback,
+ const VideoTimeCB& time_cb) = 0;
// Returns true if this filter has received and processed an end-of-stream
// buffer.
@@ -218,6 +223,11 @@ class MEDIA_EXPORT VideoRenderer : public Filter {
class MEDIA_EXPORT AudioRenderer : public Filter {
public:
+ // Used to update the pipeline's clock time. The first parameter is the
+ // current time, and the second parameter is the time that the clock must not
+ // exceed.
+ typedef base::Callback<void(base::TimeDelta, base::TimeDelta)> AudioTimeCB;
+
// Initialize a AudioRenderer with the given AudioDecoder, executing the
// |init_callback| upon completion. |underflow_callback| is called when the
// renderer runs out of data to pass to the audio card during playback.
@@ -226,7 +236,8 @@ class MEDIA_EXPORT AudioRenderer : public Filter {
// condition.
virtual void Initialize(AudioDecoder* decoder,
const PipelineStatusCB& init_callback,
- const base::Closure& underflow_callback) = 0;
+ const base::Closure& underflow_callback,
+ const AudioTimeCB& time_cb) = 0;
// Returns true if this filter has received and processed an end-of-stream
// buffer.
« no previous file with comments | « media/base/filter_host.h ('k') | media/base/mock_filter_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698