David Kastrup wrote
> https://codereview.appspot.com/341140043/diff/20001/lily/stencil-integral.cc#newcode393
> lily/stencil-integral.cc:393: for (vsize i = 0; i < (vsize) points.size
> () - 1; i++)
> Why would the last point not be transformed?

Oh, the last point actually is being transformed, because all these straight
lines are drawn from p0 to p1 with
Offset p1 = points[i+1];

Therefore, i+1 must be less than the size of the array and hence
i < points.size () - 1


But, obviously, it'd be better to increase i by 2 in each step, because my
current version will draw unnecessary lines (coloured grey in the attached
image).
These additional straight lines don't do any harm because they always lie
within the rounded box, but it'd be better to just leave them away, of
course:

<http://lilypond.1069038.n5.nabble.com/file/t3887/dak-1.png> 




David Kastrup wrote
> https://codereview.appspot.com/341140043/diff/20001/lily/stencil-integral.cc#newcode423
> lily/stencil-integral.cc:423: for (vsize i = 0; i < (vsize) quantization
> + 1; i++)
> Why not i <= quantization ?

No special reason for this. I threw a coin (really!) and I just used <
instead of <= because this had also been done in make_partial_ellipse_boxes.

When changing this, I'd also change it in make_partial_ellipse_boxes, OK?


All the best,
Torsten




--
Sent from: http://lilypond.1069038.n5.nabble.com/Dev-f88644.html

_______________________________________________
lilypond-devel mailing list
lilypond-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to