- Qt 6.7
- Qt Graphs
- Surface Graph Gallery
- Qt Graphs | Commercial or GPLv3

# Surface Graph Gallery

     // Copyright (C) 2023 The Qt Company Ltd.
     // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

     #ifndef DATASOURCE_H
     #define DATASOURCE_H

     #include <QtGraphs/qsurface3dseries.h>
     #include <QtQml/qqmlregistration.h>

     class DataSource : public QObject
     {
         Q_OBJECT
         QML_ELEMENT
     public:
         explicit DataSource(QObject *parent = 0);
         ~DataSource() override;

         Q_INVOKABLE void generateData(int cacheCount,
                                       int rowCount,
                                       int columnCount,
                                       float xMin,
                                       float xMax,
                                       float yMin,
                                       float yMax,
                                       float zMin,
                                       float zMax);

         Q_INVOKABLE void update(QSurface3DSeries *series);
     private:
         void clearData();

         QList<QSurfaceDataArray> m_data;
         int m_index;
         QSurfaceDataArray m_resetArray;
     };

     #endif