Skip to content

Conversation

@jacobtylerwalls
Copy link
Member

Fixes #904

@gregchapman-dev , please share your findings if you give this a look -- you'll need makeNotation=True turned on during musicxml export, or else need to make your own calls to these new makeNotation-y routines. You might also want #1240, so a local branch merging all of that in might be the ticket. (#1240 avoids making the implausible tuplet, and then after running splitAtDurations() to get those 11 components isolated (again... another makeNotation-y routine to run yourself), this PR puts them back together in threes to get quarter rests again.)

This still doesn't get you a leading half rest -- for that, you'll want #992. Maybe @MarkGotham can reignite the effort there: I recall we were close, we solved the beat sequence extraction and just needed a PR to nail down the API, I think (?)

@coveralls
Copy link

coveralls commented Mar 3, 2022

Coverage Status

Coverage increased (+0.007%) to 93.107% when pulling efac0cb on jacobtylerwalls:reexpress-tuplets into 83b7020 on cuthbertLab:master.

Comment on lines +1880 to +1882
>>> splitElementsToCompleteTuplets(s)
>>> [el.quarterLength for el in s.notes]
[Fraction(1, 3), Fraction(2, 3), Fraction(1, 3), Fraction(2, 3)]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we have a test that the second and third notes are tied?

@mscuthbert
Copy link
Member

mscuthbert commented Aug 6, 2022

If the tie adding test is added, this is ready to go and merge once tests pass. THANKS!

@mscuthbert mscuthbert merged commit de1be4b into cuthbertLab:master Aug 6, 2022
@mscuthbert
Copy link
Member

Congrats @jacobtylerwalls -- huge amount of work.

@jacobtylerwalls jacobtylerwalls deleted the reexpress-tuplets branch August 6, 2022 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Express durations with or without tuplets according to context

3 participants