diff options
author | Mike Krus <mike.krus@kdab.com> | 2020-01-22 21:35:32 +0000 |
---|---|---|
committer | Mike Krus <mike.krus@kdab.com> | 2020-02-27 06:29:57 +0000 |
commit | 17706144e9dc6c2dfde580b7821f18c5f6924682 (patch) | |
tree | 5f77929db358607fe63a1d438b7a746a6966cbfb /tests/auto/extras/common/geometrytesthelper.h | |
parent | 7f625e93620b313466d0223e911c0c3a5b492617 (diff) |
Geometry refactoring
Move QBuffer, QAttribute, QGeometry to Qt3DCore.
Change-Id: I59dfd091eefadcada93350b3aba955f40b304385
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'tests/auto/extras/common/geometrytesthelper.h')
-rw-r--r-- | tests/auto/extras/common/geometrytesthelper.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/auto/extras/common/geometrytesthelper.h b/tests/auto/extras/common/geometrytesthelper.h index b825fa407..a80d652a8 100644 --- a/tests/auto/extras/common/geometrytesthelper.h +++ b/tests/auto/extras/common/geometrytesthelper.h @@ -29,12 +29,12 @@ #ifndef GEOMETRYTESTHELPER_H #define GEOMETRYTESTHELPER_H -#include <Qt3DRender/qattribute.h> -#include <Qt3DRender/qbuffer.h> -#include <Qt3DRender/qgeometry.h> +#include <Qt3DCore/qattribute.h> +#include <Qt3DCore/qbuffer.h> +#include <Qt3DCore/qgeometry.h> template<typename IndexType> -IndexType extractIndexData(Qt3DRender::QAttribute *attribute, int index) +IndexType extractIndexData(Qt3DCore::QAttribute *attribute, int index) { // Get the raw data const IndexType *typedData = reinterpret_cast<const IndexType *>(attribute->buffer()->data().constData()); @@ -45,7 +45,7 @@ IndexType extractIndexData(Qt3DRender::QAttribute *attribute, int index) } template<typename VertexType, typename IndexType> -VertexType extractVertexData(Qt3DRender::QAttribute *attribute, IndexType index) +VertexType extractVertexData(Qt3DCore::QAttribute *attribute, IndexType index) { // Get the raw data const char *rawData = attribute->buffer()->data().constData(); @@ -55,10 +55,10 @@ VertexType extractVertexData(Qt3DRender::QAttribute *attribute, IndexType index) // Construct vertex from the typed data VertexType vertex; - const Qt3DRender::QAttribute::VertexBaseType type = attribute->vertexBaseType(); + const Qt3DCore::QAttribute::VertexBaseType type = attribute->vertexBaseType(); switch (type) { - case Qt3DRender::QAttribute::Float: { + case Qt3DCore::QAttribute::Float: { const float *typedVertexData = reinterpret_cast<const float *>(vertexData); const int components = attribute->vertexSize(); for (int i = 0; i < components; ++i) |