aboutsummaryrefslogtreecommitdiff
path: root/src/adlmidi.cpp
diff options
context:
space:
mode:
authorWohlstand <admin@wohlnet.ru>2021-10-25 05:38:25 +0300
committerWohlstand <admin@wohlnet.ru>2021-10-25 05:38:25 +0300
commit50a8396eb61c665b07426c70a11c0b73ed950434 (patch)
tree4abdfe53b1910b1c977d8ac5687454384dd83803 /src/adlmidi.cpp
parent57a8d528e877d3810deaa1ce24545512e1a46ac9 (diff)
downloadlibADLMIDI-50a8396eb61c665b07426c70a11c0b73ed950434.tar.gz
libADLMIDI-50a8396eb61c665b07426c70a11c0b73ed950434.tar.bz2
libADLMIDI-50a8396eb61c665b07426c70a11c0b73ed950434.zip
Added an ability to set number of loops
Diffstat (limited to 'src/adlmidi.cpp')
-rw-r--r--src/adlmidi.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/adlmidi.cpp b/src/adlmidi.cpp
index c62c2cb..621c385 100644
--- a/src/adlmidi.cpp
+++ b/src/adlmidi.cpp
@@ -574,6 +574,21 @@ ADLMIDI_EXPORT void adl_setLoopEnabled(ADL_MIDIPlayer *device, int loopEn)
#endif
}
+ADLMIDI_EXPORT void adl_setLoopCount(ADL_MIDIPlayer *device, int loopCount)
+{
+#ifndef ADLMIDI_DISABLE_MIDI_SEQUENCER
+ if(!device)
+ return;
+ MidiPlayer *play = GET_MIDI_PLAYER(device);
+ assert(play);
+ play->m_sequencer->setLoopsCount(loopCount);
+#else
+ ADL_UNUSED(device);
+ ADL_UNUSED(loopCount);
+#endif
+}
+
+
ADLMIDI_EXPORT void adl_setSoftPanEnabled(ADL_MIDIPlayer *device, int softPanEn)
{
if(!device)