Skip to content

MIDI export: apply accent- and marcato-based compound articulations - #34706

Open
hashimh4 wants to merge 1 commit into
musescore:mainfrom
hashimh4:fix-31432-compound-articulations
Open

MIDI export: apply accent- and marcato-based compound articulations#34706
hashimh4 wants to merge 1 commit into
musescore:mainfrom
hashimh4:fix-31432-compound-articulations

Conversation

@hashimh4

Copy link
Copy Markdown

Resolves: #31432

Accent-staccato, accent-tenuto, marcato-staccato and marcato-tenuto were missing from s_builtInArticulationsValues, so MIDI export applied neither their shortening nor their velocity change, although MuseScore plays them correctly. The values follow the decomposition in ARTICULATION_ABOVE_SPLIT_GROUPS. Scores that store an instrument articulation list resolve through it as before and are unaffected.

Built in CI; I tested the resulting Windows build against the score attached to the issue, and its export before the fix is byte-identical to the reporter's own.

  • I signed the CLA as hashimh4
  • The title of the PR describes the problem it addresses.
  • Each commit's message describes its purpose and effects, and references the issue it resolves. If changes are extensive, there is a sequence of easily reviewable commits.
  • The code in the PR follows the coding rules.
  • I understand all aspects of the code I'm contributing and I'm able to explain it if requested.
  • The code compiles and runs on my machine, preferably after each commit individually. I have manually tested and verified that my changes fulfil their intended purpose.
  • No prior attempts to resolve this problem exist, or if they do, I listed them in my PR description and described how I avoided repeating past mistakes.
  • There are no unnecessary changes.
  • I created a unit test or vtest to verify the changes I made (if applicable).

Accent-staccato was exported with no shortening and no velocity change, even
though MuseScore plays it correctly. symId2ArticulationName() calls these
symbols sforzatoStaccato, sforzatoTenuto, marcatoStaccato and marcatoTenuto,
and none of those names were in s_builtInArticulationsValues.
fillArticulationsInfo() only walks that map, so updateGateTime() and
velocityMultiplierByInstrument() fell back to the instrument articulation list,
which a score made in MuseScore 4 does not have.

The values come from ARTICULATION_ABOVE_SPLIT_GROUPS: velocity of the accent or
marcato, gate time of the staccato or tenuto. Scores that do carry an instrument
articulation list are unaffected.

Resolves: musescore#31432
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.

Accent-staccato articulation is not reflected in MIDI export

2 participants