MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Tools / AppCreateAndroidSurface

Function AppCreateAndroidSurface

vulkaninfo/vulkaninfo.h:1114–1125  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1112#ifdef VK_USE_PLATFORM_ANDROID_KHR
1113static void AppCreateAndroidWindow(AppInstance &inst) {}
1114static VkSurfaceKHR AppCreateAndroidSurface(AppInstance &inst) {
1115 VkAndroidSurfaceCreateInfoKHR createInfo;
1116 createInfo.sType = VK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR;
1117 createInfo.pNext = NULL;
1118 createInfo.flags = 0;
1119 createInfo.window = (struct ANativeWindow *)(inst.window);
1120
1121 VkSurfaceKHR surface;
1122 VkResult err = vkCreateAndroidSurfaceKHR(inst.instance, &createInfo, NULL, &surface);
1123 if (err) THROW_VK_ERR("vkCreateAndroidSurfaceKHR", err);
1124 return surface;
1125}
1126static void AppDestroyAndroidWindow(AppInstance &inst) {}
1127#endif
1128//-----------------------------------------------------------

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected