summaryrefslogtreecommitdiffstats
path: root/webkit/glue/media/web_video_renderer.h
diff options
context:
space:
mode:
authorIain Merrick <husky@google.com>2010-10-19 14:37:37 +0100
committerIain Merrick <husky@google.com>2010-10-19 14:37:37 +0100
commit3345a6884c488ff3a535c2c9acdd33d74b37e311 (patch)
tree7784b988ef1698cb6967ea1bdf07616237716c6c /webkit/glue/media/web_video_renderer.h
parentefc8475837ec58186051f23bb03542620424f6ce (diff)
downloadexternal_chromium-3345a6884c488ff3a535c2c9acdd33d74b37e311.zip
external_chromium-3345a6884c488ff3a535c2c9acdd33d74b37e311.tar.gz
external_chromium-3345a6884c488ff3a535c2c9acdd33d74b37e311.tar.bz2
Merge Chromium at 7.0.540.0 : Initial merge by git
Not including third_party/icu as it contains huge data files that break Gerrit, and aren't actually used. Change-Id: I428a386e70f3b58cacd28677b8cfda282e891e15
Diffstat (limited to 'webkit/glue/media/web_video_renderer.h')
-rw-r--r--webkit/glue/media/web_video_renderer.h16
1 files changed, 13 insertions, 3 deletions
diff --git a/webkit/glue/media/web_video_renderer.h b/webkit/glue/media/web_video_renderer.h
index 8bafb1a..d8b47ad 100644
--- a/webkit/glue/media/web_video_renderer.h
+++ b/webkit/glue/media/web_video_renderer.h
@@ -1,10 +1,11 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved. Use of this
-// source code is governed by a BSD-style license that can be found in the
-// LICENSE file.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
#ifndef WEBKIT_GLUE_MEDIA_WEB_VIDEO_RENDERER_H_
#define WEBKIT_GLUE_MEDIA_WEB_VIDEO_RENDERER_H_
+#include "media/base/video_frame.h"
#include "media/filters/video_renderer_base.h"
namespace webkit_glue {
@@ -30,6 +31,15 @@ class WebVideoRenderer : public media::VideoRendererBase {
virtual void Paint(skia::PlatformCanvas* canvas,
const gfx::Rect& dest_rect) = 0;
+ // Clients of this class (painter/compositor) should use GetCurrentFrame()
+ // obtain ownership of VideoFrame, it should always relinquish the ownership
+ // by use PutCurrentFrame(). Current frame is not guaranteed to be non-NULL.
+ // It expects clients to use color-fill the background if current frame
+ // is NULL. This could happen when before pipeline is pre-rolled or during
+ // pause/flush/seek.
+ virtual void GetCurrentFrame(scoped_refptr<media::VideoFrame>* frame_out) {}
+ virtual void PutCurrentFrame(scoped_refptr<media::VideoFrame> frame) {}
+
private:
DISALLOW_COPY_AND_ASSIGN(WebVideoRenderer);
};