QwtCurveFitter(3)
π QwtCurveFitter(3) β like, the mother of all curve fitters π
okay bestie, settle in, because this one's from the Qwt User's Guide manual and it's genuinely the blueprint of the whole curve-fitting family πΈ
β¨ NAME β¨
QwtCurveFitter β the abstract base class for a curve fitter. yes. abstract. it's giving "i don't do the work, my children do" main character energy π
π¦ SYNOPSIS π¦
#include <qwt_curve_fitter.h>
Inherited by QwtPolarFitter, QwtSplineCurveFitter, and QwtWeedingCurveFitter β those three are the nepo babies that actually implement stuff, and we love them for it π«Ά
π Public Types
enum Mode { Polygon, Path }β the preferred mode of the fitting algorithm. like, what format does your fitter vibe with β¨
π Public Member Functions
virtual ~QwtCurveFitter ()β Destructor. say bye πMode mode () constβ tells you which mode it prefersvirtual QPolygonF fitCurve (const QPolygonF &polygon) const =0β pure virtual, so you must implement itvirtual QPainterPath fitCurvePath (const QPolygonF &polygon) const =0β also pure virtual, also mandatory
π Protected Member Functions
QwtCurveFitter (Mode mode)β the constructor, protected, so it's a "family only" situation π
π Detailed Description π
Abstract base class for a curve fitter.
Definition at line 21 of file qwt_curve_fitter.h. β yes bestie, receipts included π§Ύ
π Member Enumeration Documentation π
enum QwtCurveFitter::Mode
Preferred mode of the fitting algorithm. and listen, this is the important bit: even if a QPainterPath can always be created from a QPolygonF, the overhead of that conversion can be avoided by indicating the preference of the implementation to the application code. so like, don't do extra work for no reason, periodt π
Enumerator:
Polygonβ the fitting algorithm creates a polygon, and the implementation offitCurvePath()simply wraps the polygon into a path. lowkey lazy but in a smart way π- See also:
QwtWeedingCurveFitter
- See also:
Pathβ the fitting algorithm creates a painter path, and the implementation offitCurve()extracts a polygon from the path. reverse uno card π¦- See also:
QwtSplineCurveFitter
- See also:
Definition at line 32 of file qwt_curve_fitter.h.
π Constructor & Destructor Documentation π
QwtCurveFitter::~QwtCurveFitter () [virtual]
Destructor. that's it. that's the whole sentence. clean, minimal, iconic π
Definition at line 22 of file qwt_curve_fitter.cpp.
QwtCurveFitter::QwtCurveFitter (Mode mode) [explicit], [protected]
Constructor β¨
Parameters:
modeβ Preferred fitting mode. pick your vibe bestie πΈ
Definition at line 16 of file qwt_curve_fitter.cpp.
π₯ Member Function Documentation π₯
virtual QPolygonF QwtCurveFitter::fitCurve (const QPolygonF & polygon) const [pure virtual]
Find a curve which has the best fit to a series of data points. it's literally the whole point of the class π
Parameters:
polygonβ Series of data points
Returns: Curve points
See also: fitCurvePath()
Implemented in QwtPolarFitter, QwtSplineCurveFitter, and QwtWeedingCurveFitter β all three of them, no cap π
virtual QPainterPath QwtCurveFitter::fitCurvePath (const QPolygonF & polygon) const [pure virtual]
Find a curve path which has the best fit to a series of data points. same assignment, different return type, we stay flexible π
Parameters:
polygonβ Series of data points
Returns: Curve path
See also: fitCurve()
Implemented in QwtPolarFitter, QwtSplineCurveFitter, and QwtWeedingCurveFitter π
QwtCurveFitter::Mode QwtCurveFitter::mode () const
Returns: Preferred fitting mode. that's the whole function. she's short and she knows it π
Definition at line 27 of file qwt_curve_fitter.cpp.
β Author β
Generated automatically by Doxygen for Qwt User's Guide from the source code. so nobody wrote this by hand, the robot did it, and honestly? slay π€β¨
π reminder bestie:fitCurve()andfitCurvePath()are pure virtual β this base class will not do the fitting for you, you gotta subclass it or use one of the three implementations. no shortcuts, iykyk π
mwah π that's the whole page, sourced from the Qwt User's Guide, QwtCurveFitter(3), generated by Doxygen from the source code β see u next time, bestie π¦π
π¦ where this page comes from
- alpine 3.24: qwt-doc 6.3.0-r0 Β· custom
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms