summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar@sletta.org>2015-10-19 10:17:51 +0200
committerGunnar Sletta <gunnar@sletta.org>2015-10-19 18:06:38 +0000
commitad227e9808288b12726114365ae1474386c6cdf8 (patch)
tree02f357b144796ca63681bb8b68b2a07d03c4f489
parent859c89fb98154d87e856dce575ff8979218f5fb6 (diff)
downloadqtgraphicaleffects-ad227e9808288b12726114365ae1474386c6cdf8.tar.gz
Clamp DropShadow's radius to [0, floor(samples/2)]
Change-Id: Ib92b7adf0c46aa6456797ba69c42f38fc67021bf Task-number: QTBUG-47749 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
-rw-r--r--src/effects/private/DropShadowBase.qml2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/effects/private/DropShadowBase.qml b/src/effects/private/DropShadowBase.qml
index 3660619..21ef0ea 100644
--- a/src/effects/private/DropShadowBase.qml
+++ b/src/effects/private/DropShadowBase.qml
@@ -62,7 +62,7 @@ Item {
x: Math.round(horizontalOffset)
y: Math.round(verticalOffset)
source: root.source
- radius: root.radius
+ radius: Math.min(Math.floor(root.samples / 2), root.radius)
samples: root.samples
_thickness: root.spread
transparentBorder: root.transparentBorder