summaryrefslogtreecommitdiffstats
path: root/include/media/stagefright/MediaCodec.h
diff options
context:
space:
mode:
authorLajos Molnar <lajos@google.com>2015-04-30 13:59:10 -0700
committerLajos Molnar <lajos@google.com>2015-05-01 18:45:35 -0700
commit1dcdfead2971c1fa7c02f24ba86f706890c9f99e (patch)
treee07226a98400e308d1a82499fbdb76757603937c /include/media/stagefright/MediaCodec.h
parent64da6f045b1a1d1b8f01391b6e37287f77f85d1e (diff)
downloadframeworks_av-1dcdfead2971c1fa7c02f24ba86f706890c9f99e.zip
frameworks_av-1dcdfead2971c1fa7c02f24ba86f706890c9f99e.tar.gz
frameworks_av-1dcdfead2971c1fa7c02f24ba86f706890c9f99e.tar.bz2
stagefright: add support for dynamically setting MediaCodec output surface
Bug: 11990461 Change-Id: I2aee89ef504234dc66eb5fcf6e62e1706088f758
Diffstat (limited to 'include/media/stagefright/MediaCodec.h')
-rw-r--r--include/media/stagefright/MediaCodec.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/media/stagefright/MediaCodec.h b/include/media/stagefright/MediaCodec.h
index e232ce6..3187938 100644
--- a/include/media/stagefright/MediaCodec.h
+++ b/include/media/stagefright/MediaCodec.h
@@ -141,6 +141,8 @@ struct MediaCodec : public AHandler {
status_t getOutputFormat(size_t index, sp<AMessage> *format);
status_t getInputBuffer(size_t index, sp<ABuffer> *buffer);
+ status_t setSurface(const sp<Surface> &nativeWindow);
+
status_t requestIDRFrame();
// Notification will be posted once there "is something to do", i.e.
@@ -179,6 +181,7 @@ private:
enum {
kWhatInit = 'init',
kWhatConfigure = 'conf',
+ kWhatSetSurface = 'sSur',
kWhatCreateInputSurface = 'cisf',
kWhatStart = 'strt',
kWhatStop = 'stop',
@@ -334,8 +337,9 @@ private:
void extractCSD(const sp<AMessage> &format);
status_t queueCSDInputBuffer(size_t bufferIndex);
- status_t handleSetSurface(
- const sp<Surface> &surface);
+ status_t handleSetSurface(const sp<Surface> &surface);
+ status_t connectToSurface(const sp<Surface> &surface);
+ status_t disconnectFromSurface();
void postActivityNotificationIfPossible();