summaryrefslogtreecommitdiffstats
path: root/src/gui/math3d/qmatrix4x4.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/math3d/qmatrix4x4.h')
-rw-r--r--src/gui/math3d/qmatrix4x4.h19
1 files changed, 4 insertions, 15 deletions
diff --git a/src/gui/math3d/qmatrix4x4.h b/src/gui/math3d/qmatrix4x4.h
index 2b485c1..79613a0 100644
--- a/src/gui/math3d/qmatrix4x4.h
+++ b/src/gui/math3d/qmatrix4x4.h
@@ -130,9 +130,11 @@ public:
QMatrix4x4& translate(const QVector3D& vector);
QMatrix4x4& rotate(qreal angle, const QVector3D& vector);
#endif
- QMatrix4x4& scale(qreal x, qreal y, qreal z = 1.0f);
+ QMatrix4x4& scale(qreal x, qreal y);
+ QMatrix4x4& scale(qreal x, qreal y, qreal z);
QMatrix4x4& scale(qreal factor);
- QMatrix4x4& translate(qreal x, qreal y, qreal z = 0.0f);
+ QMatrix4x4& translate(qreal x, qreal y);
+ QMatrix4x4& translate(qreal x, qreal y, qreal z);
QMatrix4x4& rotate(qreal angle, qreal x, qreal y, qreal z = 0.0f);
#ifndef QT_NO_QUATERNION
QMatrix4x4& rotate(const QQuaternion& quaternion);
@@ -914,19 +916,6 @@ inline QRect QMatrix4x4::mapRect(const QRect& rect) const
return QRect(QPoint(xmin, ymin), QPoint(xmax, ymax));
}
-inline QRectF QMatrix4x4::mapRect(const QRectF& rect) const
-{
- QPointF tl = map(rect.topLeft()); QPointF tr = map(rect.topRight());
- QPointF bl = map(rect.bottomLeft()); QPointF br = map(rect.bottomRight());
-
- qreal xmin = qMin(qMin(tl.x(), tr.x()), qMin(bl.x(), br.x()));
- qreal xmax = qMax(qMax(tl.x(), tr.x()), qMax(bl.x(), br.x()));
- qreal ymin = qMin(qMin(tl.y(), tr.y()), qMin(bl.y(), br.y()));
- qreal ymax = qMax(qMax(tl.y(), tr.y()), qMax(bl.y(), br.y()));
-
- return QRectF(QPointF(xmin, ymin), QPointF(xmax, ymax));
-}
-
inline float *QMatrix4x4::data()
{
// We have to assume that the caller will modify the matrix elements,