2 bezier.hh -- declare Bezier and Bezier_bow
4 (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
10 #include "interval.hh"
12 #include "polynomial.hh"
20 void assert_sanity () const;
21 void scale (Real x, Real y);
24 void translate (Offset);
26 Real get_other_coordinate (Axis a, Real x) const;
27 vector<Real> solve_point (Axis, Real coordinate) const;
28 vector<Real> solve_derivative (Offset) const;
29 Interval extent (Axis) const;
30 Interval control_point_extent (Axis) const;
32 Polynomial polynomial (Axis)const;
33 Offset curve_point (Real t) const;
34 Real curve_coordinate (Real t, Axis) const;
36 static const int CONTROL_COUNT = 4;
39 Bezier curves always have 4 control points. Making this into an
40 vector<> gives unnecessary overhead, and makes debugging a royal
46 void scale (vector<Offset> *array, Real xscale, Real yscale);
47 void rotate (vector<Offset> *array, Real phi);
48 void translate (vector<Offset> *array, Offset o);
50 Bezier slur_shape (Real width, Real height_limit,
51 Real height_proportion);
52 Real slur_height (Real width, Real height_limit, Real height_proportion);
53 void get_slur_indent_height (Real *indent, Real *height, Real width, Real h_inf, Real r_0);