You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I have Mei file containing repetitions. I want to produce a midi file which has all the repeated parts as noted in song. I also need for this midi file the timemap and svg.
Describe the solution you'd like
Please see example here. (I removed some parts, to avoid copyright issues).
The song has repetitions. My idea is, to have a function which returns a new Mei document as XML.
const char *vrvToolkit_flattenRepetitions(void *tkPtr, int maxRepeatCount = 0);
The new Mei XML document has the repetitions removed and instead the measures are duplicate exactly the way how you would play it if you follow the repetition symbols. With an optional argument maxRepeatCount you can control, that instead of 5 repetitions like in the example, it should repeat only e.g. 2 times.
For the given example with maxRepeatCount = 2, you will get a new Mei document with 33 measures.
The solution is more or less duplicating and rearranging the measures within the MEI xml document.
(And removing the repetition symbols from the xml document)
The text was updated successfully, but these errors were encountered:
If I understand correctly, this is similar to what happens with the --expand option set. However, I think this goes further in the direction of data transformation, and this might be beyond what one would reasonably expect to be available in Verovio. It would be good to hear from @wergo since he knows more about the --expand implementation.
I didn't find an official documentation for the expand functionality. This is my understanding, what I found out by reading the open issues for --expand
This functionality is a console command only, it cannot be used from the API
The functionality requires that there are additional marker tags in thei MEI document which controls the repetition flow
These additional markers are not created by the functionality but they must exist
You are completely right, this does not belongs to the base functionality of Verovio but goes to data transformation. I try currently to build this in my client code, by not requiering special markers but by analysing the ending tags / jump instructions (da capo / dal
segno ...) and so on.
What I also see, for the flattened mei document it is interesting to know, which calculated measure belongs to which source measures. S.th. like that:
["ms1": ["mc1","mc2"], "ms2": ["mc3","mc4"]]
This gives me the information:
For source measure ms1, the calculated measures with IDs mc1 and mc2 were created
For source measure ms2, the calculated measures IDs mc3 and mc4 were created
Is your feature request related to a problem? Please describe.
I have Mei file containing repetitions. I want to produce a midi file which has all the repeated parts as noted in song. I also need for this midi file the timemap and svg.
Describe the solution you'd like
Please see example here. (I removed some parts, to avoid copyright issues).
The song has repetitions. My idea is, to have a function which returns a new Mei document as XML.
const char *vrvToolkit_flattenRepetitions(void *tkPtr, int maxRepeatCount = 0);
The new Mei XML document has the repetitions removed and instead the measures are duplicate exactly the way how you would play it if you follow the repetition symbols. With an optional argument
maxRepeatCount
you can control, that instead of 5 repetitions like in the example, it should repeat only e.g. 2 times.For the given example with
maxRepeatCount = 2
, you will get a new Mei document with 33 measures.The solution is more or less duplicating and rearranging the measures within the MEI xml document.
(And removing the repetition symbols from the xml document)
The text was updated successfully, but these errors were encountered: