10#ifndef QWT_POINT_DATA_H
11#define QWT_POINT_DATA_H
13#include "qwt_global.h"
14#include "qwt_series_data.h"
28 virtual size_t size()
const QWT_OVERRIDE;
29 virtual QPointF
sample(
size_t index )
const QWT_OVERRIDE;
48 virtual size_t size()
const QWT_OVERRIDE;
49 virtual QPointF
sample(
size_t index )
const QWT_OVERRIDE;
51 const T*
xData()
const;
52 const T*
yData()
const;
73 virtual size_t size()
const QWT_OVERRIDE;
74 virtual QPointF
sample(
size_t index )
const QWT_OVERRIDE;
94 virtual size_t size()
const QWT_OVERRIDE;
95 virtual QPointF
sample(
size_t index )
const QWT_OVERRIDE;
97 const T*
yData()
const;
163 void setSize(
size_t size );
164 virtual size_t size()
const QWT_OVERRIDE;
170 virtual QPointF
sample(
size_t index )
const QWT_OVERRIDE;
178 virtual double y(
double x )
const = 0;
179 virtual double x( uint index )
const;
182 QRectF rectOfInterest()
const;
187 QRectF m_rectOfInterest;
199template<
typename T >
215template<
typename T >
219 std::memcpy( m_x.data(), x, size *
sizeof( T ) );
222 std::memcpy( m_y.data(), y, size *
sizeof( T ) );
226template<
typename T >
229 return qMin( m_x.size(), m_y.size() );
238template<
typename T >
241 return QPointF( m_x[
int( index )], m_y[
int( index )] );
245template<
typename T >
252template<
typename T >
265template<
typename T >
278template<
typename T >
282 std::memcpy( m_y.data(), y, size *
sizeof( T ) );
286template<
typename T >
298template<
typename T >
301 return QPointF( index, m_y[
int( index )] );
305template<
typename T >
325template<
typename T >
334template<
typename T >
346template<
typename T >
349 return QPointF( m_x[
int( index )], m_y[
int( index )] );
353template<
typename T >
360template<
typename T >
379template<
typename T >
387template<
typename T >
399template<
typename T >
402 return QPointF( index, m_y[
int( index ) ] );
406template<
typename T >
Data class containing two pointers to memory blocks of T.
virtual size_t size() const override
virtual QPointF sample(size_t index) const override
QwtCPointerData(const T *x, const T *y, size_t size)
Data class containing a pointer to memory of y coordinates.
QwtCPointerValueData(const T *y, size_t size)
virtual size_t size() const override
virtual QPointF sample(size_t index) const override
A class representing an interval.
Interface for iterating over two QVector<T> objects.
virtual QPointF sample(size_t index) const override
const QVector< T > & xData() const
const QVector< T > & yData() const
QwtPointArrayData(const QVector< T > &x, const QVector< T > &y)
virtual size_t size() const override
Abstract interface for iterating over samples.
virtual void setRectOfInterest(const QRectF &rect)
virtual size_t size() const =0
virtual QRectF boundingRect() const
virtual T sample(size_t i) const =0
virtual double y(double x) const =0
Interface for iterating over a QVector<T>.
QwtValuePointData(const QVector< T > &y)
virtual size_t size() const override
virtual QPointF sample(size_t index) const override
const QVector< T > & yData() const