Core 1.0
BezierQuadricCurve Class Reference

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.

Detailed Description

Piecewise Bézier quadric curves.

The class only stores the control points.

Member Function Documentation

◆ GetQuadric()

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.

Parameters
iIndex of the quadric, which should be in [0,n-3].