Mercurial > games > semicongine
comparison fuhtark_test/Vulkan-Headers-1.4.334/include/vulkan/vulkan_ohos.h @ 1501:f40d9d814c08 default tip
did: correct vulkan-api generator
| author | sam <sam@basx.dev> |
|---|---|
| date | Wed, 26 Nov 2025 23:34:29 +0700 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 1500:91c8c3b7cbf0 | 1501:f40d9d814c08 |
|---|---|
| 1 #ifndef VULKAN_OHOS_H_ | |
| 2 #define VULKAN_OHOS_H_ 1 | |
| 3 | |
| 4 /* | |
| 5 ** Copyright 2015-2025 The Khronos Group Inc. | |
| 6 ** | |
| 7 ** SPDX-License-Identifier: Apache-2.0 | |
| 8 */ | |
| 9 | |
| 10 /* | |
| 11 ** This header is generated from the Khronos Vulkan XML API Registry. | |
| 12 ** | |
| 13 */ | |
| 14 | |
| 15 | |
| 16 #ifdef __cplusplus | |
| 17 extern "C" { | |
| 18 #endif | |
| 19 | |
| 20 | |
| 21 | |
| 22 // VK_OHOS_external_memory is a preprocessor guard. Do not pass it to API calls. | |
| 23 #define VK_OHOS_external_memory 1 | |
| 24 struct OH_NativeBuffer; | |
| 25 #define VK_OHOS_EXTERNAL_MEMORY_SPEC_VERSION 1 | |
| 26 #define VK_OHOS_EXTERNAL_MEMORY_EXTENSION_NAME "VK_OHOS_external_memory" | |
| 27 typedef struct VkNativeBufferUsageOHOS { | |
| 28 VkStructureType sType; | |
| 29 void* pNext; | |
| 30 uint64_t OHOSNativeBufferUsage; | |
| 31 } VkNativeBufferUsageOHOS; | |
| 32 | |
| 33 typedef struct VkNativeBufferPropertiesOHOS { | |
| 34 VkStructureType sType; | |
| 35 void* pNext; | |
| 36 VkDeviceSize allocationSize; | |
| 37 uint32_t memoryTypeBits; | |
| 38 } VkNativeBufferPropertiesOHOS; | |
| 39 | |
| 40 typedef struct VkNativeBufferFormatPropertiesOHOS { | |
| 41 VkStructureType sType; | |
| 42 void* pNext; | |
| 43 VkFormat format; | |
| 44 uint64_t externalFormat; | |
| 45 VkFormatFeatureFlags formatFeatures; | |
| 46 VkComponentMapping samplerYcbcrConversionComponents; | |
| 47 VkSamplerYcbcrModelConversion suggestedYcbcrModel; | |
| 48 VkSamplerYcbcrRange suggestedYcbcrRange; | |
| 49 VkChromaLocation suggestedXChromaOffset; | |
| 50 VkChromaLocation suggestedYChromaOffset; | |
| 51 } VkNativeBufferFormatPropertiesOHOS; | |
| 52 | |
| 53 typedef struct VkImportNativeBufferInfoOHOS { | |
| 54 VkStructureType sType; | |
| 55 const void* pNext; | |
| 56 struct OH_NativeBuffer* buffer; | |
| 57 } VkImportNativeBufferInfoOHOS; | |
| 58 | |
| 59 typedef struct VkMemoryGetNativeBufferInfoOHOS { | |
| 60 VkStructureType sType; | |
| 61 const void* pNext; | |
| 62 VkDeviceMemory memory; | |
| 63 } VkMemoryGetNativeBufferInfoOHOS; | |
| 64 | |
| 65 typedef struct VkExternalFormatOHOS { | |
| 66 VkStructureType sType; | |
| 67 void* pNext; | |
| 68 uint64_t externalFormat; | |
| 69 } VkExternalFormatOHOS; | |
| 70 | |
| 71 typedef VkResult (VKAPI_PTR *PFN_vkGetNativeBufferPropertiesOHOS)(VkDevice device, const struct OH_NativeBuffer* buffer, VkNativeBufferPropertiesOHOS* pProperties); | |
| 72 typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryNativeBufferOHOS)(VkDevice device, const VkMemoryGetNativeBufferInfoOHOS* pInfo, struct OH_NativeBuffer** pBuffer); | |
| 73 | |
| 74 #ifndef VK_NO_PROTOTYPES | |
| 75 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 76 VKAPI_ATTR VkResult VKAPI_CALL vkGetNativeBufferPropertiesOHOS( | |
| 77 VkDevice device, | |
| 78 const struct OH_NativeBuffer* buffer, | |
| 79 VkNativeBufferPropertiesOHOS* pProperties); | |
| 80 #endif | |
| 81 | |
| 82 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 83 VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryNativeBufferOHOS( | |
| 84 VkDevice device, | |
| 85 const VkMemoryGetNativeBufferInfoOHOS* pInfo, | |
| 86 struct OH_NativeBuffer** pBuffer); | |
| 87 #endif | |
| 88 #endif | |
| 89 | |
| 90 | |
| 91 // VK_OHOS_surface is a preprocessor guard. Do not pass it to API calls. | |
| 92 #define VK_OHOS_surface 1 | |
| 93 typedef struct NativeWindow OHNativeWindow; | |
| 94 #define VK_OHOS_SURFACE_SPEC_VERSION 1 | |
| 95 #define VK_OHOS_SURFACE_EXTENSION_NAME "VK_OHOS_surface" | |
| 96 typedef VkFlags VkSurfaceCreateFlagsOHOS; | |
| 97 typedef struct VkSurfaceCreateInfoOHOS { | |
| 98 VkStructureType sType; | |
| 99 const void* pNext; | |
| 100 VkSurfaceCreateFlagsOHOS flags; | |
| 101 OHNativeWindow* window; | |
| 102 } VkSurfaceCreateInfoOHOS; | |
| 103 | |
| 104 typedef VkResult (VKAPI_PTR *PFN_vkCreateSurfaceOHOS)(VkInstance instance, const VkSurfaceCreateInfoOHOS* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); | |
| 105 | |
| 106 #ifndef VK_NO_PROTOTYPES | |
| 107 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 108 VKAPI_ATTR VkResult VKAPI_CALL vkCreateSurfaceOHOS( | |
| 109 VkInstance instance, | |
| 110 const VkSurfaceCreateInfoOHOS* pCreateInfo, | |
| 111 const VkAllocationCallbacks* pAllocator, | |
| 112 VkSurfaceKHR* pSurface); | |
| 113 #endif | |
| 114 #endif | |
| 115 | |
| 116 | |
| 117 // VK_OHOS_native_buffer is a preprocessor guard. Do not pass it to API calls. | |
| 118 #define VK_OHOS_native_buffer 1 | |
| 119 struct OHBufferHandle; | |
| 120 #define VK_OHOS_NATIVE_BUFFER_SPEC_VERSION 1 | |
| 121 #define VK_OHOS_NATIVE_BUFFER_EXTENSION_NAME "VK_OHOS_native_buffer" | |
| 122 | |
| 123 typedef enum VkSwapchainImageUsageFlagBitsOHOS { | |
| 124 VK_SWAPCHAIN_IMAGE_USAGE_SHARED_BIT_OHOS = 0x00000001, | |
| 125 VK_SWAPCHAIN_IMAGE_USAGE_FLAG_BITS_MAX_ENUM_OHOS = 0x7FFFFFFF | |
| 126 } VkSwapchainImageUsageFlagBitsOHOS; | |
| 127 typedef VkFlags VkSwapchainImageUsageFlagsOHOS; | |
| 128 typedef struct VkNativeBufferOHOS { | |
| 129 VkStructureType sType; | |
| 130 const void* pNext; | |
| 131 struct OHBufferHandle* handle; | |
| 132 } VkNativeBufferOHOS; | |
| 133 | |
| 134 typedef struct VkSwapchainImageCreateInfoOHOS { | |
| 135 VkStructureType sType; | |
| 136 const void* pNext; | |
| 137 VkSwapchainImageUsageFlagsOHOS usage; | |
| 138 } VkSwapchainImageCreateInfoOHOS; | |
| 139 | |
| 140 typedef struct VkPhysicalDevicePresentationPropertiesOHOS { | |
| 141 VkStructureType sType; | |
| 142 void* pNext; | |
| 143 VkBool32 sharedImage; | |
| 144 } VkPhysicalDevicePresentationPropertiesOHOS; | |
| 145 | |
| 146 typedef VkResult (VKAPI_PTR *PFN_vkGetSwapchainGrallocUsageOHOS)(VkDevice device, VkFormat format, VkImageUsageFlags imageUsage, uint64_t* grallocUsage); | |
| 147 typedef VkResult (VKAPI_PTR *PFN_vkAcquireImageOHOS)(VkDevice device, VkImage image, int32_t nativeFenceFd, VkSemaphore semaphore, VkFence fence); | |
| 148 typedef VkResult (VKAPI_PTR *PFN_vkQueueSignalReleaseImageOHOS)(VkQueue queue, uint32_t waitSemaphoreCount, const VkSemaphore* pWaitSemaphores, VkImage image, int32_t* pNativeFenceFd); | |
| 149 | |
| 150 #ifndef VK_NO_PROTOTYPES | |
| 151 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 152 VKAPI_ATTR VkResult VKAPI_CALL vkGetSwapchainGrallocUsageOHOS( | |
| 153 VkDevice device, | |
| 154 VkFormat format, | |
| 155 VkImageUsageFlags imageUsage, | |
| 156 uint64_t* grallocUsage); | |
| 157 #endif | |
| 158 | |
| 159 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 160 VKAPI_ATTR VkResult VKAPI_CALL vkAcquireImageOHOS( | |
| 161 VkDevice device, | |
| 162 VkImage image, | |
| 163 int32_t nativeFenceFd, | |
| 164 VkSemaphore semaphore, | |
| 165 VkFence fence); | |
| 166 #endif | |
| 167 | |
| 168 #ifndef VK_ONLY_EXPORTED_PROTOTYPES | |
| 169 VKAPI_ATTR VkResult VKAPI_CALL vkQueueSignalReleaseImageOHOS( | |
| 170 VkQueue queue, | |
| 171 uint32_t waitSemaphoreCount, | |
| 172 const VkSemaphore* pWaitSemaphores, | |
| 173 VkImage image, | |
| 174 int32_t* pNativeFenceFd); | |
| 175 #endif | |
| 176 #endif | |
| 177 | |
| 178 #ifdef __cplusplus | |
| 179 } | |
| 180 #endif | |
| 181 | |
| 182 #endif |
