From d79cf0afe26fd6503a47c17a524d45742bf2461a Mon Sep 17 00:00:00 2001 From: Vaxry Date: Fri, 24 Nov 2023 13:47:36 +0000 Subject: [PATCH] renderer: fix software cursors on nvidia fixes #3926 --- src/render/Renderer.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp index 128f36ef..c39f6f74 100644 --- a/src/render/Renderer.cpp +++ b/src/render/Renderer.cpp @@ -2199,9 +2199,10 @@ void CHyprRenderer::renderSoftwareCursors(CMonitor* pMonitor, const CRegion& dam if (!cursor->texture) continue; - CBox cursorBox = CBox{CURSORPOS.x, CURSORPOS.y, cursor->width, cursor->height}.translate({-cursor->hotspot_x, -cursor->hotspot_y}); + CBox cursorBox = CBox{CURSORPOS.x, CURSORPOS.y, cursor->width, cursor->height}.translate({-cursor->hotspot_x, -cursor->hotspot_y}).scale(pMonitor->scale); - g_pHyprOpenGL->renderTexturePrimitive(cursor->texture, &cursorBox); + // TODO: NVIDIA doesn't like if we use renderTexturePrimitive here. Why? + g_pHyprOpenGL->renderTexture(cursor->texture, &cursorBox, 1.0); } }