1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QT3DANIMATION_QMORPHTARGET_H
5#define QT3DANIMATION_QMORPHTARGET_H
6
7#include <Qt3DCore/qattribute.h>
8#include <Qt3DCore/qgeometry.h>
9
10#include <QtCore/qstringlist.h>
11
12#include <Qt3DAnimation/qt3danimation_global.h>
13
14QT_BEGIN_NAMESPACE
15
16namespace Qt3DAnimation {
17
18class QMorphTargetPrivate;
19
20class Q_3DANIMATIONSHARED_EXPORT QMorphTarget : public QObject
21{
22 Q_OBJECT
23 Q_PROPERTY(QStringList attributeNames READ attributeNames NOTIFY attributeNamesChanged)
24
25public:
26 explicit QMorphTarget(QObject *parent = nullptr);
27
28 QList<Qt3DCore::QAttribute *> attributeList() const;
29 QStringList attributeNames() const;
30
31 void setAttributes(const QList<Qt3DCore::QAttribute *> &attributes);
32 void addAttribute(Qt3DCore::QAttribute *attribute);
33 void removeAttribute(Qt3DCore::QAttribute *attribute);
34
35 Q_INVOKABLE static QMorphTarget *fromGeometry(Qt3DCore::QGeometry *geometry,
36 const QStringList &attributes);
37
38Q_SIGNALS:
39 void attributeNamesChanged(const QStringList &attributeNames);
40
41private:
42
43 Q_DECLARE_PRIVATE(QMorphTarget)
44};
45
46} // Qt3DAnimation
47
48QT_END_NAMESPACE
49
50#endif // QT3DANIMATION_QMORPHTARGET_H
51

source code of qt3d/src/animation/frontend/qmorphtarget.h