qskinny/examples/iot-dashboard/nodes/DiagramSegmentsNode.h

23 lines
535 B
C++

#pragma once
#include <QPolygonF>
#include <QSGFlatColorMaterial>
#include <QSGGeometryNode>
class IdlChartSegmentsNode : public QSGGeometryNode
{
public:
IdlChartSegmentsNode();
void update( const QRectF& rect, const QColor& color, const QVector< QVector<QPointF> >& dataPoints, int xGridLines );
private:
QSGFlatColorMaterial m_material;
QSGGeometry m_geometry;
QRectF m_rect;
QColor m_color;
QVector< QVector<QPointF> > m_dataPoints;
int m_xGridLines;
};