aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2018-11-26 14:22:13 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2018-11-28 15:28:11 +0000
commit04af30c91a68a04ab1830d6ddc1bf470354b1862 (patch)
tree9b4d2d9708ca36591277d08420dc946364f05c10 /src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp
parent0e87966c8f815269b770a0a31974e0cd5b8ab26e (diff)
Disable antialiased clipping when painting images
It shouldn't be needed and produces tiling gaps Change-Id: I3c7bbc91e5e618bdb111ddf18412acac253f2c6e Task-number: QTBUG-71322 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp')
-rw-r--r--src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp b/src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp
index 471624d3f8..bd0698be6c 100644
--- a/src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp
+++ b/src/quick/scenegraph/adaptations/software/qsgsoftwarepublicnodes.cpp
@@ -99,6 +99,8 @@ void QSGSoftwareImageNode::paint(QPainter *painter)
updateCachedMirroredPixmap();
painter->setRenderHint(QPainter::SmoothPixmapTransform, (m_filtering == QSGTexture::Linear));
+ // Disable antialiased clipping. It causes transformed tiles to have gaps.
+ painter->setRenderHint(QPainter::Antialiasing, false);
if (!m_cachedPixmap.isNull()) {
painter->drawPixmap(m_rect, m_cachedPixmap, m_sourceRect);
@@ -194,6 +196,9 @@ void QSGSoftwareNinePatchNode::update()
void QSGSoftwareNinePatchNode::paint(QPainter *painter)
{
+ // Disable antialiased clipping. It causes transformed tiles to have gaps.
+ painter->setRenderHint(QPainter::Antialiasing, false);
+
if (m_margins.isNull())
painter->drawPixmap(m_bounds, m_pixmap, QRectF(0, 0, m_pixmap.width(), m_pixmap.height()));
else