mirror of
https://github.com/sshlien/abcmidi.git
synced 2025-12-08 10:41:02 +00:00
Compare commits
3 Commits
2022.02.07
...
2022.02.21
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eaf451d6ad | ||
|
|
cded63b590 | ||
|
|
57a5ae2ba7 |
72
doc/CHANGES
72
doc/CHANGES
@@ -14590,3 +14590,75 @@ G2 B2 |\
|
||||
%%MIDI pitchbendrange 7
|
||||
!bend! G4 |
|
||||
|
||||
February 12 2022
|
||||
Midi2abc -mftext: adjusted the pitchbend sensitivity bend2cents when
|
||||
a RPN control command is received (in function mftxt_parameter).
|
||||
|
||||
February 13 2022
|
||||
abc2midi: added an optional third parameter to %%MIDI bendvelocity
|
||||
which specifies the number of MIDI pitchbend messages to create.
|
||||
If this parameter is missing, the default is 8 as before.
|
||||
|
||||
|
||||
February 18 2022
|
||||
abc2midi bug: the K: and V: score option transposes the music in the
|
||||
wrong direction. eg
|
||||
|
||||
X:1
|
||||
T: transpose
|
||||
M: 4/4
|
||||
L: 1/4
|
||||
K: G sound = DC
|
||||
CDEF|GABc|
|
||||
|
||||
CDEF... converted to BbCDE.. instead of DEF#G...
|
||||
|
||||
Fix: swapped p2 and p1 in
|
||||
*transpose = p2 - p1;
|
||||
in parsesound() in parseabc.c
|
||||
|
||||
February 21 2022
|
||||
abc2abc mangles text. eg
|
||||
input:
|
||||
|
||||
X:1
|
||||
T: Text mangled by abc2abc
|
||||
Q:1/2=120
|
||||
M:4/4
|
||||
L:1/8
|
||||
K:G bass octave=-2
|
||||
%%begintext center
|
||||
this text is mangled
|
||||
%%endtext
|
||||
%%
|
||||
!f! g2 z d g2 z d | gdgb d'2 z2 | c'2 z a c'2 z a | cafa d2 z2 | gggg gggg | [I:repeat] |
|
||||
|
||||
abc2abc text.abc -t 2 >output.abc
|
||||
|
||||
output:
|
||||
|
||||
X:1
|
||||
T:Text mangled by abc2abc
|
||||
Q:1/2=120
|
||||
M:4/4
|
||||
L:1/8
|
||||
K:Amaj clef=bass octave=-2
|
||||
%%begintext center
|
||||
this tfxt is mbnalfe
|
||||
%%endtext
|
||||
%%
|
||||
!f! a2 z e a2 z e | aeac' e'2 z2 | d'2 z b d'2 z b | dbgb e2 z2 | aaaa aaaa | [I:repeat] |
|
||||
|
||||
Analysis:
|
||||
Parseline (line) in parseabc.c checks the line for %%begintext using strcmp.
|
||||
Unfortunately, it does not find a match because the line also contains
|
||||
the word 'center'.
|
||||
|
||||
Fix: replaced
|
||||
if (strcmp(line,"%%begintext") == 0) {
|
||||
with
|
||||
if (strstr(line,"%%begintext") != NULL) {
|
||||
which returns the pointer to %%begintext in the line.
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
abcMIDI : abc <-> MIDI conversion utilities
|
||||
|
||||
midi2abc version 3.48 June 27 2021
|
||||
abc2midi version 4.66 January 27 2022
|
||||
abc2abc version 2.15 May 25 2021
|
||||
yaps version 1.87 May 25 2021
|
||||
midi2abc version 3.50 February 12 2022
|
||||
abc2midi version 4.69 February 22 2022
|
||||
abc2abc version 2.16 February 22 2022
|
||||
yaps version 1.88 February 22 2022
|
||||
abcmatch version 1.80 November 25 2021
|
||||
midicopy version 1.37 October 10 2020
|
||||
|
||||
|
||||
@@ -2074,14 +2074,17 @@ int noteson;
|
||||
skipspace(&p);
|
||||
val = readsnump(&p);
|
||||
bendacceleration = val;
|
||||
skipspace(&p); /* [SS] 2022-02-13 */
|
||||
val = readsnump(&p);
|
||||
if (val > 0 && val < 100) bendnvals = val;
|
||||
else bendnvals = 8;
|
||||
|
||||
/* [SS] 2015-08-11 */
|
||||
bendnvals = 0;
|
||||
if (bendvelocity != 0 || bendacceleration != 0) {
|
||||
for (i = 0; i<8; i++) {
|
||||
for (i = 0; i<bendnvals; i++) { /* [SS] 2022-02-13 */
|
||||
benddata[i] = bendvelocity;
|
||||
bendvelocity = bendvelocity + bendacceleration;
|
||||
}
|
||||
bendnvals = 8;
|
||||
}
|
||||
/*bendtype = 1; [SS] 2015-08-11 */
|
||||
if (bendnvals == 1) bendtype = 3; /* [SS] 2014-09-22 */
|
||||
|
||||
@@ -1056,7 +1056,7 @@ parsesound (s, word, gottranspose, transpose)
|
||||
*transpose = 0;
|
||||
} else {
|
||||
/* printf("midi note = %d\n",p2); */
|
||||
*transpose = p2 - p1;
|
||||
*transpose = p1 - p2; /* [SS] 2022.02.18 */
|
||||
/* printf("transpose = %d\n",*transpose); */
|
||||
*gottranspose = 1;
|
||||
}
|
||||
@@ -3353,11 +3353,11 @@ parseline (line)
|
||||
{
|
||||
char *p, *q;
|
||||
|
||||
/* [SS] 2020-01-03 */
|
||||
if (strcmp(line,"%%begintext") == 0) {
|
||||
/* [SS] 2020-01-03 2021-02-21 */
|
||||
if (strstr(line,"%%begintext") != NULL) {
|
||||
ignore_line = 1;
|
||||
}
|
||||
if (strcmp(line,"%%endtext") == 0) {
|
||||
if (strstr(line,"%%endtext") != NULL) {
|
||||
ignore_line = 0;
|
||||
}
|
||||
/* [SS] 2021-05-09 */
|
||||
|
||||
2
store.c
2
store.c
@@ -186,7 +186,7 @@ int main()
|
||||
|
||||
*/
|
||||
|
||||
#define VERSION "4.66 January 27 2022 abc2midi"
|
||||
#define VERSION "4.70 February 22 2022 abc2midi"
|
||||
|
||||
/* enables reading V: indication in header */
|
||||
#define XTEN1 1
|
||||
|
||||
2
toabc.c
2
toabc.c
@@ -21,7 +21,7 @@
|
||||
|
||||
/* back-end for outputting (possibly modified) abc */
|
||||
|
||||
#define VERSION "2.15 May 25 2021 abc2abc"
|
||||
#define VERSION "2.16 February 21 2022 abc2abc"
|
||||
|
||||
/* for Microsoft Visual C++ 6.0 or higher */
|
||||
#ifdef _MSC_VER
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
/* yapstree.c - back-end for abc parser. */
|
||||
/* generates a data structure suitable for typeset music */
|
||||
|
||||
#define VERSION "1.87 May 25 2021 yaps"
|
||||
#define VERSION "1.88 February 22 2022 yaps"
|
||||
#include <stdio.h>
|
||||
#ifdef USE_INDEX
|
||||
#define strchr index
|
||||
|
||||
Reference in New Issue
Block a user