-Bezier_bow::calc (Real dx, Real dy, Real h, Real d)
-{
- // ugh
- Real pi = M_PI;
- // ugh
- Real staffsize_f = paper_l_->get_var ("barsize");
- Real height_limit = staffsize_f;
- Real alpha = height_limit * pi / 2.0;
- Real ratio = 1.0/3.0;
- Real beta = 3.0/4.0 * pi * ratio/alpha;
-
- Real b = sqrt (dx * dx + dy * dy);
- Real indent = 2.0/5.0 * alpha * atan (beta * b);
- // ugh, ugly height hack, see lily-ps-defs.tex
- Real height = (indent + h) * d;
-
- Offset control[4];
- control[0] = Offset(0, 0);
- control[1] = Offset(indent, height);
- control[2] = Offset(b - indent, height);
- control[3] = Offset( b, 0 );
-
- Real phi = dx ? atan (dy/dx) : sign (dy) * pi / 2.0;
- Real sphi = sin (phi);
- Real cphi = cos (phi);
- for (int i = 1; i < 4; i++)
+Bezier::scale (Real x, Real y)
+{
+ for (int i = CONTROL_COUNT; i--;)