summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorYiwei Zhang <zzyiwei@chromium.org>2021-06-10 16:26:01 +0000
committerMarge Bot <eric+marge@anholt.net>2021-06-10 17:41:34 +0000
commit02832f9d03c80b32a4837432e3fc18db29b05148 (patch)
tree4497ffaa6bb259b9fbf7d5b74e7421ec5c071779 /include
parent8a3fa2c4d587e803118518d03b4944917c72245b (diff)
vulkan: fix back compat with Android Oreo and below
buffer_handle_t definition was previously inside the deprecated system/core/include/system/window.h. Signed-off-by: Yiwei Zhang <zzyiwei@chromium.org> Acked-by: Chia-I Wu <olvaffe@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11301>
Diffstat (limited to 'include')
-rw-r--r--include/vulkan/vk_android_native_buffer.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/vulkan/vk_android_native_buffer.h b/include/vulkan/vk_android_native_buffer.h
index 17bfd11ab6c..52d7a948fe1 100644
--- a/include/vulkan/vk_android_native_buffer.h
+++ b/include/vulkan/vk_android_native_buffer.h
@@ -20,6 +20,12 @@
#ifdef ANDROID
#include <cutils/native_handle.h>
#include <vulkan/vulkan.h>
+
+#if ANDROID_API_LEVEL < 28
+/* buffer_handle_t was defined in the deprecated system/window.h */
+typedef const native_handle_t *buffer_handle_t;
+#endif
+
#else
typedef void *buffer_handle_t;
#endif