X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=flower%2Finclude%2Foffset.hh;h=a8c5987801069b01790b545b4a12db4c70923bfc;hb=5d84bfad4626892bcffd05adcced53c8a2329047;hp=cddec1fc00c7cb9acd4c85c7e52c572a3d1dc68c;hpb=d2762a4f1add2bb04d6fc34d3c7ae03eeb7d500f;p=lilypond.git diff --git a/flower/include/offset.hh b/flower/include/offset.hh index cddec1fc00..a8c5987801 100644 --- a/flower/include/offset.hh +++ b/flower/include/offset.hh @@ -111,7 +111,6 @@ public: Offset direction () const; Offset swapped () const; - Real arg () const; Real angle_degrees () const; Real length () const; bool is_sane () const; @@ -124,8 +123,7 @@ IMPLEMENT_ARITHMETIC_OPERATOR (Offset, -); IMPLEMENT_ARITHMETIC_OPERATOR (Offset, *); Offset complex_multiply (Offset, Offset); -Offset complex_divide (Offset, Offset); -Offset complex_exp (Offset); +Offset offset_directed (Real); inline Offset Offset::operator *= (Offset z2) @@ -169,5 +167,13 @@ dot_product (Offset o1, Offset o2) return o1[X_AXIS] * o2[X_AXIS] + o1[Y_AXIS] * o2[Y_AXIS]; } +inline +Real +cross_product (Offset o1, Offset o2) +{ + return o1[X_AXIS] * o2[Y_AXIS] - o1[Y_AXIS] * o2[X_AXIS]; +} + + #endif /* OFFSET_HH */