musescore / MuseScore

MuseScore is an open source and free music notation software. For support, contribution, bug reports, visit MuseScore.org. Fork and make pull requests!
https://musescore.org
Other
12.18k stars 2.64k forks source link

D.C. (or D.S.) al Fine marking right before a section break causes the pause between sections to happen at the wrong time (4.42) #24832

Open BoBogus opened 3 weeks ago

BoBogus commented 3 weeks ago

Issue type

General playback bug

Description with steps to reproduce

  1. Create a new score with any instrumentation.
  2. Add a section break at any given measure. Make sure it is set to pause for some duration between sections.
  3. On the same measure as the section break, add a D.S. al Fine or D.C. al Fine.
  4. If using D.S. al Fine, add a segno in an earlier measure.

Expected behavior: On reaching the D.S. or D.C. marking, it should immediately jump to the capo or segno and begin playing back from there. Then, on reaching the Fine, it should pause as set in the section break properties before starting the next section.

Actual behavior: On reaching the D.S. or D.C. marking, the cursor jumps to the appropriate place, but then unexpectedly pauses as though it's about to start the next section. After the pause, it plays from the capo or segno as originally intended. Finally, when it reaches the Fine, it immediately begins playing the next section without a pause.

Supporting files, videos and screenshots

Broken Section Pauses.zip

What is the latest version of MuseScore Studio where this issue is present?

OS: Windows 10 Version 2009 or later, Arch.: x86_64, MuseScore Studio version (64-bit): 4.4.2-242570931, revision: github-musescore-musescore-3130f97

Regression

I was unable to check

Operating system

Windows 10 Pro, 64-bit

Additional context

No response

Checklist

Jojo-Schmitz commented 3 weeks ago

Duplicate of #14262 , I believe

BoBogus commented 3 weeks ago

I guess this is an additional case, since that appears to mimic what I'm seeing. I also see that it's a long-standing issue.

Something that has occurred to me is that the section break isn't relevant until after the repeat or jump has occurred. Do you know if MuseScore's playback engine handles repeats and section breaks in any particular order on measures where both are present?

jeetee commented 3 weeks ago

The data structure that unrolls the playback order processes repeats and jumps before section breaks. However the part of code that turns that information into playback instructions hasn't been updated to process that subset of the information yet..

BoBogus commented 3 weeks ago

Interesting. Are there any plans at this time to update it?

Jojo-Schmitz commented 3 weeks ago

Up to @jeetee, the master of repeats 😉