QVector3D Class Reference
#include <qvector3d.h>
Definition at line 60 of file qvector3d.h.
|
class | QVector2D |
|
class | QVector4D |
|
bool | operator== (const QVector3D &v1, const QVector3D &v2) |
|
bool | operator!= (const QVector3D &v1, const QVector3D &v2) |
|
const QVector3D | operator+ (const QVector3D &v1, const QVector3D &v2) |
|
const QVector3D | operator- (const QVector3D &v1, const QVector3D &v2) |
|
const QVector3D | operator* (qreal factor, const QVector3D &vector) |
|
const QVector3D | operator* (const QVector3D &vector, qreal factor) |
|
const QVector3D | operator* (const QVector3D &v1, const QVector3D &v2) |
|
const QVector3D | operator- (const QVector3D &vector) |
|
const QVector3D | operator/ (const QVector3D &vector, qreal divisor) |
|
bool | qFuzzyCompare (const QVector3D &v1, const QVector3D &v2) |
|
QVector3D | operator* (const QVector3D &vector, const QMatrix4x4 &matrix) |
|
QVector3D | operator* (const QMatrix4x4 &matrix, const QVector3D &vector) |
|
QVector3D |
( |
qreal |
xpos, |
|
|
qreal |
ypos, |
|
|
qreal |
zpos |
|
) |
| |
|
inline |
Definition at line 148 of file qvector3d.h.
148 : xp(xpos), yp(ypos), zp(zpos) {}
Definition at line 152 of file qvector3d.h.
152 : xp(point.
x()), yp(point.
y()), zp(0.0
f) {}
Definition at line 154 of file qvector3d.h.
154 : xp(point.
x()), yp(point.
y()), zp(0.0
f) {}
Definition at line 156 of file qvector3d.h.
158 return qIsNull(xp) && qIsNull(yp) && qIsNull(zp);
qreal lengthSquared |
( |
| ) |
const |
Definition at line 201 of file qvector3d.h.
GLXDrawable int64_t int64_t divisor
Definition at line 209 of file qvector3d.h.
211 return v1.xp == v2.xp && v1.yp == v2.yp && v1.zp == v2.zp;
Definition at line 214 of file qvector3d.h.
216 return v1.xp != v2.xp || v1.yp != v2.yp || v1.zp != v2.zp;
Definition at line 229 of file qvector3d.h.
231 return QVector3D(vector.xp * factor, vector.yp * factor, vector.zp * factor, 1);
Definition at line 234 of file qvector3d.h.
236 return QVector3D(vector.xp * factor, vector.yp * factor, vector.zp * factor, 1);
Definition at line 249 of file qvector3d.h.
GLXDrawable int64_t int64_t divisor
Definition at line 254 of file qvector3d.h.
friend bool qFuzzyCompare(const QVector3D &v1, const QVector3D &v2)
Definition at line 606 of file qmatrix4x4.h.
609 x = vector.
x() * matrix.m[0][0] +
610 vector.
y() * matrix.m[0][1] +
611 vector.
z() * matrix.m[0][2] +
613 y = vector.
x() * matrix.m[1][0] +
614 vector.
y() * matrix.m[1][1] +
615 vector.
z() * matrix.m[1][2] +
617 z = vector.
x() * matrix.m[2][0] +
618 vector.
y() * matrix.m[2][1] +
619 vector.
z() * matrix.m[2][2] +
621 w = vector.
x() * matrix.m[3][0] +
622 vector.
y() * matrix.m[3][1] +
623 vector.
z() * matrix.m[3][2] +
GLubyte GLubyte GLubyte GLubyte w
Definition at line 631 of file qmatrix4x4.h.
634 if (matrix.flagBits == QMatrix4x4::Identity) {
636 }
else if (matrix.flagBits == QMatrix4x4::Translation) {
638 vector.
y() + matrix.m[3][1],
639 vector.
z() + matrix.m[3][2]);
640 }
else if (matrix.flagBits ==
641 (QMatrix4x4::Translation | QMatrix4x4::Scale)) {
642 return QVector3D(vector.
x() * matrix.m[0][0] + matrix.m[3][0],
643 vector.
y() * matrix.m[1][1] + matrix.m[3][1],
644 vector.
z() * matrix.m[2][2] + matrix.m[3][2]);
645 }
else if (matrix.flagBits == QMatrix4x4::Scale) {
647 vector.
y() * matrix.m[1][1],
648 vector.
z() * matrix.m[2][2]);
650 x = vector.
x() * matrix.m[0][0] +
651 vector.
y() * matrix.m[1][0] +
652 vector.
z() * matrix.m[2][0] +
654 y = vector.
x() * matrix.m[0][1] +
655 vector.
y() * matrix.m[1][1] +
656 vector.
z() * matrix.m[2][1] +
658 z = vector.
x() * matrix.m[0][2] +
659 vector.
y() * matrix.m[1][2] +
660 vector.
z() * matrix.m[2][2] +
662 w = vector.
x() * matrix.m[0][3] +
663 vector.
y() * matrix.m[1][3] +
664 vector.
z() * matrix.m[2][3] +
GLubyte GLubyte GLubyte GLubyte w
The documentation for this class was generated from the following file: