diff options
author | Vinil Cheeramvelil <vinil.cheeramvelil@intel.com> | 2015-06-02 15:34:48 -0700 |
---|---|---|
committer | Pat Tjin <pattjin@google.com> | 2015-06-16 23:09:01 +0000 |
commit | c7062268956b5b8cbeab3f7c824eb0fb797f4259 (patch) | |
tree | 12d4214cf2126bff7207c9abc8351fed42d1c060 | |
parent | 9892b9c8b325cc6fc1e3fb98455b3701e89c8885 (diff) | |
download | libmix-c7062268956b5b8cbeab3f7c824eb0fb797f4259.tar.gz |
IMG DDK1.5 update for Intel HWC interface in libmix
Bug: 20914944
Bug: 20302101
Bug: 19412176
Bug: 21265944
Change-Id: I26015436a84cf52cb147ce803610322932b70478
Signed-off-by: Pradeep Radhakrishna <pradeep.radhakrishna@intel.com>
Signed-off-by: Vinil Cheeramvelil <vinil.cheeramvelil@intel.com>
-rw-r--r-- | videoencoder/Android.mk | 3 | ||||
-rw-r--r-- | videoencoder/VideoEncoderUtils.cpp | 10 |
2 files changed, 11 insertions, 2 deletions
diff --git a/videoencoder/Android.mk b/videoencoder/Android.mk index cb8528f..8e2e1cd 100644 --- a/videoencoder/Android.mk +++ b/videoencoder/Android.mk @@ -53,7 +53,8 @@ LOCAL_SHARED_LIBRARIES := \ libva-android \ libva-tpi \ libhardware \ - libintelmetadatabuffer + libintelmetadatabuffer \ + libsync LOCAL_COPY_HEADERS_TO := libmix_videoencoder diff --git a/videoencoder/VideoEncoderUtils.cpp b/videoencoder/VideoEncoderUtils.cpp index 5f78879..067e9e7 100644 --- a/videoencoder/VideoEncoderUtils.cpp +++ b/videoencoder/VideoEncoderUtils.cpp @@ -22,6 +22,7 @@ #ifdef IMG_GFX #include <hal/hal_public.h> #include <hardware/gralloc.h> +#include <sync/sync.h> //#define GFX_DUMP @@ -161,7 +162,14 @@ static int gfx_Blit(buffer_handle_t src, buffer_handle_t dest, IMG_gralloc_module_public_t* GrallocMod = (IMG_gralloc_module_public_t*)gModule; #ifdef MRFLD_GFX - err = GrallocMod->Blit(GrallocMod, src, dest, w, h, 0, 0, 0, 0); + { + int fenceFd; + err = GrallocMod->Blit(GrallocMod, src, dest, w, h, 0, 0, 0, -1, &fenceFd); + if (!err) { + sync_wait(fenceFd, -1); + close(fenceFd); + } + } #else err = GrallocMod->Blit2(GrallocMod, src, dest, w, h, 0, 0); #endif |