MCPcopy Create free account
hub / github.com/Overv/VulkanTutorial / chooseSwapPresentMode

Method chooseSwapPresentMode

code/25_sampler.cpp:1272–1280  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1270 }
1271
1272 VkPresentModeKHR chooseSwapPresentMode(const std::vector<VkPresentModeKHR>& availablePresentModes) {
1273 for (const auto& availablePresentMode : availablePresentModes) {
1274 if (availablePresentMode == VK_PRESENT_MODE_MAILBOX_KHR) {
1275 return availablePresentMode;
1276 }
1277 }
1278
1279 return VK_PRESENT_MODE_FIFO_KHR;
1280 }
1281
1282 VkExtent2D chooseSwapExtent(const VkSurfaceCapabilitiesKHR& capabilities) {
1283 if (capabilities.currentExtent.width != std::numeric_limits<uint32_t>::max()) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected