Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4d5bf2a0 authored by Greg Daniel's avatar Greg Daniel
Browse files

Prefer using 3 buffers in vulkan swapchain.

Test: manual build and running.
Bug: 119687951

Change-Id: I799955d8e035d01acb991417e95e424848fe711f
parent f660c012
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -744,7 +744,7 @@ bool VulkanManager::createSwapchain(VulkanSurface* surface) {
    surface->mWindowWidth = extent.width;
    surface->mWindowHeight = extent.height;

    uint32_t imageCount = caps.minImageCount + 2;
    uint32_t imageCount = std::max<uint32_t>(3, caps.minImageCount);
    if (caps.maxImageCount > 0 && imageCount > caps.maxImageCount) {
        // Application must settle for fewer images than desired:
        imageCount = caps.maxImageCount;