From bf4c5241a0d3069925e4fafcbe0387f879dc1955 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Thu, 11 Apr 2024 16:36:46 +0300 Subject: [PATCH] backends/x11: Use correct allocator when using software rendering The drm device will be null when using software rendering. --- src/backends/x11/windowed/x11_windowed_qpainter_backend.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backends/x11/windowed/x11_windowed_qpainter_backend.cpp b/src/backends/x11/windowed/x11_windowed_qpainter_backend.cpp index c1ef98ee59..efc3565386 100644 --- a/src/backends/x11/windowed/x11_windowed_qpainter_backend.cpp +++ b/src/backends/x11/windowed/x11_windowed_qpainter_backend.cpp @@ -36,7 +36,7 @@ std::optional X11WindowedQPainterPrimaryLayer::beginF { const QSize bufferSize = m_output->modeSize(); if (!m_swapchain || m_swapchain->size() != bufferSize) { - m_swapchain = std::make_unique(m_backend->drmDevice()->allocator(), bufferSize, m_output->backend()->driFormatForDepth(m_output->depth())); + m_swapchain = std::make_unique(m_backend->graphicsBufferAllocator(), bufferSize, m_output->backend()->driFormatForDepth(m_output->depth())); } m_current = m_swapchain->acquire();