summaryrefslogtreecommitdiffstats
path: root/media/base/video_frame.h
diff options
context:
space:
mode:
authorwonsik@google.com <wonsik@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-04 06:31:21 +0000
committerwonsik@google.com <wonsik@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-04 06:31:21 +0000
commiteadbaaf32f299ba14e6b792e4851322c287d4a4a (patch)
treec1e83b3cd17fc73e153da0d49fbc96f9b4723755 /media/base/video_frame.h
parent88ac5c023116aa501b9fd9eeac102f4f0b8f4419 (diff)
downloadchromium_src-eadbaaf32f299ba14e6b792e4851322c287d4a4a.zip
chromium_src-eadbaaf32f299ba14e6b792e4851322c287d4a4a.tar.gz
chromium_src-eadbaaf32f299ba14e6b792e4851322c287d4a4a.tar.bz2
Implement "hole" video frame.
In order to support out-of-band compositing of protected video content in Chrome, it is necessary to have a transparent hole in Chrome's HTML rendering so that video playing "beneath" the HTML elements can be seen through. To accomplish the scenario stated above, define a "hole" video frame which would clear the region where video would have been composited. In CC, this is done by sending a transparent black SolidColorDrawQuad with blending disabled. Review URL: https://chromiumcodereview.appspot.com/12255032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@185841 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/base/video_frame.h')
-rw-r--r--media/base/video_frame.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/media/base/video_frame.h b/media/base/video_frame.h
index 3483e91..07697c2 100644
--- a/media/base/video_frame.h
+++ b/media/base/video_frame.h
@@ -43,6 +43,9 @@ class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> {
EMPTY = 9, // An empty frame.
I420 = 11, // 12bpp YVU planar 1x1 Y, 2x2 UV samples.
NATIVE_TEXTURE = 12, // Native texture. Pixel-format agnostic.
+#if defined(GOOGLE_TV)
+ HOLE = 13, // Hole frame.
+#endif
};
// Creates a new frame in system memory with given parameters. Buffers for
@@ -125,6 +128,11 @@ class MEDIA_EXPORT VideoFrame : public base::RefCountedThreadSafe<VideoFrame> {
// equivalent of RGB(0,0,0).
static scoped_refptr<VideoFrame> CreateBlackFrame(const gfx::Size& size);
+#if defined(GOOGLE_TV)
+ // Allocates a hole frame.
+ static scoped_refptr<VideoFrame> CreateHoleFrame(const gfx::Size& size);
+#endif
+
Format format() const { return format_; }
const gfx::Size& coded_size() const { return coded_size_; }