彻底改版2.0
This commit is contained in:
28
control/smoothcurve/smoothcurve.h
Normal file
28
control/smoothcurve/smoothcurve.h
Normal file
@@ -0,0 +1,28 @@
|
||||
#ifndef SMOOTHCURVE_H
|
||||
#define SMOOTHCURVE_H
|
||||
|
||||
#include <QObject>
|
||||
#include <QVector>
|
||||
#include <QPointF>
|
||||
#include <QPainterPath>
|
||||
|
||||
#ifdef quc
|
||||
class Q_DECL_EXPORT SmoothCurve
|
||||
#else
|
||||
class SmoothCurve
|
||||
#endif
|
||||
|
||||
{
|
||||
public:
|
||||
//创建平滑曲线路径
|
||||
static QPainterPath createSmoothCurve(const QVector<QPointF> &points);
|
||||
static QPainterPath createSmoothCurve2(const QVector<QPointF> &points);
|
||||
|
||||
private:
|
||||
static void calculateFirstControlPoints(double *&result, const double *rhs, int n);
|
||||
static void calculateControlPoints(const QVector<QPointF> &datas,
|
||||
QVector<QPointF> *firstControlPoints,
|
||||
QVector<QPointF> *secondControlPoints);
|
||||
};
|
||||
|
||||
#endif // SMOOTHCURVE_H
|
||||
Reference in New Issue
Block a user