X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Flookup.cc;h=d7b6b8d26e9bc81c5eada2ab7911128c1de26a2d;hb=9a0e3e6c4209f203139e528a2f2f158250659d7e;hp=b6d13fc3568646eebcc70abe8f080dca2c7f54ad;hpb=0398fdb9df24ac2e22a8cbff1b3c18ca04e9f221;p=lilypond.git diff --git a/lily/lookup.cc b/lily/lookup.cc index b6d13fc356..d7b6b8d26e 100644 --- a/lily/lookup.cc +++ b/lily/lookup.cc @@ -246,9 +246,9 @@ Lookup::round_filled_polygon (vector const &points, applies to the given polygon. However, this is quite complicated to check. */ +#ifdef DEBUG const Real epsilon = 0.01; -#ifdef DEBUG /* remove consecutive duplicate points */ for (vsize i = 0; i < points.size (); i++) { @@ -417,9 +417,9 @@ Lookup::slur (Bezier curve, Real curvethick, Real linethick, calculate the offset for the two beziers that make the sandwich for the slur */ - Real alpha = (curve.control_[3] - curve.control_[0]).arg (); + Offset dir = (curve.control_[3] - curve.control_[0]).direction (); Bezier back = curve; - Offset perp = curvethick * complex_exp (Offset (0, alpha + M_PI / 2)) * 0.5; + Offset perp = 0.5 * curvethick * Offset (-dir[Y_AXIS], dir[X_AXIS]); back.control_[1] += perp; back.control_[2] += perp;