GSoC 2020: Tree Model - Week 9

Posted 4 years ago

Hi! This is another progress update blog for my GSoC project.

Last week I had my college vivas and seminar until Wednesday. After that, I have started working again on the write function refactoring.
The main progress I have made is, I have written from scratch a virtual treeWrite() function, and made it match somewhat with the current mscx format by reimplementing it in the top-level classes.

Here's a link to diffs between the original and new files produced by treewrite.cpp: (1) layout_elements.mscx (2) moonlight.mscx

Screenshot from 2020-08-04 14-49-41.png

It looks like Notes and Chords are mostly output correctly, however, Tuplets and Beams and Spanners will need to be handled specially.
Also, I have to write some code to decide which elements are to be written into the XML and which are not.

I have figured out that the new property system I was trying to make was not really required, and I have instead tried to use the existing system. I will have to add many new properties for each element.

I have opened a WIP Pull request here.

The target for this week is:
1. I will reduce the diff between the original and new mscx format as much as possible.
2. I will add many new properties into Pid.
3. I will make sure that treeWrite is working like before for most of the elements.

Other links:

WIP Pull request: https://github.com/musescore/MuseScore/pull/6405
Previous Blog: https://musescore.org/en/user/1743616/blog/2020/07/27/gsoc-2020-tree-mo…
Next Blog: https://musescore.org/en/user/1743616/blog/2020/08/11/gsoc-2020-tree-mo…