diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2019-10-20 17:35:16 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2019-10-21 10:37:29 +0200 |
commit | 82793cdc229c225494cc7e64d6351321c2442a23 (patch) | |
tree | 115493c12465e40bff1d609a9a21262974837815 /src | |
parent | 5001f79c4f98e22d9a301ae6519a67d1135f7312 (diff) |
Fix broken scaling with high dpi + rhi + thread loop
The arguments to renderSceneGraph() were incorrect in the threaded
render loop, unlike basic. Fix it up to follow what we do in the
basic loop. (The first argument is the QWindow size (logical). The
second is only used when rendering via the rhi, and is the output
surface/layer size, in pixels. This will get simplified in Qt 6.)
This fixes broken rendering with Metal and the threaded render loop
for windows with dpr > 1.
Change-Id: I427ba5def8cc34900e6fe650e1006ca5f0fa90a4
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/quick/scenegraph/qsgthreadedrenderloop.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/quick/scenegraph/qsgthreadedrenderloop.cpp b/src/quick/scenegraph/qsgthreadedrenderloop.cpp index 86d9590863..dc1f97de54 100644 --- a/src/quick/scenegraph/qsgthreadedrenderloop.cpp +++ b/src/quick/scenegraph/qsgthreadedrenderloop.cpp @@ -807,9 +807,7 @@ void QSGRenderThread::syncAndRender(QImage *grabImage) } } if (current) { - const QSize outputSize = rhi ? cd->swapchain->currentPixelSize() : windowSize; - - d->renderSceneGraph(outputSize); + d->renderSceneGraph(windowSize, rhi ? cd->swapchain->currentPixelSize() : QSize()); if (profileFrames) renderTime = threadTimer.nsecsElapsed(); |