8#include <QtQuick3DUtils/private/qssgutils_p.h>
10#include <QtQuick3DRuntimeRender/private/qssgrendermodel_p.h>
12#include <QtQuick3DRuntimeRender/private/qssgrenderbuffermanager_p.h>
14#include <QtQuick3DUtils/private/qssgplane_p.h>
37 if (markSubtreeDirty) {
39 cld.markDirty(dirtyFlag);
87 if (globallyActive &&
parent->
type != QSSGRenderGraphObject::Type::Layer) {
112 QVector3D localPos{localInstanceMatrix[3][0], localInstanceMatrix[3][1], localInstanceMatrix[3][2]};
113 localInstanceMatrix[3][0] = 0;
114 localInstanceMatrix[3][1] = 0;
115 localInstanceMatrix[3][2] = 0;
168 if (
type != QSSGRenderNode::Type::Layer) {
196 auto &removedChild = *
it++;
198 removedChild.parent =
nullptr;
203 bool inIncludeChildren)
const
206 if (inIncludeChildren)
209 if (
type == QSSGRenderGraphObject::Type::Model) {
221 childBounds =
child.getBounds(inManager);
234 QVector3D retval(dataPtr[8], dataPtr[9], dataPtr[10]);
252 retval.
setZ(retval.
z() * -1);
The QMatrix4x4 class represents a 4x4 transformation matrix in 3D space.
QMatrix3x3 normalMatrix() const
Returns the normal matrix corresponding to this 4x4 transformation.
float * data()
Returns a pointer to the raw data of this matrix.
void translate(const QVector3D &vector)
Multiplies this matrix by another that translates coordinates by the components of vector.
The QQuaternion class represents a quaternion consisting of a vector and scalar.
QMatrix3x3 toRotationMatrix() const
Class representing 3D range or axis aligned bounding box.
void include(const QVector3D &v)
expands the volume to include v
Q_ALWAYS_INLINE bool isEmpty() const
static QSSGBounds3 transform(const QMatrix3x3 &matrix, const QSSGBounds3 &bounds)
gets the transformed bounds of the passed AABB (resulting in a bigger AABB).
QSSGBounds3 getModelBounds(const QSSGRenderModel *model) const
The QVector3D class represents a vector or vertex in 3D space.
constexpr float y() const noexcept
Returns the y coordinate of this point.
constexpr float x() const noexcept
Returns the x coordinate of this point.
constexpr void setZ(float z) noexcept
Sets the z coordinate of this point to the given finite z coordinate.
void normalize() noexcept
Normalizes the current vector in place.
constexpr float z() const noexcept
Returns the z coordinate of this point.
The QVector4D class represents a vector or vertex in 4D space.
QSet< QString >::iterator it
Combined button and popup list for selecting options.
QVector3D Q_QUICK3DUTILS_EXPORT transform(const QMatrix3x3 &m, const QVector3D &v)
QVector3D Q_QUICK3DUTILS_EXPORT getPosition(const QMatrix4x4 &m)
GLenum GLuint GLintptr offset
GLuint GLenum GLenum transform
GLenum GLenum GLenum GLenum GLenum scale
static qreal position(const QQuickItem *item, QQuickAnchors::Anchor anchorLine)
QSqlQueryModel * model
[16]
static constexpr QVector3D initScale
bool calculateGlobalVariables()
void clearDirty(DirtyFlag dirtyFlag)
QVector3D getDirection() const
QMatrix4x4 globalTransform
void addChild(QSSGRenderNode &inChild)
QVector3D getScalingCorrectDirection() const
QMatrix4x4 localInstanceTransform
static QMatrix4x4 calculateTransformMatrix(QVector3D position, QVector3D scale, QVector3D pivot, QQuaternion rotation)
QMatrix4x4 globalInstanceTransform
void setState(LocalState state, bool on=true)
QSSGBounds3 getChildBounds(QSSGBufferManager &inManager) const
std::underlying_type_t< DirtyFlag > FlagT
QMatrix4x4 localTransform
void removeChild(QSSGRenderNode &inChild)
constexpr bool getLocalState(LocalState stateFlag) const
constexpr bool getGlobalState(GlobalState stateFlag) const
~QSSGRenderNode() override
constexpr bool isDirty(DirtyFlag dirtyFlag=DirtyFlag::DirtyMask) const
QMatrix3x3 calculateNormalMatrix() const
void markDirty(DirtyFlag dirtyFlag)
QVector3D getGlobalPivot() const
QSSGBounds3 getBounds(QSSGBufferManager &inManager, bool inIncludeChildren=true) const
QSSGRenderNode * instanceRoot
void calculateMVPAndNormalMatrix(const QMatrix4x4 &inViewProjection, QMatrix4x4 &outMVP, QMatrix3x3 &outNormalMatrix) const