127 inv.m[1][2] = -matrixDet2(m, 0, 1, 0, 2) * det;
129 inv.m[2][0] = matrixDet2(m, 1, 2, 0, 1) * det;
130 inv.m[2][1] = -matrixDet2(m, 0, 2, 0, 1) * det;
131 inv.m[2][2] = matrixDet2(m, 0, 1, 0, 1) * det;
133 inv.m[3][0] = -inv.m[0][0] * m[3][0] - inv.m[1][0] * m[3][1] - inv.m[2][0] * m[3][2];
134 inv.m[3][1] = -inv.m[0][1] * m[3][0] - inv.m[1][1] * m[3][1] - inv.m[2][1] * m[3][2];
135 inv.m[3][2] = -inv.m[0][2] * m[3][0] - inv.m[1][2] * m[3][1] - inv.m[2][2] * m[3][2];
137 inv.flagBits = flagBits;
144 QDoubleMatrix4x4 inv(1);
146 double det = matrixDet4(m);
150 return QDoubleMatrix4x4();
154 inv.m[0][0] = matrixDet3(m, 1, 2, 3, 1, 2, 3) * det;
155 inv.m[0][1] = -matrixDet3(m, 0, 2, 3, 1, 2, 3) * det;
156 inv.m[0][2] = matrixDet3(m, 0, 1, 3, 1, 2, 3) * det;
157 inv.m[0][3] = -matrixDet3(m, 0, 1, 2, 1, 2, 3) * det;
158 inv.m[1][0] = -matrixDet3(m, 1, 2, 3, 0, 2, 3) * det;
159 inv.m[1][1] = matrixDet3(m, 0, 2, 3, 0, 2, 3) * det;
160 inv.m[1][2] = -matrixDet3(m, 0, 1, 3, 0, 2, 3) * det;
161 inv.m[1][3] = matrixDet3(m, 0, 1, 2, 0, 2, 3) * det;
162 inv.m[2][0] = matrixDet3(m, 1, 2, 3, 0, 1, 3) * det;
163 inv.m[2][1] = -matrixDet3(m, 0, 2, 3, 0, 1, 3) * det;
164 inv.m[2][2] = matrixDet3(m, 0, 1, 3, 0, 1, 3) * det;
165 inv.m[2][3] = -matrixDet3(m, 0, 1, 2, 0, 1, 3) * det;
166 inv.m[3][0] = -matrixDet3(m, 1, 2, 3, 0, 1, 2) * det;
167 inv.m[3][1] = matrixDet3(m, 0, 2, 3, 0, 1, 2) * det;
168 inv.m[3][2] = -matrixDet3(m, 0, 1, 3, 0, 1, 2) * det;
169 inv.m[3][3] = matrixDet3(m, 0, 1, 2, 0, 1, 2) * det;
170 inv.flagBits = flagBits;
177QDoubleMatrix4x4 QDoubleMatrix4x4::transposed()
const
179 QDoubleMatrix4x4 result(1);
180 for (
int row = 0; row < 4; ++row) {
181 for (
int col = 0; col < 4; ++col) {
182 result.m[col][row] = m[row][col];
186 result.flagBits = (flagBits & Translation ? General : flagBits);
190QDoubleMatrix4x4& QDoubleMatrix4x4::operator/=(
double divisor)
215 m.m[0][0] = matrix.m[0][0] / divisor;
216 m.m[0][1] = matrix.m[0][1] / divisor;
217 m.m[0][2] = matrix.m[0][2] / divisor;
218 m.m[0][3] = matrix.m[0][3] / divisor;
219 m.m[1][0] = matrix.m[1][0] / divisor;
220 m.m[1][1] = matrix.m[1][1] / divisor;
221 m.m[1][2] = matrix.m[1][2] / divisor;
222 m.m[1][3] = matrix.m[1][3] / divisor;
223 m.m[2][0] = matrix.m[2][0] / divisor;
224 m.m[2][1] = matrix.m[2][1] / divisor;
225 m.m[2][2] = matrix.m[2][2] / divisor;
226 m.m[2][3] = matrix.m[2][3] / divisor;
227 m.m[3][0] = matrix.m[3][0] / divisor;
228 m.m[3][1] = matrix.m[3][1] / divisor;
229 m.m[3][2] = matrix.m[3][2] / divisor;
230 m.m[3][3] = matrix.m[3][3] / divisor;
231 m.flagBits = QDoubleMatrix4x4::General;
235void QDoubleMatrix4x4::scale(
const QDoubleVector3D& vector)
237 double vx = vector.x();
238 double vy = vector.y();
239 double vz = vector.z();
240 if (flagBits < Scale) {
244 }
else if (flagBits < Rotation2D) {
248 }
else if (flagBits < Rotation) {
271void QDoubleMatrix4x4::scale(
double x,
double y)
273 if (flagBits < Scale) {
276 }
else if (flagBits < Rotation2D) {
279 }
else if (flagBits < Rotation) {
297void QDoubleMatrix4x4::scale(
double x,
double y,
double z)
299 if (flagBits < Scale) {
303 }
else if (flagBits < Rotation2D) {
307 }
else if (flagBits < Rotation) {
330void QDoubleMatrix4x4::scale(
double factor)
332 if (flagBits < Scale) {
336 }
else if (flagBits < Rotation2D) {
340 }
else if (flagBits < Rotation) {
363void QDoubleMatrix4x4::translate(
const QDoubleVector3D& vector)
365 double vx = vector.x();
366 double vy = vector.y();
367 double vz = vector.z();
368 if (flagBits == Identity) {
372 }
else if (flagBits == Translation) {
376 }
else if (flagBits == Scale) {
377 m[3][0] = m[0][0] * vx;
378 m[3][1] = m[1][1] * vy;
379 m[3][2] = m[2][2] * vz;
380 }
else if (flagBits == (Translation | Scale)) {
381 m[3][0] += m[0][0] * vx;
382 m[3][1] += m[1][1] * vy;
383 m[3][2] += m[2][2] * vz;
384 }
else if (flagBits < Rotation) {
385 m[3][0] += m[0][0] * vx + m[1][0] * vy;
386 m[3][1] += m[0][1] * vx + m[1][1] * vy;
387 m[3][2] += m[2][2] * vz;
389 m[3][0] += m[0][0] * vx + m[1][0] * vy + m[2][0] * vz;
390 m[3][1] += m[0][1] * vx + m[1][1] * vy + m[2][1] * vz;
391 m[3][2] += m[0][2] * vx + m[1][2] * vy + m[2][2] * vz;
392 m[3][3] += m[0][3] * vx + m[1][3] * vy + m[2][3] * vz;
394 flagBits |= Translation;
397void QDoubleMatrix4x4::translate(
double x,
double y)
399 if (flagBits == Identity) {
402 }
else if (flagBits == Translation) {
405 }
else if (flagBits == Scale) {
406 m[3][0] = m[0][0] * x;
407 m[3][1] = m[1][1] * y;
408 }
else if (flagBits == (Translation | Scale)) {
409 m[3][0] += m[0][0] * x;
410 m[3][1] += m[1][1] * y;
411 }
else if (flagBits < Rotation) {
412 m[3][0] += m[0][0] * x + m[1][0] * y;
413 m[3][1] += m[0][1] * x + m[1][1] * y;
415 m[3][0] += m[0][0] * x + m[1][0] * y;
416 m[3][1] += m[0][1] * x + m[1][1] * y;
417 m[3][2] += m[0][2] * x + m[1][2] * y;
418 m[3][3] += m[0][3] * x + m[1][3] * y;
420 flagBits |= Translation;
423void QDoubleMatrix4x4::translate(
double x,
double y,
double z)
425 if (flagBits == Identity) {
429 }
else if (flagBits == Translation) {
433 }
else if (flagBits == Scale) {
434 m[3][0] = m[0][0] * x;
435 m[3][1] = m[1][1] * y;
436 m[3][2] = m[2][2] * z;
437 }
else if (flagBits == (Translation | Scale)) {
438 m[3][0] += m[0][0] * x;
439 m[3][1] += m[1][1] * y;
440 m[3][2] += m[2][2] * z;
441 }
else if (flagBits < Rotation) {
442 m[3][0] += m[0][0] * x + m[1][0] * y;
443 m[3][1] += m[0][1] * x + m[1][1] * y;
444 m[3][2] += m[2][2] * z;
446 m[3][0] += m[0][0] * x + m[1][0] * y + m[2][0] * z;
447 m[3][1] += m[0][1] * x + m[1][1] * y + m[2][1] * z;
448 m[3][2] += m[0][2] * x + m[1][2] * y + m[2][2] * z;
449 m[3][3] += m[0][3] * x + m[1][3] * y + m[2][3] * z;
451 flagBits |= Translation;
454void QDoubleMatrix4x4::rotate(
double angle,
const QDoubleVector3D& vector)
456 rotate(angle, vector.x(), vector.y(), vector.z());
459void QDoubleMatrix4x4::rotate(
double angle,
double x,
double y,
double z)
464 if (angle == 90.0 || angle == -270.0) {
467 }
else if (angle == -90.0 || angle == 270.0) {
470 }
else if (angle == 180.0 || angle == -180.0) {
474 double a = qDegreesToRadians(angle);
485 m[0][0] = (tmp = m[0][0]) * c + m[1][0] * s;
486 m[1][0] = m[1][0] * c - tmp * s;
487 m[0][1] = (tmp = m[0][1]) * c + m[1][1] * s;
488 m[1][1] = m[1][1] * c - tmp * s;
489 m[0][2] = (tmp = m[0][2]) * c + m[1][2] * s;
490 m[1][2] = m[1][2] * c - tmp * s;
491 m[0][3] = (tmp = m[0][3]) * c + m[1][3] * s;
492 m[1][3] = m[1][3] * c - tmp * s;
494 flagBits |= Rotation2D;
497 }
else if (z == 0.0) {
502 m[2][0] = (tmp = m[2][0]) * c + m[0][0] * s;
503 m[0][0] = m[0][0] * c - tmp * s;
504 m[2][1] = (tmp = m[2][1]) * c + m[0][1] * s;
505 m[0][1] = m[0][1] * c - tmp * s;
506 m[2][2] = (tmp = m[2][2]) * c + m[0][2] * s;
507 m[0][2] = m[0][2] * c - tmp * s;
508 m[2][3] = (tmp = m[2][3]) * c + m[0][3] * s;
509 m[0][3] = m[0][3] * c - tmp * s;
511 flagBits |= Rotation;
514 }
else if (y == 0.0 && z == 0.0) {
519 m[1][0] = (tmp = m[1][0]) * c + m[2][0] * s;
520 m[2][0] = m[2][0] * c - tmp * s;
521 m[1][1] = (tmp = m[1][1]) * c + m[2][1] * s;
522 m[2][1] = m[2][1] * c - tmp * s;
523 m[1][2] = (tmp = m[1][2]) * c + m[2][2] * s;
524 m[2][2] = m[2][2] * c - tmp * s;
525 m[1][3] = (tmp = m[1][3]) * c + m[2][3] * s;
526 m[2][3] = m[2][3] * c - tmp * s;
528 flagBits |= Rotation;
532 if (
double len = qHypot(x, y, z);
533 !qFuzzyIsNull(len) && !qFuzzyCompare(len, 1.0)) {
539 QDoubleMatrix4x4 rot(1);
540 rot.m[0][0] = x * x * ic + c;
541 rot.m[1][0] = x * y * ic - z * s;
542 rot.m[2][0] = x * z * ic + y * s;
544 rot.m[0][1] = y * x * ic + z * s;
545 rot.m[1][1] = y * y * ic + c;
546 rot.m[2][1] = y * z * ic - x * s;
548 rot.m[0][2] = x * z * ic - y * s;
549 rot.m[1][2] = y * z * ic + x * s;
550 rot.m[2][2] = z * z * ic + c;
556 rot.flagBits = Rotation;
560void QDoubleMatrix4x4::projectedRotate(
double angle,
double x,
double y,
double z,
561 double distanceToPlane)
565 if (qIsNull(distanceToPlane))
566 return rotate(angle, x, y, z);
570 if (angle == 90.0 || angle == -270.0) {
573 }
else if (angle == -90.0 || angle == 270.0) {
576 }
else if (angle == 180.0 || angle == -180.0) {
580 double a = qDegreesToRadians(angle);
585 const double d = 1.0 / distanceToPlane;
593 m[0][0] = (tmp = m[0][0]) * c + m[1][0] * s;
594 m[1][0] = m[1][0] * c - tmp * s;
595 m[0][1] = (tmp = m[0][1]) * c + m[1][1] * s;
596 m[1][1] = m[1][1] * c - tmp * s;
597 m[0][2] = (tmp = m[0][2]) * c + m[1][2] * s;
598 m[1][2] = m[1][2] * c - tmp * s;
599 m[0][3] = (tmp = m[0][3]) * c + m[1][3] * s;
600 m[1][3] = m[1][3] * c - tmp * s;
602 flagBits |= Rotation2D;
605 }
else if (z == 0.0) {
610 m[0][0] = m[0][0] * c + m[3][0] * s;
611 m[0][1] = m[0][1] * c + m[3][1] * s;
612 m[0][2] = m[0][2] * c + m[3][2] * s;
613 m[0][3] = m[0][3] * c + m[3][3] * s;
617 }
else if (y == 0.0 && z == 0.0) {
622 m[1][0] = m[1][0] * c - m[3][0] * s;
623 m[1][1] = m[1][1] * c - m[3][1] * s;
624 m[1][2] = m[1][2] * c - m[3][2] * s;
625 m[1][3] = m[1][3] * c - m[3][3] * s;
630 if (
const double len = qHypot(x, y, z);
631 !qFuzzyIsNull(len) && !qFuzzyCompare(len, 1.0)) {
637 QDoubleMatrix4x4 rot(1);
638 rot.m[0][0] = x * x * ic + c;
639 rot.m[1][0] = x * y * ic - z * s;
642 rot.m[0][1] = y * x * ic + z * s;
643 rot.m[1][1] = y * y * ic + c;
650 rot.m[0][3] = (x * z * ic - y * s) * -d;
651 rot.m[1][3] = (y * z * ic + x * s) * -d;
654 rot.flagBits = General;
658void QDoubleMatrix4x4::ortho(
const QRect& rect)
664 ortho(rect.x(), rect.x() + rect.width(), rect.y() + rect.height(), rect.y(), -1.0, 1.0);
667void QDoubleMatrix4x4::ortho(
const QRectF& rect)
669 ortho(rect.left(), rect.right(), rect.bottom(), rect.top(), -1.0, 1.0);
672void QDoubleMatrix4x4::ortho(
double left,
double right,
double bottom,
double top,
double nearPlane,
double farPlane)
675 if (left == right || bottom == top || nearPlane == farPlane)
679 double width = right - left;
680 double invheight = top - bottom;
681 double clip = farPlane - nearPlane;
682 QDoubleMatrix4x4 m(1);
683 m.m[0][0] = 2.0 / width;
686 m.m[3][0] = -(left + right) / width;
688 m.m[1][1] = 2.0 / invheight;
690 m.m[3][1] = -(top + bottom) / invheight;
693 m.m[2][2] = -2.0 / clip;
694 m.m[3][2] = -(nearPlane + farPlane) / clip;
699 m.flagBits = Translation | Scale;
705void QDoubleMatrix4x4::frustum(
double left,
double right,
double bottom,
double top,
double nearPlane,
double farPlane)
708 if (left == right || bottom == top || nearPlane == farPlane)
712 QDoubleMatrix4x4 m(1);
713 double width = right - left;
714 double invheight = top - bottom;
715 double clip = farPlane - nearPlane;
716 m.m[0][0] = 2.0 * nearPlane / width;
718 m.m[2][0] = (left + right) / width;
721 m.m[1][1] = 2.0 * nearPlane / invheight;
722 m.m[2][1] = (top + bottom) / invheight;
726 m.m[2][2] = -(nearPlane + farPlane) / clip;
727 m.m[3][2] = -2.0 * nearPlane * farPlane / clip;
732 m.flagBits = General;
738void QDoubleMatrix4x4::perspective(
double verticalAngle,
double aspectRatio,
double nearPlane,
double farPlane)
741 if (nearPlane == farPlane || aspectRatio == 0.0)
745 QDoubleMatrix4x4 m(1);
746 double radians = qDegreesToRadians(verticalAngle / 2.0);
747 double sine = std::sin(radians);
750 double cotan = std::cos(radians) / sine;
751 double clip = farPlane - nearPlane;
752 m.m[0][0] = cotan / aspectRatio;
762 m.m[2][2] = -(nearPlane + farPlane) / clip;
763 m.m[3][2] = -(2.0 * nearPlane * farPlane) / clip;
768 m.flagBits = General;
774void QDoubleMatrix4x4::lookAt(
const QDoubleVector3D& eye,
const QDoubleVector3D& center,
const QDoubleVector3D& up)
776 QDoubleVector3D forward = center - eye;
777 if (qFuzzyIsNull(forward.x()) && qFuzzyIsNull(forward.y()) && qFuzzyIsNull(forward.z()))
781 QDoubleVector3D side = QDoubleVector3D::crossProduct(forward, up).normalized();
782 QDoubleVector3D upVector = QDoubleVector3D::crossProduct(side, forward);
784 QDoubleMatrix4x4 m(1);
785 m.m[0][0] = side.x();
786 m.m[1][0] = side.y();
787 m.m[2][0] = side.z();
789 m.m[0][1] = upVector.x();
790 m.m[1][1] = upVector.y();
791 m.m[2][1] = upVector.z();
793 m.m[0][2] = -forward.x();
794 m.m[1][2] = -forward.y();
795 m.m[2][2] = -forward.z();
801 m.flagBits = Rotation;
807void QDoubleMatrix4x4::viewport(
double left,
double bottom,
double width,
double height,
double nearPlane,
double farPlane)
809 const double w2 = width / 2.0;
810 const double h2 = height / 2.0;
812 QDoubleMatrix4x4 m(1);
816 m.m[3][0] = left + w2;
820 m.m[3][1] = bottom + h2;
823 m.m[2][2] = (farPlane - nearPlane) / 2.0;
824 m.m[3][2] = (nearPlane + farPlane) / 2.0;
829 m.flagBits = General;
834void QDoubleMatrix4x4::flipCoordinates()
839 if (flagBits < Rotation2D) {
856void QDoubleMatrix4x4::copyDataTo(
double *values)
const
858 for (
int row = 0; row < 4; ++row)
859 for (
int col = 0; col < 4; ++col)
860 values[row * 4 + col] =
double(m[col][row]);
863QRect QDoubleMatrix4x4::mapRect(
const QRect& rect)
const
865 if (flagBits < Scale) {
867 return QRect(qRound(rect.x() + m[3][0]),
868 qRound(rect.y() + m[3][1]),
869 rect.width(), rect.height());
870 }
else if (flagBits < Rotation2D) {
872 double x = rect.x() * m[0][0] + m[3][0];
873 double y = rect.y() * m[1][1] + m[3][1];
874 double w = rect.width() * m[0][0];
875 double h = rect.height() * m[1][1];
884 return QRect(qRound(x), qRound(y), qRound(w), qRound(h));
887 QPoint tl = map(rect.topLeft());
888 QPoint tr = map(QPoint(rect.x() + rect.width(), rect.y()));
889 QPoint bl = map(QPoint(rect.x(), rect.y() + rect.height()));
890 QPoint br = map(QPoint(rect.x() + rect.width(),
891 rect.y() + rect.height()));
893 int xmin = qMin(qMin(tl.x(), tr.x()), qMin(bl.x(), br.x()));
894 int xmax = qMax(qMax(tl.x(), tr.x()), qMax(bl.x(), br.x()));
895 int ymin = qMin(qMin(tl.y(), tr.y()), qMin(bl.y(), br.y()));
896 int ymax = qMax(qMax(tl.y(), tr.y()), qMax(bl.y(), br.y()));
898 return QRect(xmin, ymin, xmax - xmin, ymax - ymin);
901QRectF QDoubleMatrix4x4::mapRect(
const QRectF& rect)
const
903 if (flagBits < Scale) {
905 return rect.translated(m[3][0], m[3][1]);
906 }
else if (flagBits < Rotation2D) {
908 double x = rect.x() * m[0][0] + m[3][0];
909 double y = rect.y() * m[1][1] + m[3][1];
910 double w = rect.width() * m[0][0];
911 double h = rect.height() * m[1][1];
920 return QRectF(x, y, w, h);
923 QPointF tl = map(rect.topLeft()); QPointF tr = map(rect.topRight());
924 QPointF bl = map(rect.bottomLeft()); QPointF br = map(rect.bottomRight());
926 double xmin = qMin(qMin(tl.x(), tr.x()), qMin(bl.x(), br.x()));
927 double xmax = qMax(qMax(tl.x(), tr.x()), qMax(bl.x(), br.x()));
928 double ymin = qMin(qMin(tl.y(), tr.y()), qMin(bl.y(), br.y()));
929 double ymax = qMax(qMax(tl.y(), tr.y()), qMax(bl.y(), br.y()));
931 return QRectF(QPointF(xmin, ymin), QPointF(xmax, ymax));
934QDoubleMatrix4x4 QDoubleMatrix4x4::orthonormalInverse()
const
936 QDoubleMatrix4x4 result(1);
938 result.m[0][0] = m[0][0];
939 result.m[1][0] = m[0][1];
940 result.m[2][0] = m[0][2];
942 result.m[0][1] = m[1][0];
943 result.m[1][1] = m[1][1];
944 result.m[2][1] = m[1][2];
946 result.m[0][2] = m[2][0];
947 result.m[1][2] = m[2][1];
948 result.m[2][2] = m[2][2];
950 result.m[0][3] = 0.0;
951 result.m[1][3] = 0.0;
952 result.m[2][3] = 0.0;
954 result.m[3][0] = -(result.m[0][0] * m[3][0] + result.m[1][0] * m[3][1] + result.m[2][0] * m[3][2]);
955 result.m[3][1] = -(result.m[0][1] * m[3][0] + result.m[1][1] * m[3][1] + result.m[2][1] * m[3][2]);
956 result.m[3][2] = -(result.m[0][2] * m[3][0] + result.m[1][2] * m[3][1] + result.m[2][2] * m[3][2]);
957 result.m[3][3] = 1.0;
959 result.flagBits = flagBits;
964void QDoubleMatrix4x4::optimize()
968 if (m[0][3] != 0 || m[1][3] != 0 || m[2][3] != 0 || m[3][3] != 1)
971 flagBits &= ~Perspective;
974 if (m[3][0] == 0 && m[3][1] == 0 && m[3][2] == 0)
975 flagBits &= ~Translation;
978 if (!m[0][2] && !m[1][2] && !m[2][0] && !m[2][1]) {
979 flagBits &= ~Rotation;
981 if (!m[0][1] && !m[1][0]) {
982 flagBits &= ~Rotation2D;
984 if (m[0][0] == 1 && m[1][1] == 1 && m[2][2] == 1)
988 double det = matrixDet2(m, 0, 1, 0, 1);
989 double lenX = m[0][0] * m[0][0] + m[0][1] * m[0][1];
990 double lenY = m[1][0] * m[1][0] + m[1][1] * m[1][1];
991 double lenZ = m[2][2];
992 if (qFuzzyCompare(det, 1.0) && qFuzzyCompare(lenX, 1.0)
993 && qFuzzyCompare(lenY, 1.0) && qFuzzyCompare(lenZ, 1.0))
1000 double det = matrixDet3(m, 0, 1, 2, 0, 1, 2);
1001 double lenX = m[0][0] * m[0][0] + m[0][1] * m[0][1] + m[0][2] * m[0][2];
1002 double lenY = m[1][0] * m[1][0] + m[1][1] * m[1][1] + m[1][2] * m[1][2];
1003 double lenZ = m[2][0] * m[2][0] + m[2][1] * m[2][1] + m[2][2] * m[2][2];
1004 if (qFuzzyCompare(det, 1.0) && qFuzzyCompare(lenX, 1.0)
1005 && qFuzzyCompare(lenY, 1.0) && qFuzzyCompare(lenZ, 1.0))
1012#ifndef QT_NO_DEBUG_STREAM
1016 QDebugStateSaver saver(dbg);
1019 if (m.flagBits == QDoubleMatrix4x4::Identity) {
1021 }
else if (m.flagBits == QDoubleMatrix4x4::General) {
1024 if ((m.flagBits & QDoubleMatrix4x4::Translation) != 0)
1025 bits +=
"Translation,";
1026 if ((m.flagBits & QDoubleMatrix4x4::Scale) != 0)
1028 if ((m.flagBits & QDoubleMatrix4x4::Rotation2D) != 0)
1029 bits +=
"Rotation2D,";
1030 if ((m.flagBits & QDoubleMatrix4x4::Rotation) != 0)
1031 bits +=
"Rotation,";
1032 if ((m.flagBits & QDoubleMatrix4x4::Perspective) != 0)
1033 bits +=
"Perspective,";
1034 if (!bits.isEmpty())
1035 bits = bits.left(bits.size() - 1);
1039 dbg.nospace() <<
"QDoubleMatrix4x4(type:" << bits.constData() << Qt::endl
1040 << qSetFieldWidth(10)
1041 << m(0, 0) << m(0, 1) << m(0, 2) << m(0, 3) << Qt::endl
1042 << m(1, 0) << m(1, 1) << m(1, 2) << m(1, 3) << Qt::endl
1043 << m(2, 0) << m(2, 1) << m(2, 2) << m(2, 3) << Qt::endl
1044 << m(3, 0) << m(3, 1) << m(3, 2) << m(3, 3) << Qt::endl
1045 << qSetFieldWidth(0) <<
')';