OSDN Git Service

minigbm: gralloc0: Allow lock_ycbcr for HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED
authorTomasz Figa <tfiga@chromium.org>
Wed, 5 Jul 2017 08:50:18 +0000 (17:50 +0900)
committerchrome-bot <chrome-bot@chromium.org>
Tue, 11 Jul 2017 07:39:00 +0000 (00:39 -0700)
commitaff29fdf276d3f565ab16ba88e4386930fb6dd99
treeaae0895238eda190e57732a88560c84f79eafd24
parentaddd5f2136863ff1f69239266b6e31027b722b17
minigbm: gralloc0: Allow lock_ycbcr for HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED

We can use lock_ycbcr as a way to partially work around the format resolve
problem - with the assumption that if lock_ycbcr succeeds, the
android_ycbcr struct returned describes a YCbCr 4:2:0 image, we can
query gralloc for the format instead of hardcoding one statically.

BUG=b:32077885
TEST=Camera preview renders correctly on Poppy.

Change-Id: Ic20f5aa89809bf89941f3b4851c0d28965da54ac
Reviewed-on: https://chromium-review.googlesource.com/544487
Commit-Ready: Tomasz Figa <tfiga@chromium.org>
Tested-by: Tomasz Figa <tfiga@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
cros_gralloc/gralloc0/gralloc0.cc