summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qpainterpath.cpp
diff options
context:
space:
mode:
authorSamuel Rødal <sroedal@trolltech.com>2010-04-22 07:58:03 (GMT)
committerSamuel Rødal <sroedal@trolltech.com>2010-04-22 09:28:56 (GMT)
commitf7d61dab69308f0993c8a5f2232226d1713ac4a7 (patch)
tree82d85d2353030719ee078b1f0ae9d4e0ad34366d /src/gui/painting/qpainterpath.cpp
parent7dc1d86ef4fd365483dec83b7cafff06521bf8eb (diff)
downloadQt-f7d61dab69308f0993c8a5f2232226d1713ac4a7.zip
Qt-f7d61dab69308f0993c8a5f2232226d1713ac4a7.tar.gz
Qt-f7d61dab69308f0993c8a5f2232226d1713ac4a7.tar.bz2
Removed bezier intersection code in path clipper.
The bezier intersections caused a lot of numerical stability issues, so instead we now convert them to line segments. In the future it might be possible to keep track of which bezier curve a line segment originated from and reconstruct the bezier curves at the end. Task-number: QTBUG-8035 Reviewed-by: Gunnar Sletta
Diffstat (limited to 'src/gui/painting/qpainterpath.cpp')
-rw-r--r--src/gui/painting/qpainterpath.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/gui/painting/qpainterpath.cpp b/src/gui/painting/qpainterpath.cpp
index 965b84c..f5a698e 100644
--- a/src/gui/painting/qpainterpath.cpp
+++ b/src/gui/painting/qpainterpath.cpp
@@ -3167,6 +3167,8 @@ void QPainterPath::addRoundRect(const QRectF &r, int xRnd, int yRnd)
Set operations on paths will treat the paths as areas. Non-closed
paths will be treated as implicitly closed.
+ Bezier curves may be flattened to line segments due to numerical instability of
+ doing bezier curve intersections.
\sa intersected(), subtracted()
*/
@@ -3182,6 +3184,8 @@ QPainterPath QPainterPath::united(const QPainterPath &p) const
\since 4.3
Returns a path which is the intersection of this path's fill area and \a p's fill area.
+ Bezier curves may be flattened to line segments due to numerical instability of
+ doing bezier curve intersections.
*/
QPainterPath QPainterPath::intersected(const QPainterPath &p) const
{
@@ -3198,7 +3202,8 @@ QPainterPath QPainterPath::intersected(const QPainterPath &p) const
Set operations on paths will treat the paths as areas. Non-closed
paths will be treated as implicitly closed.
-
+ Bezier curves may be flattened to line segments due to numerical instability of
+ doing bezier curve intersections.
*/
QPainterPath QPainterPath::subtracted(const QPainterPath &p) const
{
@@ -3227,6 +3232,8 @@ QPainterPath QPainterPath::subtractedInverted(const QPainterPath &p) const
Returns a simplified version of this path. This implies merging all subpaths that intersect,
and returning a path containing no intersecting edges. Consecutive parallel lines will also
be merged. The simplified path will always use the default fill rule, Qt::OddEvenFill.
+ Bezier curves may be flattened to line segments due to numerical instability of
+ doing bezier curve intersections.
*/
QPainterPath QPainterPath::simplified() const
{