diff options
author | Sean Harmer <sean.harmer@kdab.com> | 2016-04-29 19:35:20 +0100 |
---|---|---|
committer | Sean Harmer <sean.harmer@kdab.com> | 2016-05-01 15:43:11 +0000 |
commit | a01b14670e5b35a951ec57297613418dc829d65c (patch) | |
tree | d9bdcc4ca7b325ff5a1c2e68b801efe9e4d667b8 /src/extras | |
parent | f9dc7c72090b9a11a3daf9e2c912213fbeec5739 (diff) |
Q_NULLPTR -> nullptr
Task-number: QTBUG-52736
Change-Id: I58f9cbcdf018e7b672d33dd865067485412b79fe
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'src/extras')
30 files changed, 85 insertions, 85 deletions
diff --git a/src/extras/defaults/qdiffusemapmaterial.h b/src/extras/defaults/qdiffusemapmaterial.h index a0e6a88cf..b6bba9b36 100644 --- a/src/extras/defaults/qdiffusemapmaterial.h +++ b/src/extras/defaults/qdiffusemapmaterial.h @@ -66,7 +66,7 @@ class QT3DEXTRASSHARED_EXPORT QDiffuseMapMaterial : public Qt3DRender::QMaterial Q_PROPERTY(float textureScale READ textureScale WRITE setTextureScale NOTIFY textureScaleChanged) public: - explicit QDiffuseMapMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QDiffuseMapMaterial(Qt3DCore::QNode *parent = nullptr); ~QDiffuseMapMaterial(); QColor ambient() const; diff --git a/src/extras/defaults/qdiffusespecularmapmaterial.h b/src/extras/defaults/qdiffusespecularmapmaterial.h index 43e84bf90..d5dd053bd 100644 --- a/src/extras/defaults/qdiffusespecularmapmaterial.h +++ b/src/extras/defaults/qdiffusespecularmapmaterial.h @@ -65,7 +65,7 @@ class QT3DEXTRASSHARED_EXPORT QDiffuseSpecularMapMaterial : public Qt3DRender::Q Q_PROPERTY(float textureScale READ textureScale WRITE setTextureScale NOTIFY textureScaleChanged) public: - explicit QDiffuseSpecularMapMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QDiffuseSpecularMapMaterial(Qt3DCore::QNode *parent = nullptr); ~QDiffuseSpecularMapMaterial(); QColor ambient() const; diff --git a/src/extras/defaults/qfirstpersoncameracontroller.cpp b/src/extras/defaults/qfirstpersoncameracontroller.cpp index 57cf3ba88..2558dc7b6 100644 --- a/src/extras/defaults/qfirstpersoncameracontroller.cpp +++ b/src/extras/defaults/qfirstpersoncameracontroller.cpp @@ -67,7 +67,7 @@ namespace Qt3DExtras { QFirstPersonCameraControllerPrivate::QFirstPersonCameraControllerPrivate() : Qt3DCore::QEntityPrivate() - , m_camera(Q_NULLPTR) + , m_camera(nullptr) , m_leftMouseButtonAction(new Qt3DInput::QAction()) , m_fineMotionAction(new Qt3DInput::QAction()) , m_rxAxis(new Qt3DInput::QAxis()) @@ -178,7 +178,7 @@ void QFirstPersonCameraControllerPrivate::init() void QFirstPersonCameraControllerPrivate::_q_onTriggered(float dt) { - if (m_camera != Q_NULLPTR) { + if (m_camera != nullptr) { m_camera->translate(QVector3D(m_txAxis->value() * m_linearSpeed, m_tyAxis->value() * m_linearSpeed, m_tzAxis->value() * m_linearSpeed) * dt); diff --git a/src/extras/defaults/qfirstpersoncameracontroller.h b/src/extras/defaults/qfirstpersoncameracontroller.h index 358f69160..e50d4db5a 100644 --- a/src/extras/defaults/qfirstpersoncameracontroller.h +++ b/src/extras/defaults/qfirstpersoncameracontroller.h @@ -72,7 +72,7 @@ class QT3DEXTRASSHARED_EXPORT QFirstPersonCameraController : public Qt3DCore::QE Q_PROPERTY(float lookSpeed READ lookSpeed WRITE setLookSpeed NOTIFY lookSpeedChanged) public: - explicit QFirstPersonCameraController(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QFirstPersonCameraController(Qt3DCore::QNode *parent = nullptr); ~QFirstPersonCameraController(); Qt3DRender::QCamera *camera() const; diff --git a/src/extras/defaults/qforwardrenderer.h b/src/extras/defaults/qforwardrenderer.h index 34ea9055b..a744b3caf 100644 --- a/src/extras/defaults/qforwardrenderer.h +++ b/src/extras/defaults/qforwardrenderer.h @@ -61,7 +61,7 @@ class QT3DEXTRASSHARED_EXPORT QForwardRenderer : public Qt3DRender::QTechniqueFi Q_PROPERTY(QColor clearColor READ clearColor WRITE setClearColor NOTIFY clearColorChanged) Q_PROPERTY(Qt3DCore::QEntity *camera READ camera WRITE setCamera NOTIFY cameraChanged) public: - explicit QForwardRenderer(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QForwardRenderer(Qt3DCore::QNode *parent = nullptr); ~QForwardRenderer(); QRectF viewportRect() const; diff --git a/src/extras/defaults/qgoochmaterial.h b/src/extras/defaults/qgoochmaterial.h index 170c391ac..dc8bcf2e0 100644 --- a/src/extras/defaults/qgoochmaterial.h +++ b/src/extras/defaults/qgoochmaterial.h @@ -62,7 +62,7 @@ class QT3DEXTRASSHARED_EXPORT QGoochMaterial : public Qt3DRender::QMaterial Q_PROPERTY(float shininess READ shininess WRITE setShininess NOTIFY shininessChanged) public: - explicit QGoochMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QGoochMaterial(Qt3DCore::QNode *parent = nullptr); QColor diffuse() const; QColor specular() const; QColor cool() const; @@ -90,7 +90,7 @@ Q_SIGNALS: void shininessChanged(float shininess); protected: - QGoochMaterial(QGoochMaterialPrivate &dd, Qt3DCore::QNode *parent = Q_NULLPTR); + QGoochMaterial(QGoochMaterialPrivate &dd, Qt3DCore::QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QGoochMaterial) diff --git a/src/extras/defaults/qnormaldiffusemapalphamaterial.h b/src/extras/defaults/qnormaldiffusemapalphamaterial.h index ad4dd6c53..040199b26 100644 --- a/src/extras/defaults/qnormaldiffusemapalphamaterial.h +++ b/src/extras/defaults/qnormaldiffusemapalphamaterial.h @@ -53,7 +53,7 @@ class QT3DEXTRASSHARED_EXPORT QNormalDiffuseMapAlphaMaterial : public QNormalDif { Q_OBJECT public: - explicit QNormalDiffuseMapAlphaMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QNormalDiffuseMapAlphaMaterial(Qt3DCore::QNode *parent = nullptr); ~QNormalDiffuseMapAlphaMaterial(); private: diff --git a/src/extras/defaults/qnormaldiffusemapmaterial.h b/src/extras/defaults/qnormaldiffusemapmaterial.h index 7152d64d5..f60a27b86 100644 --- a/src/extras/defaults/qnormaldiffusemapmaterial.h +++ b/src/extras/defaults/qnormaldiffusemapmaterial.h @@ -67,7 +67,7 @@ class QT3DEXTRASSHARED_EXPORT QNormalDiffuseMapMaterial : public Qt3DRender::QMa Q_PROPERTY(float textureScale READ textureScale WRITE setTextureScale NOTIFY textureScaleChanged) public: - explicit QNormalDiffuseMapMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QNormalDiffuseMapMaterial(Qt3DCore::QNode *parent = nullptr); ~QNormalDiffuseMapMaterial(); QColor ambient() const; @@ -94,7 +94,7 @@ Q_SIGNALS: void textureScaleChanged(float textureScale); protected: - QNormalDiffuseMapMaterial(QNormalDiffuseMapMaterialPrivate &dd, Qt3DCore::QNode *parent = Q_NULLPTR); + QNormalDiffuseMapMaterial(QNormalDiffuseMapMaterialPrivate &dd, Qt3DCore::QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QNormalDiffuseMapMaterial) diff --git a/src/extras/defaults/qnormaldiffusespecularmapmaterial.h b/src/extras/defaults/qnormaldiffusespecularmapmaterial.h index a2f32d2ae..586715971 100644 --- a/src/extras/defaults/qnormaldiffusespecularmapmaterial.h +++ b/src/extras/defaults/qnormaldiffusespecularmapmaterial.h @@ -61,7 +61,7 @@ class QT3DEXTRASSHARED_EXPORT QNormalDiffuseSpecularMapMaterial : public Qt3DRen Q_PROPERTY(float textureScale READ textureScale WRITE setTextureScale NOTIFY textureScaleChanged) public: - explicit QNormalDiffuseSpecularMapMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QNormalDiffuseSpecularMapMaterial(Qt3DCore::QNode *parent = nullptr); ~QNormalDiffuseSpecularMapMaterial(); QColor ambient() const; @@ -88,7 +88,7 @@ Q_SIGNALS: void textureScaleChanged(float textureScale); protected: - QNormalDiffuseSpecularMapMaterial(QNormalDiffuseSpecularMapMaterialPrivate &dd, Qt3DCore::QNode *parent = Q_NULLPTR); + QNormalDiffuseSpecularMapMaterial(QNormalDiffuseSpecularMapMaterialPrivate &dd, Qt3DCore::QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QNormalDiffuseSpecularMapMaterial) diff --git a/src/extras/defaults/qorbitcontrol.cpp b/src/extras/defaults/qorbitcontrol.cpp index 65810e1a0..fbcaa9902 100644 --- a/src/extras/defaults/qorbitcontrol.cpp +++ b/src/extras/defaults/qorbitcontrol.cpp @@ -59,7 +59,7 @@ namespace Qt3DExtras { QOrbitControlPrivate::QOrbitControlPrivate() : Qt3DCore::QEntityPrivate() - , m_camera(Q_NULLPTR) + , m_camera(nullptr) , m_leftMouseButtonAction(new Qt3DInput::QAction()) , m_rightMouseButtonAction(new Qt3DInput::QAction()) , m_altButtonAction(new Qt3DInput::QAction()) @@ -198,7 +198,7 @@ float zoomDistance(QVector3D firstPoint, QVector3D secondPoint) void QOrbitControlPrivate::_q_onTriggered(float dt) { - if (m_camera != Q_NULLPTR) { + if (m_camera != nullptr) { // Mouse input if (m_leftMouseButtonAction->isActive()) { if (m_rightMouseButtonAction->isActive()) { diff --git a/src/extras/defaults/qpervertexcolormaterial.h b/src/extras/defaults/qpervertexcolormaterial.h index 86d169715..485e2fe0e 100644 --- a/src/extras/defaults/qpervertexcolormaterial.h +++ b/src/extras/defaults/qpervertexcolormaterial.h @@ -55,7 +55,7 @@ class QT3DEXTRASSHARED_EXPORT QPerVertexColorMaterial : public Qt3DRender::QMate Q_OBJECT public: - explicit QPerVertexColorMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QPerVertexColorMaterial(Qt3DCore::QNode *parent = nullptr); ~QPerVertexColorMaterial(); private: diff --git a/src/extras/defaults/qphongalphamaterial.h b/src/extras/defaults/qphongalphamaterial.h index d4d46f756..fb2ae1857 100644 --- a/src/extras/defaults/qphongalphamaterial.h +++ b/src/extras/defaults/qphongalphamaterial.h @@ -60,7 +60,7 @@ class QT3DEXTRASSHARED_EXPORT QPhongAlphaMaterial : public Qt3DRender::QMaterial Q_PROPERTY(float alpha READ alpha WRITE setAlpha NOTIFY alphaChanged) public: - explicit QPhongAlphaMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QPhongAlphaMaterial(Qt3DCore::QNode *parent = nullptr); ~QPhongAlphaMaterial(); QColor ambient() const; diff --git a/src/extras/defaults/qphongmaterial.h b/src/extras/defaults/qphongmaterial.h index 112482dee..d4b8a0f0e 100644 --- a/src/extras/defaults/qphongmaterial.h +++ b/src/extras/defaults/qphongmaterial.h @@ -59,7 +59,7 @@ class QT3DEXTRASSHARED_EXPORT QPhongMaterial : public Qt3DRender::QMaterial Q_PROPERTY(float shininess READ shininess WRITE setShininess NOTIFY shininessChanged) public: - explicit QPhongMaterial(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QPhongMaterial(Qt3DCore::QNode *parent = nullptr); ~QPhongMaterial(); QColor ambient() const; diff --git a/src/extras/defaults/qskyboxentity.h b/src/extras/defaults/qskyboxentity.h index b0b97cc3e..4295c2332 100644 --- a/src/extras/defaults/qskyboxentity.h +++ b/src/extras/defaults/qskyboxentity.h @@ -53,7 +53,7 @@ class QT3DEXTRASSHARED_EXPORT QSkyboxEntity : public Qt3DCore::QEntity { Q_OBJECT public: - explicit QSkyboxEntity(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QSkyboxEntity(Qt3DCore::QNode *parent = nullptr); void setBaseName(const QString &path); QString baseName() const; diff --git a/src/extras/geometries/qconegeometry.cpp b/src/extras/geometries/qconegeometry.cpp index ee6e64c1b..64cc569e8 100644 --- a/src/extras/geometries/qconegeometry.cpp +++ b/src/extras/geometries/qconegeometry.cpp @@ -238,7 +238,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const ConeVertexDataFunctor *otherFunctor = functor_cast<ConeVertexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_hasTopEndcap == m_hasTopEndcap && otherFunctor->m_hasBottomEndcap == m_hasBottomEndcap && otherFunctor->m_rings == m_rings && @@ -301,7 +301,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const ConeIndexDataFunctor *otherFunctor = functor_cast<ConeIndexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_hasTopEndcap == m_hasTopEndcap && otherFunctor->m_hasBottomEndcap == m_hasBottomEndcap && otherFunctor->m_rings == m_rings && @@ -330,12 +330,12 @@ QConeGeometryPrivate::QConeGeometryPrivate() , m_topRadius(0.0f) , m_bottomRadius(1.0f) , m_length(1.0f) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qcuboidgeometry.cpp b/src/extras/geometries/qcuboidgeometry.cpp index 78eab4537..dc76edbf6 100644 --- a/src/extras/geometries/qcuboidgeometry.cpp +++ b/src/extras/geometries/qcuboidgeometry.cpp @@ -344,7 +344,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_FINAL { const CuboidVertexBufferFunctor *otherFunctor = functor_cast<CuboidVertexBufferFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_xExtent == m_xExtent && otherFunctor->m_yExtent == m_yExtent && otherFunctor->m_zExtent == m_zExtent && @@ -386,7 +386,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_FINAL { const CuboidIndexBufferFunctor *otherFunctor = functor_cast<CuboidIndexBufferFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_yzFaceResolution == m_yzFaceResolution && otherFunctor->m_xzFaceResolution == m_xzFaceResolution && otherFunctor->m_xyFaceResolution == m_xyFaceResolution); @@ -409,13 +409,13 @@ QCuboidGeometryPrivate::QCuboidGeometryPrivate() , m_yzFaceResolution(2, 2) , m_xzFaceResolution(2, 2) , m_xyFaceResolution(2, 2) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_tangentAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_tangentAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qcuboidgeometry.h b/src/extras/geometries/qcuboidgeometry.h index 3ce52e3bd..1bf7905ea 100644 --- a/src/extras/geometries/qcuboidgeometry.h +++ b/src/extras/geometries/qcuboidgeometry.h @@ -72,7 +72,7 @@ class QT3DEXTRASSHARED_EXPORT QCuboidGeometry : public Qt3DRender::QGeometry Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT) public: - explicit QCuboidGeometry(QNode *parent = Q_NULLPTR); + explicit QCuboidGeometry(QNode *parent = nullptr); void updateIndices(); void updateVertices(); @@ -108,7 +108,7 @@ Q_SIGNALS: void xyMeshResolutionChanged(const QSize &xyMeshResolution); protected: - QCuboidGeometry(QCuboidGeometryPrivate &dd, QNode *parent = Q_NULLPTR); + QCuboidGeometry(QCuboidGeometryPrivate &dd, QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QCuboidGeometry) diff --git a/src/extras/geometries/qcuboidmesh.h b/src/extras/geometries/qcuboidmesh.h index e06d09306..93d386d2c 100644 --- a/src/extras/geometries/qcuboidmesh.h +++ b/src/extras/geometries/qcuboidmesh.h @@ -60,7 +60,7 @@ class QT3DEXTRASSHARED_EXPORT QCuboidMesh : public Qt3DRender::QGeometryRenderer Q_PROPERTY(QSize xyMeshResolution READ xyMeshResolution WRITE setXYMeshResolution NOTIFY xyMeshResolutionChanged) public: - explicit QCuboidMesh(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QCuboidMesh(Qt3DCore::QNode *parent = nullptr); float xExtent() const; float yExtent() const; diff --git a/src/extras/geometries/qcylindergeometry.cpp b/src/extras/geometries/qcylindergeometry.cpp index f42cb0a46..de9d25f9b 100644 --- a/src/extras/geometries/qcylindergeometry.cpp +++ b/src/extras/geometries/qcylindergeometry.cpp @@ -198,7 +198,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const CylinderVertexDataFunctor *otherFunctor = functor_cast<CylinderVertexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_slices == m_slices && otherFunctor->m_radius == m_radius && @@ -247,7 +247,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const CylinderIndexDataFunctor *otherFunctor = functor_cast<CylinderIndexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_slices == m_slices && otherFunctor->m_length == m_length); @@ -269,12 +269,12 @@ QCylinderGeometryPrivate::QCylinderGeometryPrivate() , m_slices(16) , m_radius(1.0f) , m_length(1.0f) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qcylindergeometry.h b/src/extras/geometries/qcylindergeometry.h index 4d524b4f8..9be49c67c 100644 --- a/src/extras/geometries/qcylindergeometry.h +++ b/src/extras/geometries/qcylindergeometry.h @@ -67,7 +67,7 @@ class QT3DEXTRASSHARED_EXPORT QCylinderGeometry : public Qt3DRender::QGeometry Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT) public: - explicit QCylinderGeometry(QNode *parent = Q_NULLPTR); + explicit QCylinderGeometry(QNode *parent = nullptr); void updateVertices(); void updateIndices(); @@ -95,7 +95,7 @@ Q_SIGNALS: void lengthChanged(float length); protected: - QCylinderGeometry(QCylinderGeometryPrivate &dd, QNode *parent = Q_NULLPTR); + QCylinderGeometry(QCylinderGeometryPrivate &dd, QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QCylinderGeometry) diff --git a/src/extras/geometries/qcylindermesh.h b/src/extras/geometries/qcylindermesh.h index 63a497607..0da4b9555 100644 --- a/src/extras/geometries/qcylindermesh.h +++ b/src/extras/geometries/qcylindermesh.h @@ -56,7 +56,7 @@ class QT3DEXTRASSHARED_EXPORT QCylinderMesh : public Qt3DRender::QGeometryRender Q_PROPERTY(float radius READ radius WRITE setRadius NOTIFY radiusChanged) Q_PROPERTY(float length READ length WRITE setLength NOTIFY lengthChanged) public: - explicit QCylinderMesh(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QCylinderMesh(Qt3DCore::QNode *parent = nullptr); int rings() const; int slices() const; diff --git a/src/extras/geometries/qplanegeometry.cpp b/src/extras/geometries/qplanegeometry.cpp index 59e2dbad4..29ec8256e 100644 --- a/src/extras/geometries/qplanegeometry.cpp +++ b/src/extras/geometries/qplanegeometry.cpp @@ -163,7 +163,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_FINAL { const PlaneVertexBufferFunctor *otherFunctor = functor_cast<PlaneVertexBufferFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_width == m_width && otherFunctor->m_height == m_height && otherFunctor->m_resolution == m_resolution); @@ -195,7 +195,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_FINAL { const PlaneIndexBufferFunctor *otherFunctor = functor_cast<PlaneIndexBufferFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_resolution == m_resolution); return false; } @@ -439,13 +439,13 @@ QPlaneGeometryPrivate::QPlaneGeometryPrivate() , m_width(1.0f) , m_height(1.0f) , m_meshResolution(QSize(2, 2)) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_tangentAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_tangentAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qplanegeometry.h b/src/extras/geometries/qplanegeometry.h index a9031f780..d082269c3 100644 --- a/src/extras/geometries/qplanegeometry.h +++ b/src/extras/geometries/qplanegeometry.h @@ -69,7 +69,7 @@ class QT3DEXTRASSHARED_EXPORT QPlaneGeometry : public Qt3DRender::QGeometry Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT) public: - explicit QPlaneGeometry(QNode *parent = Q_NULLPTR); + explicit QPlaneGeometry(QNode *parent = nullptr); void updateVertices(); void updateIndices(); @@ -95,7 +95,7 @@ Q_SIGNALS: void heightChanged(float height); protected: - QPlaneGeometry(QPlaneGeometryPrivate &dd, QNode *parent = Q_NULLPTR); + QPlaneGeometry(QPlaneGeometryPrivate &dd, QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QPlaneGeometry) diff --git a/src/extras/geometries/qplanemesh.h b/src/extras/geometries/qplanemesh.h index 4f05a3896..b308908e8 100644 --- a/src/extras/geometries/qplanemesh.h +++ b/src/extras/geometries/qplanemesh.h @@ -56,7 +56,7 @@ class QT3DEXTRASSHARED_EXPORT QPlaneMesh : public Qt3DRender::QGeometryRenderer Q_PROPERTY(QSize meshResolution READ meshResolution WRITE setMeshResolution NOTIFY meshResolutionChanged) public: - explicit QPlaneMesh(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QPlaneMesh(Qt3DCore::QNode *parent = nullptr); float width() const; float height() const; diff --git a/src/extras/geometries/qspheregeometry.cpp b/src/extras/geometries/qspheregeometry.cpp index 21633f3cd..38af69fe5 100644 --- a/src/extras/geometries/qspheregeometry.cpp +++ b/src/extras/geometries/qspheregeometry.cpp @@ -183,7 +183,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const SphereVertexDataFunctor *otherFunctor = functor_cast<SphereVertexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_slices == m_slices && otherFunctor->m_radius == m_radius); @@ -215,7 +215,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const SphereIndexDataFunctor *otherFunctor = functor_cast<SphereIndexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_slices == m_slices); return false; @@ -234,13 +234,13 @@ QSphereGeometryPrivate::QSphereGeometryPrivate() , m_rings(16) , m_slices(16) , m_radius(1.0f) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_tangentAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_tangentAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qspheregeometry.h b/src/extras/geometries/qspheregeometry.h index 9f2d661e4..5deb8a171 100644 --- a/src/extras/geometries/qspheregeometry.h +++ b/src/extras/geometries/qspheregeometry.h @@ -69,7 +69,7 @@ class QT3DEXTRASSHARED_EXPORT QSphereGeometry : public Qt3DRender::QGeometry Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT) public: - explicit QSphereGeometry(QNode *parent = Q_NULLPTR); + explicit QSphereGeometry(QNode *parent = nullptr); void updateVertices(); void updateIndices(); @@ -98,7 +98,7 @@ Q_SIGNALS: void generateTangentsChanged(bool generateTangents); protected: - QSphereGeometry(QSphereGeometryPrivate &dd, QNode *parent = Q_NULLPTR); + QSphereGeometry(QSphereGeometryPrivate &dd, QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QSphereGeometry) diff --git a/src/extras/geometries/qspheremesh.h b/src/extras/geometries/qspheremesh.h index ac13cb563..5880f7188 100644 --- a/src/extras/geometries/qspheremesh.h +++ b/src/extras/geometries/qspheremesh.h @@ -58,7 +58,7 @@ class QT3DEXTRASSHARED_EXPORT QSphereMesh : public Qt3DRender::QGeometryRenderer Q_PROPERTY(bool generateTangents READ generateTangents WRITE setGenerateTangents NOTIFY generateTangentsChanged) public: - explicit QSphereMesh(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QSphereMesh(Qt3DCore::QNode *parent = nullptr); int rings() const; int slices() const; diff --git a/src/extras/geometries/qtorusgeometry.cpp b/src/extras/geometries/qtorusgeometry.cpp index b9055e332..f62700755 100644 --- a/src/extras/geometries/qtorusgeometry.cpp +++ b/src/extras/geometries/qtorusgeometry.cpp @@ -144,7 +144,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const TorusVertexDataFunctor *otherFunctor = functor_cast<TorusVertexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_sides == m_sides && otherFunctor->m_radius == m_radius && @@ -178,7 +178,7 @@ public: bool operator ==(const QBufferDataGenerator &other) const Q_DECL_OVERRIDE { const TorusIndexDataFunctor *otherFunctor = functor_cast<TorusIndexDataFunctor>(&other); - if (otherFunctor != Q_NULLPTR) + if (otherFunctor != nullptr) return (otherFunctor->m_rings == m_rings && otherFunctor->m_sides == m_sides); return false; @@ -197,12 +197,12 @@ QTorusGeometryPrivate::QTorusGeometryPrivate() , m_slices(16) , m_radius(1.0f) , m_minorRadius(1.0f) - , m_positionAttribute(Q_NULLPTR) - , m_normalAttribute(Q_NULLPTR) - , m_texCoordAttribute(Q_NULLPTR) - , m_indexAttribute(Q_NULLPTR) - , m_vertexBuffer(Q_NULLPTR) - , m_indexBuffer(Q_NULLPTR) + , m_positionAttribute(nullptr) + , m_normalAttribute(nullptr) + , m_texCoordAttribute(nullptr) + , m_indexAttribute(nullptr) + , m_vertexBuffer(nullptr) + , m_indexBuffer(nullptr) { } diff --git a/src/extras/geometries/qtorusgeometry.h b/src/extras/geometries/qtorusgeometry.h index 46637156d..89e205a3f 100644 --- a/src/extras/geometries/qtorusgeometry.h +++ b/src/extras/geometries/qtorusgeometry.h @@ -68,7 +68,7 @@ class QT3DEXTRASSHARED_EXPORT QTorusGeometry : public Qt3DRender::QGeometry Q_PROPERTY(Qt3DRender::QAttribute *indexAttribute READ indexAttribute CONSTANT) public: - explicit QTorusGeometry(QNode *parent = Q_NULLPTR); + explicit QTorusGeometry(QNode *parent = nullptr); void updateVertices(); void updateIndices(); @@ -97,7 +97,7 @@ Q_SIGNALS: protected: - QTorusGeometry(QTorusGeometryPrivate &dd, QNode *parent = Q_NULLPTR); + QTorusGeometry(QTorusGeometryPrivate &dd, QNode *parent = nullptr); private: Q_DECLARE_PRIVATE(QTorusGeometry) diff --git a/src/extras/geometries/qtorusmesh.h b/src/extras/geometries/qtorusmesh.h index 064a589ce..f75ec913a 100644 --- a/src/extras/geometries/qtorusmesh.h +++ b/src/extras/geometries/qtorusmesh.h @@ -55,7 +55,7 @@ class QT3DEXTRASSHARED_EXPORT QTorusMesh : public Qt3DRender::QGeometryRenderer Q_PROPERTY(float radius READ radius WRITE setRadius NOTIFY radiusChanged) Q_PROPERTY(float minorRadius READ minorRadius WRITE setMinorRadius NOTIFY minorRadiusChanged) public: - explicit QTorusMesh(Qt3DCore::QNode *parent = Q_NULLPTR); + explicit QTorusMesh(Qt3DCore::QNode *parent = nullptr); int rings() const; int slices() const; |