[Xr] Xr API comments

Keith Packard keithp at keithp.com
Tue May 27 21:43:41 PDT 2003


Around 15 o'clock on May 27, Bill Spitzak wrote:

> I don't think conic sections or 3-point splines can be mathematically 
> accurately represented by 4-point Bezier splines.

Conic sections cannot, that's why we've seen rational quadratic splines 
creep into other drawing systems.  Quadratic splines can be trivially 
converted into cubic splines.

I think approximating conics with cubic splines is a good solution; cubic 
splines are far easier to draw and it takes only a few splines to 
accurately represent an arbitrary conic.

> Also there are an infinite number of curves possible and you can't add a
> new call for every one.

Yup.  Cubic Beziér splines have the advantage of being easy to understand 
intuitively, isomorphic to all linear, quadratic and cubic splines and 
really easy to draw.  If you want something else, we provide all of the 
underlying mechanism and you can do it yourself :-)

-keith






More information about the cairo mailing list