Be more conservative about triplets

This commit is contained in:
Matthias Neeracher 2007-05-29 07:53:57 +00:00
parent 40a84a82e9
commit 2fdd04ac45

View File

@ -477,8 +477,7 @@ void VLMeasure::DecomposeNotes(const VLProperties & prop, VLNoteList & decompose
VLFraction grid(2*swung); VLFraction grid(2*swung);
if (p.fDuration == 4*swung/3 && (at % grid == 0)) { if (p.fDuration == 4*swung/3 && (at % grid == 0)) {
if (p.fDuration == c.fDuration && n!=e if (p.fDuration == c.fDuration && n!=e
&& (n->fDuration == p.fDuration && n->fDuration == p.fDuration
|| (n->fDuration == 2*p.fDuration))
) { ) {
; // Triplet, not swing note ; // Triplet, not swing note
} else { } else {
@ -494,8 +493,9 @@ void VLMeasure::DecomposeNotes(const VLProperties & prop, VLNoteList & decompose
// Second swing note (8th triplet -> 8th) // Second swing note (8th triplet -> 8th)
// //
p.fVisual &= VLNote::kNoteHead; p.fVisual &= VLNote::kNoteHead;
} else if (p.fDuration != c.fDuration } else if ((at % p.fDuration != 0)
&& 2*p.fDuration != c.fDuration || (p.fDuration != c.fDuration
&& 2*p.fDuration != c.fDuration)
) { ) {
// //
// Get rid of awkward triplets // Get rid of awkward triplets