diff options
author | Mike Krus <mike.krus@kdab.com> | 2020-02-26 19:56:54 +0000 |
---|---|---|
committer | Mike Krus <mike.krus@kdab.com> | 2020-02-27 14:19:24 +0000 |
commit | 9c7e55958716de86387d11de0295435d61adfece (patch) | |
tree | 37b590f1e51f0190def5dcf7f51f50bc5a7323fe | |
parent | 2e97cde1dd6f0dec7ee36df8d02527b955597e07 (diff) |
Remove more deprecated code
Change-Id: I14695a93c4dc1b54c5ebc149b0fde0d328d75d7b
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
-rw-r--r-- | src/core/geometry/qbuffer.cpp | 35 | ||||
-rw-r--r-- | src/core/geometry/qbuffer.h | 17 | ||||
-rw-r--r-- | src/core/geometry/qbuffer_p.h | 1 | ||||
-rw-r--r-- | src/extras/defaults/defaults.pri | 2 | ||||
-rw-r--r-- | src/extras/defaults/qtexturedmetalroughmaterial.cpp | 66 | ||||
-rw-r--r-- | src/extras/defaults/qtexturedmetalroughmaterial.h | 67 | ||||
-rw-r--r-- | src/plugins/sceneparsers/assimp/assimpimporter.cpp | 2 | ||||
-rw-r--r-- | src/quick3d/imports/extras/qt3dquick3dextrasplugin.cpp | 6 |
8 files changed, 0 insertions, 196 deletions
diff --git a/src/core/geometry/qbuffer.cpp b/src/core/geometry/qbuffer.cpp index 1b0101c26..a6a13f52e 100644 --- a/src/core/geometry/qbuffer.cpp +++ b/src/core/geometry/qbuffer.cpp @@ -49,7 +49,6 @@ namespace Qt3DCore { QBufferPrivate::QBufferPrivate() : QNodePrivate() - , m_type(QBuffer::VertexBuffer) , m_usage(QBuffer::StaticDraw) , m_access(QBuffer::Write) { @@ -185,18 +184,6 @@ QBuffer::QBuffer(QNode *parent) } /*! - * Constructs a new QBuffer of buffer type \a ty with \a parent. - * - * \deprecated - */ -QBuffer::QBuffer(QBuffer::BufferType ty, QNode *parent) - : QNode(*new QBufferPrivate(), parent) -{ - Q_D(QBuffer); - d->m_type = ty; -} - -/*! * \internal */ QBuffer::~QBuffer() @@ -265,19 +252,6 @@ void QBuffer::setUsage(QBuffer::UsageType usage) } } -/*! - * \property QBuffer::type - * - * Holds the buffer type. - * - * \deprecated - */ -QBuffer::BufferType QBuffer::type() const -{ - Q_D(const QBuffer); - return d->m_type; -} - void QBuffer::setAccessType(QBuffer::AccessType access) { Q_D(QBuffer); @@ -300,15 +274,6 @@ QBuffer::AccessType QBuffer::accessType() const return d->m_access; } -void QBuffer::setType(QBuffer::BufferType type) -{ - Q_D(QBuffer); - if (type != d->m_type) { - d->m_type = type; - emit typeChanged(type); - } -} - } // namespace Qt3DCore QT_END_NAMESPACE diff --git a/src/core/geometry/qbuffer.h b/src/core/geometry/qbuffer.h index d60f99fa7..341ac019d 100644 --- a/src/core/geometry/qbuffer.h +++ b/src/core/geometry/qbuffer.h @@ -54,23 +54,10 @@ class QBufferPrivate; class Q_3DCORESHARED_EXPORT QBuffer : public Qt3DCore::QNode { Q_OBJECT - Q_PROPERTY(BufferType type READ type WRITE setType NOTIFY typeChanged) Q_PROPERTY(UsageType usage READ usage WRITE setUsage NOTIFY usageChanged) Q_PROPERTY(AccessType accessType READ accessType WRITE setAccessType NOTIFY accessTypeChanged REVISION 9) public: - enum BufferType - { - VertexBuffer = 0x8892, // GL_ARRAY_BUFFER - IndexBuffer = 0x8893, // GL_ELEMENT_ARRAY_BUFFER - PixelPackBuffer = 0x88EB, // GL_PIXEL_PACK_BUFFER - PixelUnpackBuffer = 0x88EC, // GL_PIXEL_UNPACK_BUFFER - UniformBuffer = 0x8A11, // GL_UNIFORM_BUFFER - ShaderStorageBuffer = 0x90D2, // GL_SHADER_STORAGE_BUFFER - DrawIndirectBuffer = 0x8F3F // GL_DRAW_INDIRECT_BUFFER - }; - Q_ENUM(BufferType) // LCOV_EXCL_LINE - enum UsageType { StreamDraw = 0x88E0, // GL_STREAM_DRAW @@ -93,11 +80,9 @@ public: Q_ENUM(AccessType) // LCOV_EXCL_LINE explicit QBuffer(Qt3DCore::QNode *parent = nullptr); - QT_DEPRECATED explicit QBuffer(BufferType ty, Qt3DCore::QNode *parent = nullptr); ~QBuffer(); UsageType usage() const; - QT_DEPRECATED BufferType type() const; AccessType accessType() const; void setData(const QByteArray &bytes); @@ -106,13 +91,11 @@ public: Q_INVOKABLE void updateData(int offset, const QByteArray &bytes); public Q_SLOTS: - QT_DEPRECATED void setType(BufferType type); void setUsage(UsageType usage); void setAccessType(AccessType access); Q_SIGNALS: void dataChanged(const QByteArray &bytes); - void typeChanged(BufferType type); void usageChanged(UsageType usage); void accessTypeChanged(AccessType access); void dataAvailable(); diff --git a/src/core/geometry/qbuffer_p.h b/src/core/geometry/qbuffer_p.h index c4bb9d834..8baffc13e 100644 --- a/src/core/geometry/qbuffer_p.h +++ b/src/core/geometry/qbuffer_p.h @@ -69,7 +69,6 @@ public: QBufferPrivate(); QByteArray m_data; - QBuffer::BufferType m_type; QBuffer::UsageType m_usage; QBuffer::AccessType m_access; diff --git a/src/extras/defaults/defaults.pri b/src/extras/defaults/defaults.pri index db4db24db..cbd3bb8fe 100644 --- a/src/extras/defaults/defaults.pri +++ b/src/extras/defaults/defaults.pri @@ -44,7 +44,6 @@ HEADERS += \ $$PWD/qtexturematerial_p.h \ $$PWD/qmetalroughmaterial.h \ $$PWD/qmetalroughmaterial_p.h \ - $$PWD/qtexturedmetalroughmaterial.h \ $$PWD/qmorphphongmaterial.h \ $$PWD/qmorphphongmaterial_p.h @@ -71,6 +70,5 @@ SOURCES += \ $$PWD/qspritesheetitem.cpp \ $$PWD/qtexturematerial.cpp \ $$PWD/qmetalroughmaterial.cpp \ - $$PWD/qtexturedmetalroughmaterial.cpp \ $$PWD/qmorphphongmaterial.cpp diff --git a/src/extras/defaults/qtexturedmetalroughmaterial.cpp b/src/extras/defaults/qtexturedmetalroughmaterial.cpp deleted file mode 100644 index 55d061fc3..000000000 --- a/src/extras/defaults/qtexturedmetalroughmaterial.cpp +++ /dev/null @@ -1,66 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2017 Klaralvdalens Datakonsult AB (KDAB). -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the Qt3D module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 3 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL3 included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 3 requirements -** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 2.0 or (at your option) the GNU General -** Public license version 3 or any later version approved by the KDE Free -** Qt Foundation. The licenses are as published by the Free Software -** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-2.0.html and -** https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#include "qtexturedmetalroughmaterial.h" - -QT_BEGIN_NAMESPACE - -namespace Qt3DExtras { - -/*! - \class Qt3DExtras::QTexturedMetalRoughMaterial - \brief This class is deprecated; use QMetalRoughMaterial instead. - \inmodule Qt3DExtras - \since 5.9 - \inherits Qt3DExtras::QMetalRoughMaterial - - \deprecated -*/ - -/*! - Constructs a new QTexturedMetalRoughMaterial instance with parent object \a parent. -*/ -QTexturedMetalRoughMaterial::QTexturedMetalRoughMaterial(QNode *parent) - : QMetalRoughMaterial(parent) -{ -} - -} // namespace Qt3DExtras - -QT_END_NAMESPACE diff --git a/src/extras/defaults/qtexturedmetalroughmaterial.h b/src/extras/defaults/qtexturedmetalroughmaterial.h deleted file mode 100644 index 23bce81f0..000000000 --- a/src/extras/defaults/qtexturedmetalroughmaterial.h +++ /dev/null @@ -1,67 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2017 Klaralvdalens Datakonsult AB (KDAB). -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the Qt3D module of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 3 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL3 included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 3 requirements -** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 2.0 or (at your option) the GNU General -** Public license version 3 or any later version approved by the KDE Free -** Qt Foundation. The licenses are as published by the Free Software -** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-2.0.html and -** https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#ifndef QT3DEXTRAS_QTEXTUREDMETALROUGHMATERIAL_H -#define QT3DEXTRAS_QTEXTUREDMETALROUGHMATERIAL_H - -#include <Qt3DExtras/qmetalroughmaterial.h> - -QT_BEGIN_NAMESPACE - -namespace Qt3DExtras { - -class QT_DEPRECATED_X("Use Qt3DExtras::QMetalRoughMaterial") Q_3DEXTRASSHARED_EXPORT QTexturedMetalRoughMaterial : public QMetalRoughMaterial -{ - Q_OBJECT - Q_PROPERTY(QVariant ambientOcclusion READ ambientOcclusion WRITE setAmbientOcclusion NOTIFY ambientOcclusionChanged) - Q_PROPERTY(QVariant normal READ normal WRITE setNormal NOTIFY normalChanged) - -public: - explicit QTexturedMetalRoughMaterial(Qt3DCore::QNode *parent = nullptr); - -Q_SIGNALS: - void ambientOcclusionChanged(const QVariant &ambientOcclusion); - void normalChanged(const QVariant &normal); -}; - -} // namespace Qt3DExtras - -QT_END_NAMESPACE - -#endif // QT3DEXTRAS_QTEXTUREDMETALROUGHMATERIAL_H diff --git a/src/plugins/sceneparsers/assimp/assimpimporter.cpp b/src/plugins/sceneparsers/assimp/assimpimporter.cpp index 7655bf931..2f858b41e 100644 --- a/src/plugins/sceneparsers/assimp/assimpimporter.cpp +++ b/src/plugins/sceneparsers/assimp/assimpimporter.cpp @@ -704,10 +704,8 @@ QGeometryRenderer *AssimpImporter::loadMesh(uint meshIndex) meshGeometry->setParent(geometryRenderer); Qt3DCore::QBuffer *vertexBuffer = QAbstractNodeFactory::createNode<Qt3DCore::QBuffer>("QBuffer"); vertexBuffer->setParent(meshGeometry); - vertexBuffer->setType(Qt3DCore::QBuffer::VertexBuffer); Qt3DCore::QBuffer *indexBuffer = QAbstractNodeFactory::createNode<Qt3DCore::QBuffer>("QBuffer"); indexBuffer->setParent(meshGeometry); - indexBuffer->setType(Qt3DCore::QBuffer::IndexBuffer); geometryRenderer->setGeometry(meshGeometry); diff --git a/src/quick3d/imports/extras/qt3dquick3dextrasplugin.cpp b/src/quick3d/imports/extras/qt3dquick3dextrasplugin.cpp index 707824182..515f9545c 100644 --- a/src/quick3d/imports/extras/qt3dquick3dextrasplugin.cpp +++ b/src/quick3d/imports/extras/qt3dquick3dextrasplugin.cpp @@ -71,7 +71,6 @@ #include <Qt3DExtras/qspritesheetitem.h> #include <Qt3DExtras/qtext2dentity.h> #include <Qt3DExtras/qtexturematerial.h> -#include <Qt3DExtras/qtexturedmetalroughmaterial.h> #include <Qt3DExtras/qtorusgeometry.h> #include <Qt3DExtras/qtorusmesh.h> @@ -115,11 +114,6 @@ void Qt3DQuick3DExtrasPlugin::registerTypes(const char *uri) qmlRegisterType<Qt3DExtras::QDiffuseSpecularMaterial>(uri, 2, 10, "DiffuseSpecularMaterial"); qmlRegisterType<Qt3DExtras::QMetalRoughMaterial>(uri, 2, 9, "MetalRoughMaterial"); qmlRegisterType<Qt3DExtras::QMetalRoughMaterial, 10>(uri, 2, 10, "MetalRoughMaterial"); -QT_WARNING_PUSH -QT_WARNING_DISABLE_DEPRECATED - qmlRegisterType<Qt3DExtras::QTexturedMetalRoughMaterial>(uri, 2, 9, "TexturedMetalRoughMaterial"); -QT_WARNING_POP - qmlRegisterType<Qt3DExtras::QMorphPhongMaterial>(uri, 2, 9, "MorphPhongMaterial"); qmlRegisterType<Qt3DExtras::QSpriteGrid>(uri, 2, 10, "SpriteGrid"); qmlRegisterType<Qt3DExtras::QSpriteSheetItem>(uri, 2, 10, "SpriteItem"); |