Overview of work this week

A number of things worked on this week, and tweaking of the GPX format.

Key signatures are now imported correctly into a Guitar Pro 6 (GPX) file. Modulation that occurs anywhere in the piece should also be detected and displayed correctly, so that should be all completed. There is still an outstanding bug related to key signatures on a different version of Guitar Pro (http://musescore.org/en/node/23519), and that’s something that I would like to clean up next week if possible. The Guitar Pro file submitted with that bug report is pretty large in size, I’ll try to narrow that down a bit if possible before attempting to fix that bug. I certainly prefer the structure of the new Guitar Pro format (GPX) than that of the previous versions, having the score.gpif XML file means that we can see exactly what we’re dealing with when developing.

Dotted rhythms are also supported, for all notes, in the GPX format. I wanted to fix this as it corrected the wrong number of beats in the bar issue that I get on the test case that I’m using during development, though it’s certainly still possible to get that issue due to the lack of support for tuplets. Tuplet support has been started but there’s something that needs to be done before it’s completed. In its current state, ChordRests are initialised when we encounter a new Beat description. Unfortunately, it cannot be done this way in order to support tuples, as each beat specifies some notes and a rhythm, and whenever a tuplet is present in the rhythm, only one note out of that tuplet is specified in the beat. I’m not sure why they have chose to do it this way rather than specifying all the notes in the tuplet, perhaps that adds for greater flexibility in the specification of other information such as dynamics within each note of the tuplet. In any case, I see what they’re doing for this now, I need to make an edit to the way that we handle beats in order to handle this correctly.

I’ve also looked at work on how the clef is specified, and we should see the correct clef now appearing in GPX files for each instrument/part. This includes the percussive staff, which I have also added some support for. I have added back in support for MIDI note specifications that are present in score.gpif now that this is the case. There is still a little work to be done here, as drum notes specified in the Guitar Pro file are not parsed correctly yet.

I have looked at support for bends in the other Guitar Pro formats. There are all kinds of bends that users can specify in their scores and we should have support now for the majority of these. The feature we don’t have support for w.r.t. bends is the “Hold” feature, Musescore doesn’t have a good way to represent this yet so that’s something that I’ll need to add in later. Probably this will be denoted via a dotted line over the held section (likely using a spanner in Musescore terminology). Bends can of course be held on to the next line of the score, so however spanners work when they are spanned on to a new line of the score is something that I’ll have to investigate later. I’m not going to continue further work on bends likely until later in this project, as it’s a relatively minor feature compared with the rest of the things that I need to implement support for.

The issue that I talked about last week with respect to bends has been fixed. For some odd reason, it was possible for a call to Ms::Bend:layout to exist where a score did not exist. This call was present only during execution of mtest (the test framework) and not when run by the user. Once the issue was located it was fixed with a simple conditional statement to check the existence of the score. Support for bends (minor support for holds) is now present in the Musescore repository.

The fade-in issue is something that I’ve also been working on. There’s a slot for this in the articulation & ornaments portion of the side palette, and I’ve implemented a shortcut for that for reasons of faster development, which is something that may or may not stay when I’ve finished doing that, I would think some kind of shortcut will stay. I seem to have hooked up everything that I can see by following the implementation of other articulations, such as marcato, though I’m not seeing the fade in symbol for this yet from the font. There’s likely a line missing somewhere that I’ll need to find. Representing a font symbol for fades is something that Guitar Pro does, but it’s conceivable that one day we might want to draw this with a bezier curve and represent it as a spanner so that it can span across multiple bars.

All of the work on GPX support has been cleaned up a little and merged with the current master, so now I’ve added a pull request for the GPX support this morning so that everything can get merged together and then I can add pull requests on top of that, this support will likely appear in the Musescore repository some time this week.

Key tasks that stalled

Nothing in particular, the primary thing I wanted to hunt down was the bend bug that’s was stalling the last few weeks and this has now been located and fixed.

Overview of work for next week

I’ll make any changes to the GPX pull request that need to be made before it’s merged into the master branch, it’s a fairly large chunk of code so perhaps some of the devs would like edits. Getting the fade symbol displayed in the palette is something that I would like to see done, as well as attempting to locate the source of error in the bug report concerning key signatures in key signatures in previous Guitar Pro versions that I mentioned. Tuplet support in GPX files would also be a good thing to look at, and then perhaps the bugs at http://musescore.org/en/node/22888 , http://musescore.org/en/node/23074 , and http://musescore.org/en/node/22110 too, which is also related to tuplets (in a previous version of Guitar Pro). It occurs to me that these issues with bugs in tuplets might be due to the same reason that my tuplets aren’t working in the GPX format – if ChordRest values are instantiated to rests they can be redefined, losing tuplet information (a possibility, but I’m not certain on that yet, will need some testing). If I get through all of that then I’ll spend the rest of the time adding more support for GPX files.