From 6ef40175e50599a9c19d25cd1e2d3a658a61b494 Mon Sep 17 00:00:00 2001 From: Konstantin Ritt Date: Mon, 26 Jan 2015 11:37:45 +0400 Subject: Introduce QMatrix4x4::isAffine() - a convenience method thats checks if the matrix has no projective coefficients. Change-Id: Ieea8ac2e4237b471a683ad5010672b1e89a0c953 Reviewed-by: Sean Harmer --- src/gui/math3d/qmatrix4x4.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/gui/math3d/qmatrix4x4.cpp') diff --git a/src/gui/math3d/qmatrix4x4.cpp b/src/gui/math3d/qmatrix4x4.cpp index c8a036918c..2fa31b5b14 100644 --- a/src/gui/math3d/qmatrix4x4.cpp +++ b/src/gui/math3d/qmatrix4x4.cpp @@ -289,6 +289,18 @@ QMatrix4x4::QMatrix4x4(const QTransform& transform) \sa row(), setColumn() */ +/*! + \fn bool QMatrix4x4::isAffine() const + \since 5.5 + + Returns \c true if this matrix is affine matrix; false otherwise. + + An affine matrix is a 4x4 matrix with row 3 equal to (0, 0, 0, 1), + e.g. no projective coefficients. + + \sa isIdentity() +*/ + /*! \fn bool QMatrix4x4::isIdentity() const -- cgit v1.2.3