-rw-r--r-- | Android.mk | 15 | ||||
-rw-r--r-- | aml_screen.cpp | 2 | ||||
-rw-r--r-- | aml_screen.h | 114 | ||||
-rw-r--r-- | v4l2_vdin.cpp | 6 | ||||
-rw-r--r-- | v4l2_vdin.h | 3 |
5 files changed, 131 insertions, 9 deletions
diff --git a/v4l2_vdin.cpp b/v4l2_vdin.cpp index ff989f9..34f41aa 100644 --- a/v4l2_vdin.cpp +++ b/v4l2_vdin.cpp @@ -959,7 +959,11 @@ int vdin_screen_source::workThread() return BAD_VALUE; } mANativeWindow->lockBuffer_DEPRECATED(mANativeWindow.get(), buf); - sp<GraphicBuffer> graphicBuffer(new GraphicBuffer(buf, false)); + sp<GraphicBuffer> graphicBuffer(new GraphicBuffer(buf->handle, GraphicBuffer::WRAP_HANDLE, + buf->width, buf->height, + buf->format, buf->layerCount, + buf->usage, buf->stride)); + graphicBuffer->lock(SCREENSOURCE_GRALLOC_USAGE, (void **)&dest); if (dest == NULL) { ALOGE("Invalid Gralloc Handle"); |