1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
4#ifndef Q3DSCATTER_H
5#define Q3DSCATTER_H
6
7#include <QtDataVisualization/qabstract3dgraph.h>
8#include <QtDataVisualization/qvalue3daxis.h>
9#include <QtDataVisualization/qscatter3dseries.h>
10
11QT_BEGIN_NAMESPACE
12
13class Q3DScatterPrivate;
14
15class Q_DATAVISUALIZATION_EXPORT Q3DScatter : public QAbstract3DGraph
16{
17 Q_OBJECT
18 Q_PROPERTY(QValue3DAxis *axisX READ axisX WRITE setAxisX NOTIFY axisXChanged)
19 Q_PROPERTY(QValue3DAxis *axisY READ axisY WRITE setAxisY NOTIFY axisYChanged)
20 Q_PROPERTY(QValue3DAxis *axisZ READ axisZ WRITE setAxisZ NOTIFY axisZChanged)
21 Q_PROPERTY(QScatter3DSeries *selectedSeries READ selectedSeries NOTIFY selectedSeriesChanged)
22
23public:
24 explicit Q3DScatter(const QSurfaceFormat *format = nullptr, QWindow *parent = nullptr);
25 virtual ~Q3DScatter();
26
27 void addSeries(QScatter3DSeries *series);
28 void removeSeries(QScatter3DSeries *series);
29 QList<QScatter3DSeries *> seriesList() const;
30
31 void setAxisX(QValue3DAxis *axis);
32 QValue3DAxis *axisX() const;
33 void setAxisY(QValue3DAxis *axis);
34 QValue3DAxis *axisY() const;
35 void setAxisZ(QValue3DAxis *axis);
36 QValue3DAxis *axisZ() const;
37 void addAxis(QValue3DAxis *axis);
38 void releaseAxis(QValue3DAxis *axis);
39 QList<QValue3DAxis *> axes() const;
40
41 QScatter3DSeries *selectedSeries() const;
42
43Q_SIGNALS:
44 void axisXChanged(QValue3DAxis *axis);
45 void axisYChanged(QValue3DAxis *axis);
46 void axisZChanged(QValue3DAxis *axis);
47 void selectedSeriesChanged(QScatter3DSeries *series);
48
49private:
50 Q3DScatterPrivate *dptr();
51 const Q3DScatterPrivate *dptrc() const;
52 Q_DISABLE_COPY(Q3DScatter)
53};
54
55QT_END_NAMESPACE
56
57#endif
58

source code of qtdatavis3d/src/datavisualization/engine/q3dscatter.h