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
qssgmeshbvhbuilder.cpp File Reference

(7fd08af374a678b79e43f2564310c8e05896484a)

#include "qssgmeshbvhbuilder_p.h"
#include <QtQuick3DUtils/private/qssgassert_p.h>
+ Include dependency graph for qssgmeshbvhbuilder.cpp:

Go to the source code of this file.

Functions

template<QSSGRenderComponentType ComponentType>
static quint32 getIndexBufferValue (quint32 index, const quint32 indexCount, const QByteArray &indexBufferData)
 
static QVector3D getVertexBufferValuePosition (quint32 index, const quint32 vertexStride, const quint32 vertexPosOffset, const QByteArray &vertexBufferData)
 
static QVector2D getVertexBufferValueUV (quint32 index, const quint32 vertexStride, const quint32 vertexUVOffset, const QByteArray &vertexBufferData)
 
template<QSSGRenderComponentType ComponentType, bool hasIndexBuffer, bool hasPositionData, bool hasUVData>
static void calculateTriangleBoundsImpl (quint32 indexOffset, quint32 indexCount, const QByteArray &indexBufferData, const QByteArray &vertexBufferData, const quint32 vertexStride, const quint32 vertexUVOffset, const quint32 vertexPosOffset, QSSGMeshBVHTriangles &triangleBounds)
 

Variables

static QT_BEGIN_NAMESPACE constexpr quint32 QSSG_MAX_TREE_DEPTH = 40
 
static constexpr quint32 QSSG_MAX_LEAF_TRIANGLES = 10
 

Function Documentation

◆ calculateTriangleBoundsImpl()

template<QSSGRenderComponentType ComponentType, bool hasIndexBuffer, bool hasPositionData, bool hasUVData>
static void calculateTriangleBoundsImpl ( quint32 indexOffset,
quint32 indexCount,
const QByteArray & indexBufferData,
const QByteArray & vertexBufferData,
const quint32 vertexStride,
const quint32 vertexUVOffset,
const quint32 vertexPosOffset,
QSSGMeshBVHTriangles & triangleBounds )
static

Definition at line 149 of file qssgmeshbvhbuilder.cpp.

References getVertexBufferValuePosition(), getVertexBufferValueUV(), and i.

+ Here is the call graph for this function:

◆ getIndexBufferValue()

template<QSSGRenderComponentType ComponentType>
static quint32 getIndexBufferValue ( quint32 index,
const quint32 indexCount,
const QByteArray & indexBufferData )
inlinestatic

Definition at line 115 of file qssgmeshbvhbuilder.cpp.

References Q_ASSERT, Q_STATIC_ASSERT, UnsignedInt16, and UnsignedInt32.

◆ getVertexBufferValuePosition()

static QVector3D getVertexBufferValuePosition ( quint32 index,
const quint32 vertexStride,
const quint32 vertexPosOffset,
const QByteArray & vertexBufferData )
inlinestatic

Definition at line 132 of file qssgmeshbvhbuilder.cpp.

References position().

Referenced by calculateTriangleBoundsImpl().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getVertexBufferValueUV()

static QVector2D getVertexBufferValueUV ( quint32 index,
const quint32 vertexStride,
const quint32 vertexUVOffset,
const QByteArray & vertexBufferData )
inlinestatic

Definition at line 140 of file qssgmeshbvhbuilder.cpp.

Referenced by calculateTriangleBoundsImpl().

+ Here is the caller graph for this function:

Variable Documentation

◆ QSSG_MAX_LEAF_TRIANGLES

constexpr quint32 QSSG_MAX_LEAF_TRIANGLES = 10
staticconstexpr

Definition at line 10 of file qssgmeshbvhbuilder.cpp.

◆ QSSG_MAX_TREE_DEPTH

QT_BEGIN_NAMESPACE constexpr quint32 QSSG_MAX_TREE_DEPTH = 40
staticconstexpr

Definition at line 9 of file qssgmeshbvhbuilder.cpp.