3

我正在尝试将整个巴赫语料库(mxl 文件)转换为 abc 文件。这在music21中可能吗?

谢谢!v

4

3 回答 3

3

music21目前没有导出 abc 的能力,只能导入。

于 2017-03-20T21:03:51.583 回答
1

你可以用 node 和 xml2abc 破解一些东西。Mxl 是 zip 文件中的 musicxml。

这是我在 zupfnoter 中使用的代码片段;它

function pasteXml(text){
                        try{
                          var xmldata = $.parseXML(text);
                         }
                        catch(ex){
                          #{$log.error(`ex.message`)}
                        }

                        var options = {
                                'u': 0, 'b': 0, 'n': 0,    // unfold repeats (1), bars per line, chars per line
                        'c': 0, 'v': 0, 'd': 0,    // credit text filter level (0-6), no volta on higher voice numbers (1), denominator unit length (L:)
                        'm': 0, 'x': 0,           // with midi volume and panning (1), no line breaks (1)
                        'p': 'f'
                      };              // page format: scale (1.0), width, left- and right margin in cm

                      result = vertaal(xmldata, options);
                      return result;
}

function pasteMxl(text){
   zip = new JSZip(text);
   text = zip.file(/^[^/ ]*\.xml$/)[0].asText();
   pasteXml(text);
}
于 2017-05-04T20:47:03.940 回答
0

您是否尝试过此 Web 服务?http://www.mandolintab.net/abcconverter.php

于 2017-03-21T12:45:28.847 回答