]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/bezier-bow.hh
release: 1.3.25
[lilypond.git] / lily / include / bezier-bow.hh
1 /*   
2   bezier-bow.hh -- declare Bezier_bow
3   
4   source file of the GNU LilyPond music typesetter
5   
6   (c) 1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7   
8  */
9
10 #ifndef BEZIER_BOW_HH
11 #define BEZIER_BOW_HH
12
13 #include "bezier.hh"
14 #include "lily-proto.hh"
15 #include "lily-guile.hh"
16
17 /**
18   Implement bow specific bezier curve. Calculate bezier curve for bow
19   from bow paratime_signatures.  */
20 class Bezier_bow
21 {
22   Bezier curve_;
23   Array<Offset> encompass_;
24   
25   void blow_fit ();
26   void calc_default ();
27   void to_canonic_form ();
28   void calc_tangent_controls ();
29   Real fit_factor () const;
30
31
32   Paper_def* paper_l_;
33   Direction dir_;
34   Real alpha_;
35   Offset origin_;
36 public:
37   Real  rc_factor_;
38   Real height_limit_;
39   Real ratio_;
40
41
42   Real vertical_offset_needed () const;
43   
44   Bezier_bow (Array<Offset> points, Direction dir);
45   void calculate ();
46   Bezier get_curve () const;
47 };
48
49
50 #endif /* BEZIER_BOW_HH */
51