Importing MIDI or Capella files can create corrupted or empty measures

• Apr 3, 2013 - 02:48
Type
Functional
Severity
S4 - Minor
Status
active
Project
Tags

When you import a MIDI or Capella file, Musescore will often create completely empty measures (containing nothing at all, not even rests). Frequently in MIDI files, a part that has no more notes after some point in the score will simply end early.
Example: AnSylvia.mid, in which the vocal part is completely empty starting with measure 27 (I chose 64th-note minimum when importing, but that probably doesn't matter).
That doesn't matter when playing back a MIDI file, but they should get filled with rests when imported into a scorewriter. Screenshot: AnSylvia screenshot.png
Further, due to the related bug #9808: Empty beats/measures can't be selected or refilled in UI, the user cannot fix the empty measures after they are created by this bug. The UI doesn't seem to let you select them or enter notes into them.
Occasionally, I also see a corrupted (partially-filled) measure, in which the contents add up to less than the full time. Example: BWV_1016_3.cap; when imported into mscore 1.3 rev 5702, the second-to-last measure of the middle staff is short one 24th-note (triplet 16th-note).

Musescore should detect corrupted measures and fill the gaps with rests on import.

Possibly related: //musescore.org/en/node/12445

Attachment Size
BWV_1016_3.cap 19.92 KB
AnSylvia.mid 9.03 KB
AnSylvia screenshot.png 141.79 KB

Comments

Thanks for the bug report.
In (2.0) Nightly builds rev. 474256e (Win XP Professional SP3) the problem of empty measures in midi import seems to be no more a concern, BUT there are other serious problems (regressions with respect to 1.3), as shown in the image "midi_import.png".
First, some notes in chords are missing, see also http://musescore.org/en/node/19533.
Second, some notes are wrong, for example the final C double flat (corresponding to B flat) which indeed is A when opened with MuseScore 1.3.

For what concerns the import of the capella file, the problem in 1.3 seems to be in the final triplet of the middle staff, which in Capella Reader looks as in image "Cap_reader_tuplet.png". It seems that the last 16th note of the tuplet is not recognized as part of the tuplet and the tuplet itself is interpreted as a triplets of three 16th notes (image "MS1.3_tuplet.png"). Please note that the tuplet import for capella file is at the moment quite simple and works correctly only for triplets of three notes of the same length (ES: a triplet of three 8th notes, or a triplet of three 16th notes, et cetera).
When using the 2.0 Nightly Builds rev. 474256e (Win XP Professional SP3) the notes appear to have the right length in ticks, BUT the presence of triplets is not detected: when looking at the built-in debugger, there are no tuplets corresponding to the chords. The problem with the final tuplet is still present as in 1.3.
- With my personal builds ( revision 2f265da , Qt 4.8.4, MinGW-gcc 4.7.2, debug mode; both Qt and MinGW from MinGW-builds, Win32, posix, sjlj exception handling), I experience a crash when opening this capella file. Moreover, in the command line it displays a series of warnings about tuplets (with double question marks "??") and slurs, just before crashing.

Attachment Size
midi_import.png 66.73 KB
MS1.3_tuplet.png 42.7 KB
Cap_reader_tuplet.png 12.47 KB

The problem with the MIDI file (missing notes and wrong pitch) are now fixed in rev. 69ce400d43

The capella file does still give errors during importing.