DescriptionThread skyline construction through stencil interpretation
Before, we'd convert stencils to a combination of boxes and buildings,
and afterwards convert those to skylines.
Avoid passing transforms through Scheme and back.
The new approach has the following advantages:
* We can convert stencils to line segments directly, allowing for more
precise outlines. In particular, angled lines and angled boxes are
converted to line segments, rather than sampled in boxes.
* Fixes a small bug with quantization of rounded box corners
* Obviates intermediate SCM storage for path components. This seems to
be offset by increased memory usage due to more accurate path
representation.
* We can treat line thicknesses much more simply: we just extend line
segments by 0.5 thicknesses on either side, and add them .5
thickness up and down.
A next improvement is to thread Lazy_skyline_pair through to the glyph
outline generation. This would let us cut back on memory use for path
storage, and reduce the number of paths by 2x (the orientation of the
outline segments tells us if they are for the up or down skyline.)
Formatting impact:
The regtest shows 114 differences. The improved skylines lead to
slightly denser formatting, both horizontally and vertically. In
particular, the bulb of the 'flat' symbol is represented more
accurately, leading to tighter spacing of the fourth interval, if the
flat is in a lower position, for example: <es' as'>4 and <es' a'!>4.
Timing data
32bdd6a847 - Thread skyline construction through stencil interpretation
baseline: eaf40071f5 Use vectors rather than lists for skylines.
args: input/regression/mozart-hrn-3
memory: med diff -132 (stddevs 110 53, n=3)
memory: med diff -0.0 % (32bdd6a847 is neutral)
time: med diff -0.40 (stddevs 0.01 0.01, n=3)
time: med diff -10.5 % (32bdd6a847 is faster)
32bdd6a847 - Thread skyline construction through stencil interpretation
baseline: eaf40071f5 Use vectors rather than lists for skylines.
args: -I carver MSDM
memory: med diff 6900 (stddevs 142 76, n=3)
memory: med diff 0.6 % (32bdd6a847 is fatter)
time: med diff -0.21 (stddevs 0.08 0.10, n=3)
time: med diff -0.4 % (32bdd6a847 is faster)
Patch Set 1 #Patch Set 2 : separate header file, pass in transform. #Patch Set 3 : split functions into scm arg and rest #Patch Set 4 : tweaks; timings. #
Total comments: 15
Patch Set 5 : jonas, dak. #Patch Set 6 : update commit msg; no functional changes #
MessagesTotal messages: 9
|