|
Core 1.0
|
Piecewise Bézier quadric curves. More...
#include <bezier.h>
Public Member Functions | |
| QuadricCurve | GetQuadric (int) const |
| Return the i-th QuadricCurve. | |
| Box | GetBox () const |
| Return the bounding box. | |
Protected Attributes | |
| QVector< Vector > | c |
| Set of control points. | |
Piecewise Bézier quadric curves.
The class only stores the control points.
| QuadricCurve BezierQuadricCurve::GetQuadric | ( | int | i | ) | const |
Return the i-th QuadricCurve.
The n control points define n-2 quadrics, which are joined with a continuous tangent: the curve starts at the first control point, ends at the last one, and goes through the middle of the other control segments. The quadric number i has the control points i, i+1 and i+2, the end points being replaced by the middle of the control segments, except for the end points of the curve.
An empty QuadricCurve is returned if there are less than three control points.
| i | Index of the quadric, which should be in [0,n-3]. |