summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qpaintengine_d3d.cpp
diff options
context:
space:
mode:
authormae <qt-info@nokia.com>2009-04-09 10:23:05 (GMT)
committermae <qt-info@nokia.com>2009-04-09 10:23:05 (GMT)
commit7f0b685d8cc56bece74585af8e74454185dc785a (patch)
tree52bd5e544a63f190a50358b0a491c0ec8a164d80 /src/gui/painting/qpaintengine_d3d.cpp
parentf3ee66750d279fb3d44cd13307312b703c77172f (diff)
parent8da880e77db04cc4509e0f48e0b5b1d6265da223 (diff)
downloadQt-7f0b685d8cc56bece74585af8e74454185dc785a.zip
Qt-7f0b685d8cc56bece74585af8e74454185dc785a.tar.gz
Qt-7f0b685d8cc56bece74585af8e74454185dc785a.tar.bz2
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt
Diffstat (limited to 'src/gui/painting/qpaintengine_d3d.cpp')
-rw-r--r--src/gui/painting/qpaintengine_d3d.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/painting/qpaintengine_d3d.cpp b/src/gui/painting/qpaintengine_d3d.cpp
index bb81623..9a7638b 100644
--- a/src/gui/painting/qpaintengine_d3d.cpp
+++ b/src/gui/painting/qpaintengine_d3d.cpp
@@ -2506,8 +2506,8 @@ void QD3DDrawHelper::addTrap(const Trapezoid &trap)
qreal _rightA = (qreal)_w/_h;
qreal _rightB = topRightX - _rightA * topRightY;
- qreal invLeftA = qFuzzyCompare(_leftA + 1, 1) ? 0.0 : 1.0 / _leftA;
- qreal invRightA = qFuzzyCompare(_rightA + 1, 1) ? 0.0 : 1.0 / _rightA;
+ qreal invLeftA = qFuzzyIsNull(_leftA) ? 0.0 : 1.0 / _leftA;
+ qreal invRightA = qFuzzyIsNull(_rightA) ? 0.0 : 1.0 / _rightA;
vertex v1 = { {1.f, top - 1.f, 0.5f}, 0.f,
top, bottom, invLeftA, -invRightA,
@@ -2970,7 +2970,7 @@ qreal calculateAngle(qreal dx, qreal dy)
{
qreal angle;
- if (qFuzzyCompare(dx + 1, 1)) {
+ if (qFuzzyIsNull(dx)) {
angle = (dy < 0) ? -M_PI/2 : M_PI/2;
} else {
angle = atanf(dy/dx);