QMatrix4x4 Class

The QMatrix4x4 class represents a 4x4 transformation matrix in 3D space. More...

Header: #include <QMatrix4x4>
qmake: QT += gui
Since: Qt 4.6

This class was introduced in Qt 4.6.

Detailed Description

The QMatrix4x4 class in general is treated as a row-major matrix, in that the constructors and operator() functions take data in row-major format, as is familiar in C-style usage.

Internally the data is stored as column-major format, so as to be optimal for passing to OpenGL functions, which expect column-major data.

When using these functions be aware that they return data in column-major format:

  • data()
  • constData()

See also QVector3D and QGenericMatrix.