GSoC 2016 - Week 13 - Voices and Rhythms

Posted 8 years ago

This was my 13th and final week working on note entry with MuseScore for Google Summer of Code. This week I improved the rhythm simplification algorithm and added the ability to enter more than one voice at a time in Real-time mode.

This week’s summary:

  • Rhythmic groupings at the sub-beat level
  • Separation of Real-time input into multiple voices

Still to do:

  • Fix bugs with voice separation
  • Submit GSoC Work Product

Rhythmic grouping at the sub-beat level

I extended the grouping algorithm to work with notes that are smaller than a beat in the current time signature (i.e. smaller than a crotchet or quarter-note in 4/4). I followed the grouping rules in Elaine Gould's "Behind Bars", and I believe I have pretty much every case covered that does not involve analysing the surrounding context within the bar. In practice this means that there are very few cases that the algorithm does not get exactly right (at least not according to Gould's rules), but even in these cases the result appears to be acceptable.

Voice separation

It becomes necessary to add extra voices when there are at least two notes that overlap in time, but this can be avoided by splitting the notes at the overlap and connecting them with ties. I had a basic algorithm for voice separation working a few weeks ago, and now I have improved it to take advantage of the grouping algorithm. The grouping algorithm breaks and ties notes that cross rhythmically important beats within the bar, and the presence of the additional breaks allows some notes to be combined into chords instead of creating another voice.

Unfortunately, their appears to be a bug somewhere in MuseScore's score editing functions that is only exposed when 3 or more voices are in use simultaneously, leading to some strange behaviour in Real-time mode. Hopefully I can get to the bottom of this in the next couple of days.

Previous Section Next
GSoC 2016 - Week 12 - Rhythmic durations shoogle's blog GSoC 2016 - Work Product - Semi-Realtime MIDI