summaryrefslogtreecommitdiffstats
path: root/src/extras/geometries
diff options
context:
space:
mode:
authorMike Krus <mike.krus@kdab.com>2020-01-22 21:35:32 +0000
committerMike Krus <mike.krus@kdab.com>2020-02-27 06:29:57 +0000
commit17706144e9dc6c2dfde580b7821f18c5f6924682 (patch)
tree5f77929db358607fe63a1d438b7a746a6966cbfb /src/extras/geometries
parent7f625e93620b313466d0223e911c0c3a5b492617 (diff)
Geometry refactoring
Move QBuffer, QAttribute, QGeometry to Qt3DCore. Change-Id: I59dfd091eefadcada93350b3aba955f40b304385 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'src/extras/geometries')
-rw-r--r--src/extras/geometries/qconegeometry.cpp12
-rw-r--r--src/extras/geometries/qconegeometry.h22
-rw-r--r--src/extras/geometries/qconegeometry_p.h22
-rw-r--r--src/extras/geometries/qconemesh.cpp4
-rw-r--r--src/extras/geometries/qconemesh.h2
-rw-r--r--src/extras/geometries/qcuboidgeometry.cpp24
-rw-r--r--src/extras/geometries/qcuboidgeometry.h28
-rw-r--r--src/extras/geometries/qcuboidgeometry_p.h23
-rw-r--r--src/extras/geometries/qcuboidmesh.h2
-rw-r--r--src/extras/geometries/qcylindergeometry.cpp12
-rw-r--r--src/extras/geometries/qcylindergeometry.h24
-rw-r--r--src/extras/geometries/qcylindergeometry_p.h21
-rw-r--r--src/extras/geometries/qcylindermesh.cpp5
-rw-r--r--src/extras/geometries/qcylindermesh.h4
-rw-r--r--src/extras/geometries/qplanegeometry.cpp10
-rw-r--r--src/extras/geometries/qplanegeometry.h28
-rw-r--r--src/extras/geometries/qplanegeometry_p.h23
-rw-r--r--src/extras/geometries/qplanemesh.h4
-rw-r--r--src/extras/geometries/qspheregeometry.cpp12
-rw-r--r--src/extras/geometries/qspheregeometry.h28
-rw-r--r--src/extras/geometries/qspheregeometry_p.h27
-rw-r--r--src/extras/geometries/qspheremesh.h2
-rw-r--r--src/extras/geometries/qtorusgeometry.cpp12
-rw-r--r--src/extras/geometries/qtorusgeometry.h24
-rw-r--r--src/extras/geometries/qtorusgeometry_p.h23
-rw-r--r--src/extras/geometries/qtorusmesh.h2
26 files changed, 203 insertions, 197 deletions
diff --git a/src/extras/geometries/qconegeometry.cpp b/src/extras/geometries/qconegeometry.cpp
index af9941394..e2165e6f8 100644
--- a/src/extras/geometries/qconegeometry.cpp
+++ b/src/extras/geometries/qconegeometry.cpp
@@ -45,7 +45,7 @@
* \brief The QConeGeometry class allows creation of a cone in 3D space.
* \since 5.7
* \ingroup geometries
- * \inherits Qt3DRender::QGeometry
+ * \inherits Qt3DCore::QGeometry
*
* The QConeGeometry class is most commonly used internally by the QConeMesh
* but can also be used in custom Qt3DRender::QGeometryRenderer subclasses. The class
@@ -59,15 +59,15 @@
#include "qconegeometry.h"
#include "qconegeometry_p.h"
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
#include <QtGui/QVector3D>
#include <cmath>
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -249,8 +249,8 @@ void QConeGeometryPrivate::init()
m_normalAttribute = new QAttribute(q);
m_texCoordAttribute = new QAttribute(q);
m_indexAttribute = new QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
// vec3 pos, vec2 tex, vec3 normal
const quint32 elementSize = 3 + 2 + 3;
diff --git a/src/extras/geometries/qconegeometry.h b/src/extras/geometries/qconegeometry.h
index 2deb56f0e..cff40576e 100644
--- a/src/extras/geometries/qconegeometry.h
+++ b/src/extras/geometries/qconegeometry.h
@@ -41,11 +41,11 @@
#define QT3DEXTRAS_QCONEGEOMETRY_H
#include <Qt3DExtras/qt3dextras_global.h>
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
} // Render
@@ -53,7 +53,7 @@ namespace Qt3DExtras {
class QConeGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QConeGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QConeGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY( bool hasTopEndcap READ hasTopEndcap WRITE setHasTopEndcap NOTIFY hasTopEndcapChanged )
@@ -63,10 +63,10 @@ class Q_3DEXTRASSHARED_EXPORT QConeGeometry : public Qt3DRender::QGeometry
Q_PROPERTY( float topRadius READ topRadius WRITE setTopRadius NOTIFY topRadiusChanged )
Q_PROPERTY( float bottomRadius READ bottomRadius WRITE setBottomRadius NOTIFY bottomRadiusChanged )
Q_PROPERTY(float length READ length WRITE setLength NOTIFY lengthChanged)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QConeGeometry(QNode *parent = nullptr);
@@ -83,10 +83,10 @@ public:
int slices() const;
float length() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setHasTopEndcap( bool hasTopEndcap );
diff --git a/src/extras/geometries/qconegeometry_p.h b/src/extras/geometries/qconegeometry_p.h
index 39c3913fc..a87aa41c6 100644
--- a/src/extras/geometries/qconegeometry_p.h
+++ b/src/extras/geometries/qconegeometry_p.h
@@ -51,20 +51,20 @@
// We mean it.
//
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // namespace Qt3DRender
+} // namespace Qt3DCore
namespace Qt3DExtras {
-class QConeGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QConeGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QConeGeometryPrivate();
@@ -80,13 +80,13 @@ public:
float m_topRadius;
float m_bottomRadius;
float m_length;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_positionBuffer;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_positionBuffer;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
QByteArray generateVertexData() const;
QByteArray generateIndexData() const;
diff --git a/src/extras/geometries/qconemesh.cpp b/src/extras/geometries/qconemesh.cpp
index d54e43e1f..508e7cfd3 100644
--- a/src/extras/geometries/qconemesh.cpp
+++ b/src/extras/geometries/qconemesh.cpp
@@ -44,8 +44,8 @@
#include "qconegeometry.h"
#include <Qt3DExtras/qconemesh.h>
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
#include <QtGui/QVector3D>
#include <qmath.h>
diff --git a/src/extras/geometries/qconemesh.h b/src/extras/geometries/qconemesh.h
index 6c0408b7b..57fe0c0fc 100644
--- a/src/extras/geometries/qconemesh.h
+++ b/src/extras/geometries/qconemesh.h
@@ -97,7 +97,7 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};
diff --git a/src/extras/geometries/qcuboidgeometry.cpp b/src/extras/geometries/qcuboidgeometry.cpp
index 1f86defb4..87707eefd 100644
--- a/src/extras/geometries/qcuboidgeometry.cpp
+++ b/src/extras/geometries/qcuboidgeometry.cpp
@@ -40,16 +40,16 @@
#include "qcuboidgeometry.h"
#include "qcuboidgeometry_p.h"
-#include <Qt3DRender/qattribute.h>
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/private/renderlogging_p.h>
+#include <Qt3DCore/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/private/corelogging_p.h>
#include <limits>
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -406,13 +406,13 @@ QCuboidGeometryPrivate::QCuboidGeometryPrivate()
void QCuboidGeometryPrivate::init()
{
Q_Q(QCuboidGeometry);
- m_positionAttribute = new Qt3DRender::QAttribute(q);
- m_normalAttribute = new Qt3DRender::QAttribute(q);
- m_texCoordAttribute = new Qt3DRender::QAttribute(q);
- m_tangentAttribute = new Qt3DRender::QAttribute(q);
- m_indexAttribute = new Qt3DRender::QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_positionAttribute = new Qt3DCore::QAttribute(q);
+ m_normalAttribute = new Qt3DCore::QAttribute(q);
+ m_texCoordAttribute = new Qt3DCore::QAttribute(q);
+ m_tangentAttribute = new Qt3DCore::QAttribute(q);
+ m_indexAttribute = new Qt3DCore::QAttribute(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
// vec3 pos vec2 tex vec3 normal vec4 tangent
const quint32 stride = (3 + 2 + 3 + 4) * sizeof(float);
@@ -578,7 +578,7 @@ QByteArray QCuboidGeometryPrivate::generateIndexData() const
* \brief The QCuboidGeometry class allows creation of a cuboid in 3D space.
* \since 5.7
* \ingroup geometries
- * \inherits Qt3DRender::QGeometry
+ * \inherits Qt3DCore::QGeometry
*
* The QCuboidGeometry class is most commonly used internally by the QCuboidMesh
* but can also be used in custom Qt3DRender::QGeometryRenderer subclasses.
diff --git a/src/extras/geometries/qcuboidgeometry.h b/src/extras/geometries/qcuboidgeometry.h
index 50bb10930..1234c65be 100644
--- a/src/extras/geometries/qcuboidgeometry.h
+++ b/src/extras/geometries/qcuboidgeometry.h
@@ -41,22 +41,22 @@
#define QT3DEXTRAS_QCUBOIDGEOMETRY_H
#include <Qt3DExtras/qt3dextras_global.h>
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
#include <QtCore/QSize>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
class QCuboidGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QCuboidGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QCuboidGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY(float xExtent READ xExtent WRITE setXExtent NOTIFY xExtentChanged)
@@ -65,11 +65,11 @@ class Q_3DEXTRASSHARED_EXPORT QCuboidGeometry : public Qt3DRender::QGeometry
Q_PROPERTY(QSize xyMeshResolution READ xyMeshResolution WRITE setXYMeshResolution NOTIFY xyMeshResolutionChanged)
Q_PROPERTY(QSize yzMeshResolution READ yzMeshResolution WRITE setYZMeshResolution NOTIFY yzMeshResolutionChanged)
Q_PROPERTY(QSize xzMeshResolution READ xzMeshResolution WRITE setXZMeshResolution NOTIFY xzMeshResolutionChanged)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QCuboidGeometry(QNode *parent = nullptr);
@@ -85,11 +85,11 @@ public:
QSize xyMeshResolution() const;
QSize xzMeshResolution() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *tangentAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *tangentAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setXExtent(float xExtent);
diff --git a/src/extras/geometries/qcuboidgeometry_p.h b/src/extras/geometries/qcuboidgeometry_p.h
index 2c0ea5524..399ea5876 100644
--- a/src/extras/geometries/qcuboidgeometry_p.h
+++ b/src/extras/geometries/qcuboidgeometry_p.h
@@ -53,20 +53,21 @@
#include <QtCore/QSize>
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
+#include <Qt3DExtras/qcuboidgeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
-class QCuboidGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QCuboidGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QCuboidGeometryPrivate();
@@ -82,13 +83,13 @@ public:
QSize m_xzFaceResolution;
QSize m_xyFaceResolution;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_tangentAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_tangentAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
Q_DECLARE_PUBLIC(QCuboidGeometry)
diff --git a/src/extras/geometries/qcuboidmesh.h b/src/extras/geometries/qcuboidmesh.h
index dc7f821ff..a945dbe2b 100644
--- a/src/extras/geometries/qcuboidmesh.h
+++ b/src/extras/geometries/qcuboidmesh.h
@@ -97,7 +97,7 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};
diff --git a/src/extras/geometries/qcylindergeometry.cpp b/src/extras/geometries/qcylindergeometry.cpp
index a6bdc5f8d..5d37b5ac8 100644
--- a/src/extras/geometries/qcylindergeometry.cpp
+++ b/src/extras/geometries/qcylindergeometry.cpp
@@ -44,8 +44,8 @@
#include "qcylindergeometry.h"
#include "qcylindergeometry_p.h"
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
#include <QtGui/QVector3D>
#include <qmath.h>
@@ -53,7 +53,7 @@
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -202,8 +202,8 @@ void QCylinderGeometryPrivate::init()
m_normalAttribute = new QAttribute(q);
m_texCoordAttribute = new QAttribute(q);
m_indexAttribute = new QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
// vec3 pos, vec2 tex, vec3 normal
const quint32 elementSize = 3 + 2 + 3;
@@ -354,7 +354,7 @@ QByteArray QCylinderGeometryPrivate::generateIndexData() const
* \brief The QCylinderGeometry class allows creation of a cylinder in 3D space.
* \since 5.7
* \ingroup geometries
- * \inherits Qt3DRender::QGeometry
+ * \inherits Qt3DCore::QGeometry
*
* The QCylinderGeometry class is most commonly used internally by the QCylinderMesh
* but can also be used in custom Qt3DRender::QGeometryRenderer subclasses.
diff --git a/src/extras/geometries/qcylindergeometry.h b/src/extras/geometries/qcylindergeometry.h
index 0a9022016..4151aadb2 100644
--- a/src/extras/geometries/qcylindergeometry.h
+++ b/src/extras/geometries/qcylindergeometry.h
@@ -41,30 +41,30 @@
#define QT3DEXTRAS_QCYLINDERGEOMETRY_H
#include <Qt3DExtras/qt3dextras_global.h>
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
-} // namespace Qt3DRender
+} // namespace Qt3DCore
namespace Qt3DExtras {
class QCylinderGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QCylinderGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QCylinderGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY(int rings READ rings WRITE setRings NOTIFY ringsChanged)
Q_PROPERTY(int slices READ slices WRITE setSlices NOTIFY slicesChanged)
Q_PROPERTY(float radius READ radius WRITE setRadius NOTIFY radiusChanged)
Q_PROPERTY(float length READ length WRITE setLength NOTIFY lengthChanged)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QCylinderGeometry(QNode *parent = nullptr);
@@ -78,10 +78,10 @@ public:
float radius() const;
float length() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setRings(int rings);
diff --git a/src/extras/geometries/qcylindergeometry_p.h b/src/extras/geometries/qcylindergeometry_p.h
index d88c34874..4803322e1 100644
--- a/src/extras/geometries/qcylindergeometry_p.h
+++ b/src/extras/geometries/qcylindergeometry_p.h
@@ -51,20 +51,21 @@
// We mean it.
//
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
+#include <Qt3DExtras/qcylindergeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // namespace Qt3DRender
+} // namespace Qt3DCore
namespace Qt3DExtras {
-class QCylinderGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QCylinderGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QCylinderGeometryPrivate();
@@ -77,12 +78,12 @@ public:
int m_slices;
float m_radius;
float m_length;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
QByteArray generateVertexData() const;
QByteArray generateIndexData() const;
diff --git a/src/extras/geometries/qcylindermesh.cpp b/src/extras/geometries/qcylindermesh.cpp
index 48e114cd4..3a495cce2 100644
--- a/src/extras/geometries/qcylindermesh.cpp
+++ b/src/extras/geometries/qcylindermesh.cpp
@@ -45,14 +45,15 @@
#include "qcylindermesh.h"
#include <Qt3DExtras/qcylindergeometry.h>
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
#include <QtGui/QVector3D>
#include <qmath.h>
QT_BEGIN_NAMESPACE
+using namespace Qt3DCore;
using namespace Qt3DRender;
namespace Qt3DExtras {
diff --git a/src/extras/geometries/qcylindermesh.h b/src/extras/geometries/qcylindermesh.h
index 19ef5d2cf..f2c8fb01b 100644
--- a/src/extras/geometries/qcylindermesh.h
+++ b/src/extras/geometries/qcylindermesh.h
@@ -86,11 +86,11 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};
-} // namespace Qt3DRender
+} // namespace Qt3DExtras
QT_END_NAMESPACE
diff --git a/src/extras/geometries/qplanegeometry.cpp b/src/extras/geometries/qplanegeometry.cpp
index a7ba3d56a..e83548ad5 100644
--- a/src/extras/geometries/qplanegeometry.cpp
+++ b/src/extras/geometries/qplanegeometry.cpp
@@ -40,14 +40,14 @@
#include "qplanegeometry.h"
#include "qplanegeometry_p.h"
-#include <Qt3DRender/qattribute.h>
-#include <Qt3DRender/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
#include <limits>
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -445,8 +445,8 @@ void QPlaneGeometryPrivate::init()
m_texCoordAttribute = new QAttribute(q);
m_tangentAttribute = new QAttribute(q);
m_indexAttribute = new QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
const int nVerts = m_meshResolution.width() * m_meshResolution.height();
const int stride = (3 + 2 + 3 + 4) * sizeof(float);
diff --git a/src/extras/geometries/qplanegeometry.h b/src/extras/geometries/qplanegeometry.h
index 91e985700..9cd51abea 100644
--- a/src/extras/geometries/qplanegeometry.h
+++ b/src/extras/geometries/qplanegeometry.h
@@ -41,33 +41,33 @@
#define QT3DEXTRAS_QPLANEGEOMETRY_H
#include <Qt3DExtras/qt3dextras_global.h>
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
#include <QtCore/QSize>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
class QPlaneGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QPlaneGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QPlaneGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY(float width READ width WRITE setWidth NOTIFY widthChanged)
Q_PROPERTY(float height READ height WRITE setHeight NOTIFY heightChanged)
Q_PROPERTY(QSize resolution READ resolution WRITE setResolution NOTIFY resolutionChanged)
Q_PROPERTY(bool mirrored READ mirrored WRITE setMirrored NOTIFY mirroredChanged REVISION 9)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QPlaneGeometry(QNode *parent = nullptr);
@@ -81,11 +81,11 @@ public:
float height() const;
bool mirrored() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *tangentAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *tangentAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setResolution(const QSize &resolution);
diff --git a/src/extras/geometries/qplanegeometry_p.h b/src/extras/geometries/qplanegeometry_p.h
index b1f63f277..4e87a3781 100644
--- a/src/extras/geometries/qplanegeometry_p.h
+++ b/src/extras/geometries/qplanegeometry_p.h
@@ -53,20 +53,21 @@
#include <QtCore/QSize>
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
+#include <Qt3DExtras/qplanegeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
-class QPlaneGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QPlaneGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QPlaneGeometryPrivate();
@@ -76,13 +77,13 @@ public:
float m_height;
QSize m_meshResolution;
bool m_mirrored;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_tangentAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_tangentAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
Q_DECLARE_PUBLIC(QPlaneGeometry)
diff --git a/src/extras/geometries/qplanemesh.h b/src/extras/geometries/qplanemesh.h
index eebea1dbf..923af8897 100644
--- a/src/extras/geometries/qplanemesh.h
+++ b/src/extras/geometries/qplanemesh.h
@@ -87,11 +87,11 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};
-} // namespace Qt3DRender
+} // namespace Qt3DExtras
QT_END_NAMESPACE
diff --git a/src/extras/geometries/qspheregeometry.cpp b/src/extras/geometries/qspheregeometry.cpp
index ab84b5ff0..c780ba83c 100644
--- a/src/extras/geometries/qspheregeometry.cpp
+++ b/src/extras/geometries/qspheregeometry.cpp
@@ -40,8 +40,8 @@
#include "qspheregeometry.h"
#include "qspheregeometry_p.h"
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
#include <qmath.h>
@@ -52,7 +52,7 @@
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -190,8 +190,8 @@ void QSphereGeometryPrivate::init()
m_texCoordAttribute = new QAttribute(q);
m_tangentAttribute = new QAttribute(q);
m_indexAttribute = new QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
// vec3 pos, vec2 tex, vec3 normal, vec4 tangent
const quint32 elementSize = 3 + 2 + 3 + 4;
@@ -334,7 +334,7 @@ QByteArray QSphereGeometryPrivate::generateIndexData() const
* \brief The QSphereGeometry class allows creation of a sphere in 3D space.
* \since 5.7
* \ingroup geometries
- * \inherits Qt3DRender::QGeometry
+ * \inherits Qt3DCore::QGeometry
*
* The QSphereGeometry class is most commonly used internally by the QSphereMesh
* but can also be used in custom Qt3DRender::QGeometryRenderer subclasses.
diff --git a/src/extras/geometries/qspheregeometry.h b/src/extras/geometries/qspheregeometry.h
index 8bd8c9c94..8f42e4a31 100644
--- a/src/extras/geometries/qspheregeometry.h
+++ b/src/extras/geometries/qspheregeometry.h
@@ -40,33 +40,33 @@
#ifndef QT3DEXTRAS_QSPHEREGEOMETRY_H
#define QT3DEXTRAS_QSPHEREGEOMETRY_H
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
#include <Qt3DExtras/qt3dextras_global.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
class QSphereGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QSphereGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QSphereGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY(int rings READ rings WRITE setRings NOTIFY ringsChanged)
Q_PROPERTY(int slices READ slices WRITE setSlices NOTIFY slicesChanged)
Q_PROPERTY(float radius READ radius WRITE setRadius NOTIFY radiusChanged)
Q_PROPERTY(bool generateTangents READ generateTangents WRITE setGenerateTangents NOTIFY generateTangentsChanged)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *tangentAttribute READ tangentAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QSphereGeometry(QNode *parent = nullptr);
@@ -80,11 +80,11 @@ public:
int slices() const;
float radius() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *tangentAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *tangentAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setRings(int rings);
diff --git a/src/extras/geometries/qspheregeometry_p.h b/src/extras/geometries/qspheregeometry_p.h
index 2dc83495e..cf31e17c6 100644
--- a/src/extras/geometries/qspheregeometry_p.h
+++ b/src/extras/geometries/qspheregeometry_p.h
@@ -51,20 +51,21 @@
// We mean it.
//
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
+#include <Qt3DExtras/qspheregeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
-class QSphereGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QSphereGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QSphereGeometryPrivate();
@@ -74,15 +75,15 @@ public:
int m_rings;
int m_slices;
float m_radius;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_tangentAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
-
- Q_DECLARE_PUBLIC(QSphereGeometry);
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_tangentAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
+
+ Q_DECLARE_PUBLIC(QSphereGeometry)
QByteArray generateVertexData() const;
QByteArray generateIndexData() const;
diff --git a/src/extras/geometries/qspheremesh.h b/src/extras/geometries/qspheremesh.h
index 44e5b81bb..998cd7c0e 100644
--- a/src/extras/geometries/qspheremesh.h
+++ b/src/extras/geometries/qspheremesh.h
@@ -87,7 +87,7 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};
diff --git a/src/extras/geometries/qtorusgeometry.cpp b/src/extras/geometries/qtorusgeometry.cpp
index 1e65ab2ef..c9b430043 100644
--- a/src/extras/geometries/qtorusgeometry.cpp
+++ b/src/extras/geometries/qtorusgeometry.cpp
@@ -40,8 +40,8 @@
#include "qtorusgeometry.h"
#include "qtorusgeometry_p.h"
-#include <Qt3DRender/qbuffer.h>
-#include <Qt3DRender/qattribute.h>
+#include <Qt3DCore/qbuffer.h>
+#include <Qt3DCore/qattribute.h>
#include <QtGui/QVector3D>
#include <QtGui/QVector4D>
@@ -49,7 +49,7 @@
QT_BEGIN_NAMESPACE
-using namespace Qt3DRender;
+using namespace Qt3DCore;
namespace Qt3DExtras {
@@ -176,8 +176,8 @@ void QTorusGeometryPrivate::init()
m_texCoordAttribute = new QAttribute(q);
m_tangentAttribute = new QAttribute(q);
m_indexAttribute = new QAttribute(q);
- m_vertexBuffer = new Qt3DRender::QBuffer(q);
- m_indexBuffer = new Qt3DRender::QBuffer(q);
+ m_vertexBuffer = new Qt3DCore::QBuffer(q);
+ m_indexBuffer = new Qt3DCore::QBuffer(q);
// vec3 pos, vec2 tex, vec3 normal, vec4 tangent
const quint32 elementSize = 3 + 2 + 3 + 4;
const quint32 stride = elementSize * sizeof(float);
@@ -311,7 +311,7 @@ QByteArray QTorusGeometryPrivate::generateIndexData() const
* \brief The QTorusGeometry class allows creation of a torus in 3D space.
* \since 5.7
* \ingroup geometries
- * \inherits Qt3DRender::QGeometry
+ * \inherits Qt3DCore::QGeometry
*
* The QTorusGeometry class is most commonly used internally by the QTorusMesh
* but can also be used in custom Qt3DRender::QGeometryRenderer subclasses.
diff --git a/src/extras/geometries/qtorusgeometry.h b/src/extras/geometries/qtorusgeometry.h
index cd4a4bb06..3fe159aa7 100644
--- a/src/extras/geometries/qtorusgeometry.h
+++ b/src/extras/geometries/qtorusgeometry.h
@@ -41,31 +41,31 @@
#define QT3DEXTRAS_QTORUSGEOMETRY_H
#include <Qt3DExtras/qt3dextras_global.h>
-#include <Qt3DRender/qgeometry.h>
+#include <Qt3DCore/qgeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
class QTorusGeometryPrivate;
-class Q_3DEXTRASSHARED_EXPORT QTorusGeometry : public Qt3DRender::QGeometry
+class Q_3DEXTRASSHARED_EXPORT QTorusGeometry : public Qt3DCore::QGeometry
{
Q_OBJECT
Q_PROPERTY(int rings READ rings WRITE setRings NOTIFY ringsChanged)
Q_PROPERTY(int slices READ slices WRITE setSlices NOTIFY slicesChanged)
Q_PROPERTY(float radius READ radius WRITE setRadius NOTIFY radiusChanged)
Q_PROPERTY(float minorRadius READ minorRadius WRITE setMinorRadius NOTIFY minorRadiusChanged)
- Q_PROPERTY(Qt3DRender::QAttribute *positionAttribute READ positionAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *normalAttribute READ normalAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
- Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *positionAttribute READ positionAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *normalAttribute READ normalAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *texCoordAttribute READ texCoordAttribute CONSTANT)
+ Q_PROPERTY(Qt3DCore::QAttribute *indexAttribute READ indexAttribute CONSTANT)
public:
explicit QTorusGeometry(QNode *parent = nullptr);
@@ -79,10 +79,10 @@ public:
float radius() const;
float minorRadius() const;
- Qt3DRender::QAttribute *positionAttribute() const;
- Qt3DRender::QAttribute *normalAttribute() const;
- Qt3DRender::QAttribute *texCoordAttribute() const;
- Qt3DRender::QAttribute *indexAttribute() const;
+ Qt3DCore::QAttribute *positionAttribute() const;
+ Qt3DCore::QAttribute *normalAttribute() const;
+ Qt3DCore::QAttribute *texCoordAttribute() const;
+ Qt3DCore::QAttribute *indexAttribute() const;
public Q_SLOTS:
void setRings(int rings);
diff --git a/src/extras/geometries/qtorusgeometry_p.h b/src/extras/geometries/qtorusgeometry_p.h
index c05e03835..28572261e 100644
--- a/src/extras/geometries/qtorusgeometry_p.h
+++ b/src/extras/geometries/qtorusgeometry_p.h
@@ -51,20 +51,21 @@
// We mean it.
//
-#include <Qt3DRender/private/qgeometry_p.h>
+#include <Qt3DCore/private/qgeometry_p.h>
+#include <Qt3DExtras/qtorusgeometry.h>
QT_BEGIN_NAMESPACE
-namespace Qt3DRender {
+namespace Qt3DCore {
class QAttribute;
class QBuffer;
-} // Qt3DRender
+} // Qt3DCore
namespace Qt3DExtras {
-class QTorusGeometryPrivate : public Qt3DRender::QGeometryPrivate
+class QTorusGeometryPrivate : public Qt3DCore::QGeometryPrivate
{
public:
QTorusGeometryPrivate();
@@ -74,13 +75,13 @@ public:
int m_slices;
float m_radius;
float m_minorRadius;
- Qt3DRender::QAttribute *m_positionAttribute;
- Qt3DRender::QAttribute *m_normalAttribute;
- Qt3DRender::QAttribute *m_texCoordAttribute;
- Qt3DRender::QAttribute *m_tangentAttribute;
- Qt3DRender::QAttribute *m_indexAttribute;
- Qt3DRender::QBuffer *m_vertexBuffer;
- Qt3DRender::QBuffer *m_indexBuffer;
+ Qt3DCore::QAttribute *m_positionAttribute;
+ Qt3DCore::QAttribute *m_normalAttribute;
+ Qt3DCore::QAttribute *m_texCoordAttribute;
+ Qt3DCore::QAttribute *m_tangentAttribute;
+ Qt3DCore::QAttribute *m_indexAttribute;
+ Qt3DCore::QBuffer *m_vertexBuffer;
+ Qt3DCore::QBuffer *m_indexBuffer;
Q_DECLARE_PUBLIC(QTorusGeometry)
diff --git a/src/extras/geometries/qtorusmesh.h b/src/extras/geometries/qtorusmesh.h
index 97bde10a2..2fd9f0a23 100644
--- a/src/extras/geometries/qtorusmesh.h
+++ b/src/extras/geometries/qtorusmesh.h
@@ -85,7 +85,7 @@ private:
void setFirstInstance(int firstInstance);
void setRestartIndexValue(int index);
void setPrimitiveRestartEnabled(bool enabled);
- void setGeometry(Qt3DRender::QGeometry *geometry);
+ void setGeometry(Qt3DCore::QGeometry *geometry);
void setPrimitiveType(PrimitiveType primitiveType);
};