Loop (partial) playback feature

• Aug 7, 2013 - 04:21

Here's a preview of what I've been working on for a loop playback feature.

To loop the whole score (already available in MuseScore 2.0)

1. Clic on the loop button in the toolba to activate the Loop fonction
2. Press Spacebar to play the score and start the loop.
3. MuseScore will start from the beginning of the score and restart when it reached the end of the score.

To loop part of the score (on my local computer branch)

1. Clic on the first note, then press Shift+I to set the loop start position (In).
2. Clic on the last note, then press Shift+O to set the loop end position (Out).
3. Clic on the loop button in the toolbar to activate the Loop fonction
4. Press Spacebar to play that part of the score in loop.

The In/Out positions remain active until we uncheck the loop button.

Here's a short video of the partial loop feature : //youtu.be/XNsmGGGx2F8

We can change the tempo/volume. We can also add the metronome, but for that, there a little glitch on the repeat between the last beat and the first beat of the repeat.

Any comments or questions?


I mainly use MuseScore to practise for choir singing. So being able to select an arbitrary section of the whole score is something, which will make MuseScore much more useful for me. The short video was absolutely convincing. Any idea, when this feature will be available?



In reply to by vgStef

For my choir I did so:
Save to wave and use the loop function of Vlc (because it is open-source, intuitive and the commands are essential, only one button to start / end loop).
A built-in functionality would be very useful for teaching, so my best wishes for your idea.
(I attach a image as hypothesis).

Attachment Size
loop.png 37.78 KB

nice, very useful feature

but wouldnt it be easier to loop a selection other than having to set the start/end position?

In reply to by mjbg

You don't need to set the in and out position for the loop!

If you only click the loop button, the whole score will restart.

But if you want to loop only part of the score, you need to tell MuseScore where to start and where to end! That's why you can also set the In position and/or the Out position.

I've updated the Playpanel and the way the button works. Here's the latest version : //youtu.be/Hw6q55OK-bE

In reply to by vgStef

The loop facility looks brilliant, I can't wait to try it out.
I use MuseScore a lot to practice playing music that I am learning. If the loop starts playing as soon as I press play then I won't have time to move my hands from the computer keyboard to the instrument I am playing.

It would be very helpful if the play panel could include an option to add a number of bars count in before play commences.
If set to 0 then the play would start immediately. If set to 1 there would be one bars count in, 2 then two bars count in etc.

This count in would apply to all playback whether looping or just playing the tune through, it could just sound the metronome for the count in bars.

What do you think? Would this be easy for you to add?

Kind regards


In reply to by aum7

Hum, that's starting to be a bit more complex if the playback doesn't follow the score. I would recommend you simply add a few empty measures at the beginning of the segment you want to loop. All you need to do is press the Insert button on your keyboard to add a measure. Then set the In and Out position for your loop. After, you press Ctrl+Delete to remove the measure.

In reply to by schepers

I downloaded the nightly build for Musescore 2 today and started trying out the new loop and count in features. I am really impressed with them. Many thanks to everyone involved in their implementation.

The one thing that would be helpful if at all possible would be an option to select the number of bars to count in. The single bar count in is useful, but it is a bit of a rush on 3/4 time music to start the playback and then be ready with my instrument by the time the playback commences. An option to select say from 0 up to a 4 bar count in would allow some flexibility whilst allowing time to get ready in time for the start of play back. 0 could be used effectively to turn of count in allowing for a simple roll over object in the play panel to replace the count in button.

What do you think?

Kind regards


In reply to by vgStef

I agree with Marc. In my opinion the most convenient way to tell MuseScore to know where to stop and end is to use the beginning of the selected range for the start, and the end of the selected range as the end. If there is no selection, then loop the entire score. Doesn't that seem simpler than introducing a whole new control to select a range?

Great implementation of my wishes! Handy settings in the play panel.

The trick is to be able to edit the music in the marked section and replay the result.
I have changed two quarters in a section to a dotted quarter and an eight. The begin and end color markers get disturbed, although the selection seems to play right. Same happens when i insert a measure in between two marked measures.

Just changing the pitch of notes in marked section works fine!

A perfect kandidate for the next release! Keep on going!

Sorry to hear that this would be complicated to implement.

I appreciate what you are saying regarding looping. It would not be particularly inconvenient to select a couple of bars earlier than the start of the section that you wanted to practice, so that these additional bars could act as the count in (unless you are starting your loop from the start of the piece of music).

At present I am documenting music scores for a dance group, so I have to produce two versions of the music, one to print out and play from, and one to practice with by playing along to it in MuseScore. The latter version has to include additional bars at the start of the music to provide a count in. Having a feature in the play panel that allowed you to set how many count in bars you wanted played before the score itself commenced playing would have removed the need to add these count in bars to my scores.

Similarly I use MuseScore to improve my accordion playing, and again when I type in exercises from my tutor book I have to add count in bars to each one.

If the loop feature did not utilise the count in, so as to keep the loop feature simple, would it be that difficult for the count in to function only if the score was being played from the first bar?

Kind regards



Loop playback would be great! I could play slowly by ear and by notation, and I believe combining both would help me learn faster and even somehow improve my sight reading skill!. But I'm worried that selecting notes with key combinations may be a little complex/unintuitive and would prevent the feature from being used? Would it be possible to use toolbar buttons or menu items instead? I'm assuming that these key combinations would be shortcut keys of something that can be done via mouse instead of a "advanced secret function".

Ideally one would just make a selection and then press a "play with loop" or toggle a loop mode button just beside playback. I liked this feature in Guitar Pro (I think also Reaper). But I guess, that depends on playback/select implementation. So another suggestion I have is similar to Synthesia where you have a special select mode, maybe hold down a key while selecting. Or a right click menu on the "normally selected" region that would implement what the shift I and shift O are doing?

Just sharing my random ideas. Feel free to shoot down! :-)


In reply to by makoto314

Thanks and congratulations for the very intuitive implementation! I just tested out nightly to see what's new with the mixer/synthesizer... Glad to see loop play back works on the selected notes! Keep up the great work! :-)

Since practicing and editing are different things, I could happily practice piano using a nightly. Thanks again!

Here's an update of the loop playback feature.

Now, it's possibile to have the loop follow the repeat signs in the score. If the repeat button is checked, the loop will respect the repeats.

Here I include two files I used to test the feature.
File "test - Barline2" has repeats in the middle of the score.
File "test - Barline3" has a repeat at the end of the score.

So if a repeat bar is present between the In and the Out loop positions, it will be taken into consideration and the whole repeat section will be played.

Any comments?

Attachment Size
test - Barline2.mscz 1.42 KB
test - Barline3.mscz 1.42 KB

Maybe a workaround:
in editing modus: go with cursor to loop-start, press space bar to play, at end of loop press space bar 2 times to repeat loop.

Do you still have an unanswered question? Please log in first to post your question.