Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qt_quadratic_bezier.cpp File Reference
#include <private/qbezier_p.h>
#include <QtMath>
+ Include dependency graph for qt_quadratic_bezier.cpp:

Go to the source code of this file.

Functions

static QT_BEGIN_NAMESPACE qreal qt_scoreQuadratic (const QBezier &b, QPointF qcp)
 
static QPointF qt_quadraticForCubic (const QBezier &b)
 
static int qt_getInflectionPoints (const QBezier &orig, qreal *tpoints)
 
static void qt_addToQuadratics (const QBezier &b, QPolygonF *p, int maxSplits, qreal maxDiff)
 
void qt_toQuadratics (const QBezier &b, QPolygonF *out, qreal errorLimit)
 

Function Documentation

◆ qt_addToQuadratics()

static void qt_addToQuadratics ( const QBezier b,
QPolygonF p,
int  maxSplits,
qreal  maxDiff 
)
static

Definition at line 144 of file qt_quadratic_bezier.cpp.

References QBezier::parameterSplitLeft(), qt_addToQuadratics(), qt_quadraticForCubic(), and qt_scoreQuadratic().

Referenced by qt_addToQuadratics(), and qt_toQuadratics().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_getInflectionPoints()

static int qt_getInflectionPoints ( const QBezier orig,
qreal tpoints 
)
static

Definition at line 88 of file qt_quadratic_bezier.cpp.

References QLineF::angle(), QBezier::mapBy(), QBezier::pt1(), QBezier::pt4(), Q_ASSERT, qFuzzyCompare(), qFuzzyIsNull(), qIsFinite(), qSqrt(), qSwap(), QTransform::rotate(), QTransform::translate(), QPointF::x(), and QPointF::y().

Referenced by qt_toQuadratics().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_quadraticForCubic()

static QPointF qt_quadraticForCubic ( const QBezier b)
static

Definition at line 67 of file qt_quadratic_bezier.cpp.

References QLineF::intersects(), QLineF::NoIntersection, QPointF::x(), and QPointF::y().

Referenced by qt_addToQuadratics().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_scoreQuadratic()

static QT_BEGIN_NAMESPACE qreal qt_scoreQuadratic ( const QBezier b,
QPointF  qcp 
)
static

Definition at line 11 of file qt_quadratic_bezier.cpp.

References d, QPointF::dotProduct(), i, init(), and Q_STATIC_ASSERT.

Referenced by qt_addToQuadratics().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_toQuadratics()

void qt_toQuadratics ( const QBezier b,
QPolygonF out,
qreal  errorLimit 
)

Definition at line 159 of file qt_quadratic_bezier.cpp.

References QBezier::bezierOnInterval(), QRectF::bottomRight(), c2, QPointF::dotProduct(), i, out, qt_addToQuadratics(), qt_getInflectionPoints(), t1, and QRectF::topLeft().

Referenced by QuadPath::fromPainterPath().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: