summaryrefslogtreecommitdiffstats
path: root/media/video
diff options
context:
space:
mode:
authorwatk <watk@chromium.org>2016-02-03 14:37:05 -0800
committerCommit bot <commit-bot@chromium.org>2016-02-03 22:37:55 +0000
commitcd5d9e95ca27d3a71ef31c21ba82b2f55fa4f49e (patch)
tree17ae973931ff4d25f2c683bd03a1cd5401c8435e /media/video
parent386c2301bdf5a65263d6f28c60bea2374d1b414e (diff)
downloadchromium_src-cd5d9e95ca27d3a71ef31c21ba82b2f55fa4f49e.zip
chromium_src-cd5d9e95ca27d3a71ef31c21ba82b2f55fa4f49e.tar.gz
chromium_src-cd5d9e95ca27d3a71ef31c21ba82b2f55fa4f49e.tar.bz2
AndroidVideoDecodeAccelerator can now render to a SurfaceView
Previously AVDA would always configure MediaCodec with a SurfaceTexture. Now, to support efficient fullscreen video, it can render to a SurfaceView too. BUG=533630 Review URL: https://codereview.chromium.org/1639963002 Cr-Commit-Position: refs/heads/master@{#373365}
Diffstat (limited to 'media/video')
-rw-r--r--media/video/video_decode_accelerator.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/media/video/video_decode_accelerator.h b/media/video/video_decode_accelerator.h
index 87fac21..f638ce4 100644
--- a/media/video/video_decode_accelerator.h
+++ b/media/video/video_decode_accelerator.h
@@ -82,6 +82,8 @@ class MEDIA_EXPORT VideoDecodeAccelerator {
// Config structure contains parameters required for the VDA initialization.
struct MEDIA_EXPORT Config {
+ enum { kNoSurfaceID = -1 };
+
Config() = default;
Config(VideoCodecProfile profile);
Config(const VideoDecoderConfig& video_decoder_config);
@@ -93,6 +95,11 @@ class MEDIA_EXPORT VideoDecodeAccelerator {
// The flag indicating whether the stream is encrypted.
bool is_encrypted = false;
+
+ // An optional graphics surface that the VDA should render to. For setting
+ // an output SurfaceView on Android. It's only valid when not equal to
+ // |kNoSurfaceID|.
+ int surface_id = kNoSurfaceID;
};
// Interface for collaborating with picture interface to provide memory for