[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: misplaced-note-head bug (issue 5303)
From: |
Lukas-Fabian Moser |
Subject: |
Re: misplaced-note-head bug (issue 5303) |
Date: |
Thu, 4 Jul 2019 12:31:46 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 |
Folks,
only now was I able to do regression tests regarding my proposed fix(es)
of the misplaced-note-head-bug (issue 5303):
The bug is caused by the integer-cast
lastpos = int (p);
in lily/stem.cc:629.
Replacing it by either
i) lastpos = p; // use float value
or
ii) lastpos = int (round (p)) // correctly round to integer
resolves the bug. Neither variant introduces regressions (differences
only in in test-output-distance and rest-dot-position, the latter being,
I think, unrelated - the seemingly random position changes of dots to
multi-voice simultaneous rests).
Questions:
a) How to decide which fix is "better"? (My guess that using floats
might pose the danger of rounding errors adding up until something bad
happens - probably only for huge chords comprising hundreds of notes,
but I'd tend to favor the solution with rounding.)
b) Would anybody be willing to shepherd a patch through the review process?
c) Does the situation warrant inclusion of a new regression test? (The
example in the bug report on
https://sourceforge.net/p/testlilyissues/issues/5303/ would be suitable
I think.)
Best
Lukas
fix-misplaced-notehead-bug-use-float-value.diff
Description: Text Data
fix-misplaced-notehead-bug-round-to-int.diff
Description: Text Data
- Re: misplaced-note-head bug (issue 5303),
Lukas-Fabian Moser <=
- Re: misplaced-note-head bug (issue 5303), James Lowe, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), Phil Holmes, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), David Kastrup, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), Benkő Pál, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), Lukas-Fabian Moser, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), David Kastrup, 2019/07/04
- Re: misplaced-note-head bug (issue 5303), Lukas-Fabian Moser, 2019/07/05
- Re: misplaced-note-head bug (issue 5303), James Lowe, 2019/07/06