diff options
author | Jamie Gennis <jgennis@google.com> | 2010-08-30 16:48:38 -0700 |
---|---|---|
committer | Jamie Gennis <jgennis@google.com> | 2010-09-01 13:07:08 -0700 |
commit | 559dc605bfe2deb73ad718e0d5c5dc55e27c45df (patch) | |
tree | c98ca8836231a2cb5332e67f866f38ab9c811f4e /media/libstagefright/omx/OMX.cpp | |
parent | 53bfd693c45278bf71cb5e184ffd3e95d52e04d8 (diff) | |
download | frameworks_av-559dc605bfe2deb73ad718e0d5c5dc55e27c45df.zip frameworks_av-559dc605bfe2deb73ad718e0d5c5dc55e27c45df.tar.gz frameworks_av-559dc605bfe2deb73ad718e0d5c5dc55e27c45df.tar.bz2 |
Add the new Stagefright ANativeWindow OMX codec API.
This change defines the two OMX_SetParameter calls that enable OMX codecs to
interact with ANativeWindows. It also adds the plumbing to the IOMX, OMX, and
OMXNodeInstance classes to use these new APIs.
Change-Id: Ibfbf893dc3513db0b3d3221bec5708c77287cddc
Diffstat (limited to 'media/libstagefright/omx/OMX.cpp')
-rw-r--r-- | media/libstagefright/omx/OMX.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/media/libstagefright/omx/OMX.cpp b/media/libstagefright/omx/OMX.cpp index 88b9605..37243ad 100644 --- a/media/libstagefright/omx/OMX.cpp +++ b/media/libstagefright/omx/OMX.cpp @@ -287,6 +287,11 @@ status_t OMX::setConfig( index, params, size); } +status_t OMX::enableGraphicBuffers( + node_id node, OMX_U32 port_index, OMX_BOOL enable) { + return findInstance(node)->enableGraphicBuffers(port_index, enable); +} + status_t OMX::useBuffer( node_id node, OMX_U32 port_index, const sp<IMemory> ¶ms, buffer_id *buffer) { @@ -294,6 +299,13 @@ status_t OMX::useBuffer( port_index, params, buffer); } +status_t OMX::useGraphicBuffer( + node_id node, OMX_U32 port_index, + const sp<GraphicBuffer> &graphicBuffer, buffer_id *buffer) { + return findInstance(node)->useGraphicBuffer( + port_index, graphicBuffer, buffer); +} + status_t OMX::allocateBuffer( node_id node, OMX_U32 port_index, size_t size, buffer_id *buffer, void **buffer_data) { @@ -530,4 +542,3 @@ void OMXRenderer::render(IOMX::buffer_id buffer) { } } // namespace android - |