diff --git a/VERSION b/VERSION index fdde57e..e0f22f7 100644 --- a/VERSION +++ b/VERSION @@ -1,2 +1,2 @@ -2021 January 24 2021 +2021 February 21 2021 diff --git a/doc/CHANGES b/doc/CHANGES index 6c61fe5..76d3bbb 100644 --- a/doc/CHANGES +++ b/doc/CHANGES @@ -14086,4 +14086,25 @@ Hooks to new instructions !accent! !mordent!, !sfz!, !wedge! were added to the function event_handle_instruction() in store.c. +February 21 2021 + +Abc2midi bug: unfortunately the fix applied to add_missing_repeats +applied on January 21 2021 caused a new problem for single voice files. +For example: + +X: 1 +T: repeat bug +R: jig +M: 6/8 +L: 1/8 +K: G +D |"G" ~G3 GAB |"D"ABA ABd | "G"edd gdB | "D"AGF "G"G2 :: + A | "G"BAB dBd| "Em"ege "G"dBd | gfg "D"aga | "G"bgf g2 :| + +Those files do not contain a VOICE feature, so that the fix results +in the leftrepeat being misplaced. The problem was repaired by +testing the varieable voicesused before searching for the VOICE feature. + + + diff --git a/doc/readme.txt b/doc/readme.txt index 68fece9..be42127 100644 --- a/doc/readme.txt +++ b/doc/readme.txt @@ -1,7 +1,7 @@ abcMIDI : abc <-> MIDI conversion utilities midi2abc version 3.47 November 01 2020 -abc2midi version 4.47 January 24 2021 +abc2midi version 4.49 February 21 2021 abc2abc version 2.12 October 19 2020 yaps version 1.86 December 10 2020 abcmatch version 1.77 December 10 2020 diff --git a/store.c b/store.c index 56702d6..0cc24f2 100644 --- a/store.c +++ b/store.c @@ -186,7 +186,7 @@ int main() */ -#define VERSION "4.47 January 24 2021 abc2midi" +#define VERSION "4.49 February 21 2021 abc2midi" /* enables reading V: indication in header */ #define XTEN1 1 @@ -4707,6 +4707,13 @@ if (nofnop == 0) { done = 1; }; +/* The following instructions were added to avoid numerous + warnings if they appear in the abc file (in particular the + files derived from Craig Sapp's kern files using hum2abc). + Though most of these instructions are part of the abc + 2.2 standard, I have yet to implement them. +*/ + if (strcmp(s,"accent") == 0) { /* [SS] 2021-01-24 */ done = 1; }; @@ -4723,6 +4730,10 @@ if (nofnop == 0) { done = 1; }; + if (strcmp(s,"turn") == 0) { /* [SS] 2021-01-25 */ + done = 1; + }; + if (done == 0 && quiet == -1) { /* [SS] 2013-11-02 */ sprintf(buff, "instruction !%s! ignored", s); event_warning(buff); @@ -6023,10 +6034,12 @@ for (i = num2add-1; i >= 0; i--) { leftrepeat = add_leftrepeat_at[i]; k=0; /* [SS] 2021-12-21 */ +if (voicesused) { /* 2021-02-21 */ while (feature[leftrepeat] != VOICE && k < 20) { leftrepeat++; k++; } +} insertfeature(BAR_REP,0,0,0,leftrepeat+1); /* for (j=0;j<=parts;j++) { [SS] 2011-06-06 */ for (j=0;j<26;j++) { /* [SS] 2011-08-03 */