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

Unified Diff: media/filters/video_renderer_base.h

Issue 11428095: Pass in media message loop to VideoRendererBase and enforce calling on the right thread. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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/video_renderer_base.h
diff --git a/media/filters/video_renderer_base.h b/media/filters/video_renderer_base.h
index 85e6527c68112d60f56de6b729b5fa13e047f5ed..7ff82da5e1b7c045d3343314008f2a2f7430f9b3 100644
--- a/media/filters/video_renderer_base.h
+++ b/media/filters/video_renderer_base.h
@@ -17,6 +17,10 @@
#include "media/base/video_frame.h"
#include "media/base/video_renderer.h"
+namespace base {
+class MessageLoopProxy;
+}
+
namespace media {
// VideoRendererBase creates its own thread for the sole purpose of timing frame
@@ -48,7 +52,8 @@ class MEDIA_EXPORT VideoRendererBase
// Get/PutCurrentFrame() http://crbug.com/108435
VideoRendererBase(const base::Closure& paint_cb,
const SetOpaqueCB& set_opaque_cb,
- bool drop_frames);
+ bool drop_frames,
+ const scoped_refptr<base::MessageLoopProxy>& message_loop);
Ami GONE FROM CHROMIUM 2012/11/29 23:34:23 could alternatively let the decoder tell the rende
scherkus (not reviewing) 2012/11/29 23:45:56 I'm mulling over this one the "caller has to know
// VideoRenderer implementation.
virtual void Initialize(const scoped_refptr<DemuxerStream>& stream,
@@ -249,6 +254,8 @@ class MEDIA_EXPORT VideoRendererBase
// The last natural size |size_changed_cb_| was called with.
gfx::Size last_natural_size_;
+ scoped_refptr<base::MessageLoopProxy> decoder_message_loop_;
+
DISALLOW_COPY_AND_ASSIGN(VideoRendererBase);
};

Powered by Google App Engine
This is Rietveld 408576698