summaryrefslogtreecommitdiffstats
path: root/src/openvg
diff options
context:
space:
mode:
authorRhys Weatherley <rhys.weatherley@nokia.com>2009-07-01 23:57:52 (GMT)
committerRhys Weatherley <rhys.weatherley@nokia.com>2009-07-01 23:57:52 (GMT)
commitf31d2c01e5998a9fcf4345fa66e0349921e115da (patch)
tree2348fe8e3e9143f0383051060298e8cac941f919 /src/openvg
parent29b71240d17a1557fd9a8d2ce7dcd450b07b57a8 (diff)
downloadQt-f31d2c01e5998a9fcf4345fa66e0349921e115da.zip
Qt-f31d2c01e5998a9fcf4345fa66e0349921e115da.tar.gz
Qt-f31d2c01e5998a9fcf4345fa66e0349921e115da.tar.bz2
OpenVG: use the correct clip region to detect single-rect clips
"Special case: if the intersection of the system clip and the region is a single rectangle, then use the scissor for clipping." It was doing the intersection but then didn't use the intersection to test for the single-rectangle case. Task-number: QT-64 Reviewed-by: trustme
Diffstat (limited to 'src/openvg')
-rw-r--r--src/openvg/qpaintengine_vg.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/openvg/qpaintengine_vg.cpp b/src/openvg/qpaintengine_vg.cpp
index c7fe604..8ce3f69 100644
--- a/src/openvg/qpaintengine_vg.cpp
+++ b/src/openvg/qpaintengine_vg.cpp
@@ -1656,10 +1656,10 @@ void QVGPaintEngine::clip(const QRegion &region, Qt::ClipOperation op)
clip = r;
else
clip = clip.intersect(r);
- if (r.numRects() == 1) {
+ if (clip.numRects() == 1) {
d->maskValid = false;
d->maskIsSet = false;
- d->maskRect = r.boundingRect();
+ d->maskRect = clip.boundingRect();
vgSeti(VG_MASKING, VG_FALSE);
updateScissor();
} else {