OSDN Git Service

vulkan: Translate usage flags before passing to driver
authorChris Forbes <chrisforbes@google.com>
Fri, 19 May 2017 21:47:29 +0000 (14:47 -0700)
committerChris Forbes <chrisforbes@google.com>
Mon, 31 Jul 2017 15:53:19 +0000 (15:53 +0000)
commit8e0c3f5f1c4ffc3a055fe016406bd6a549ebdd00
treedc447634ab64bc8840967bb18309ca1307013c65
parent58ba988476d848598e62376f726f69c567d033ad
vulkan: Translate usage flags before passing to driver

Previously we just cast the 32bit flags and jammed them in the two
gralloc1 slots. Use the helper which does the correct translation.

(Yes, all these gralloc1isms are going away in favor of a single 64bit
flags field, but Vulkan HALs expect us to implement our side of
ANDROID_native_buffer correctly.)

(Cherry-picked from 4744291270cc6 in oc-dev)

Test: boot sailfish, run vulkan demo
Bug: 37686587
Change-Id: I806011986e8140d7f608d281798605bd9ca9a86b
vulkan/libvulkan/swapchain.cpp