Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qopenvgmatrix.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QOPENVGMATRIX_H
5#define QOPENVGMATRIX_H
6
7#include <QtCore/qdebug.h>
8#include <QtCore/QDataStream>
9#include <QtCore/QPointF>
10
12
14{
15public:
17 explicit QOpenVGMatrix(const float *values);
18
19 const float& operator()(int row, int column) const;
20 float& operator()(int row, int column);
21
22 bool isIdentity() const;
23 void setToIdentity();
24
25 bool isAffine() const;
26
27 QPointF map(const QPointF& point) const;
28
29 void fill(float value);
30
32
36 QOpenVGMatrix& operator*=(float factor);
38 friend QOpenVGMatrix operator*(const QOpenVGMatrix& m1, const QOpenVGMatrix& m2);
39 friend QPointF operator*(const QPointF& point, const QOpenVGMatrix& matrix);
40 friend QPointF operator*(const QOpenVGMatrix& matrix, const QPointF& point);
41#ifndef QT_NO_DEBUG_STREAM
42 friend QDebug operator<<(QDebug dbg, const QOpenVGMatrix &m);
43#endif
44 bool operator==(const QOpenVGMatrix& other) const;
45 bool operator!=(const QOpenVGMatrix& other) const;
46
47 void copyDataTo(float *values) const;
48
49 float *data() { return *m; }
50 const float *data() const { return *m; }
51 const float *constData() const { return *m; }
52
53private:
54 float m[3][3];
55};
56
58QPointF operator*(const QPointF& point, const QOpenVGMatrix& matrix);
59QPointF operator*(const QOpenVGMatrix& matrix, const QPointF& point);
60
61#ifndef QT_NO_DEBUG_STREAM
63#endif
64
65#ifndef QT_NO_DATASTREAM
68#endif
69
71
72#endif // QOPENVGMATRIX_H
\inmodule QtCore\reentrant
Definition qdatastream.h:46
\inmodule QtCore
QOpenVGMatrix & operator*=(const QOpenVGMatrix &other)
QOpenVGMatrix & operator-=(const QOpenVGMatrix &other)
float * data()
const float & operator()(int row, int column) const
const float * constData() const
void fill(float value)
friend QOpenVGMatrix operator*(const QOpenVGMatrix &m1, const QOpenVGMatrix &m2)
QOpenVGMatrix transposed() const
bool operator!=(const QOpenVGMatrix &other) const
friend QDebug operator<<(QDebug dbg, const QOpenVGMatrix &m)
QOpenVGMatrix & operator+=(const QOpenVGMatrix &other)
bool isIdentity() const
bool isAffine() const
QOpenVGMatrix & operator/=(float divisor)
void copyDataTo(float *values) const
bool operator==(const QOpenVGMatrix &other) const
const float * data() const
\inmodule QtCore\reentrant
Definition qpoint.h:217
QMap< QString, QString > map
[6]
Combined button and popup list for selecting options.
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
GLenum GLsizei GLsizei GLint * values
[15]
const GLfloat * m
GLuint divisor
GLenum GLenum GLsizei void GLsizei void * column
GLuint GLenum matrix
GLenum GLenum GLsizei void * row
QDataStream & operator>>(QDataStream &, QOpenVGMatrix &)
QOpenVGMatrix operator*(const QOpenVGMatrix &m1, const QOpenVGMatrix &m2)
QDebug operator<<(QDebug dbg, const QOpenVGMatrix &m)
QSharedPointer< T > other(t)
[5]