Convert musicxml to wav?
Asked Answered
M

3

2

How I can get a wav from a musicxml file ? I tried this javascript package.

I am getting various errors, different for each file, but mostly

"Cannot read property 'score-partwise' of undefined"

. I can't seem to find anything else.

Do you know something reliable ?

Maibach answered 18/11, 2015 at 8:45 Comment(4)
have you tried out any of these: musicxml.com/software ?Nik
I looked at what these software, mostly they're for writing music, none of them seem to be able to record the sound made by the xml music fileMaibach
superuser.com/questions/180325/…Nik
I think this is supposed to be answer to my comment your answer, not this one. Thanks anyway, with that + your answer I reckon I have everything I needMaibach
N
2

musicXML is a format that describes musical notation (scores). (not the actual soundwaves produced while playing something, like a wave recording in a *.wav file)

the xml can mostly be converted into MIDI notations, and given a MIDI synthesizer synthetic instruments can play the scores and this can generate the soundwaves found in a wav file.

almost all the converters out there go through this process XML->midi->wav

There is plenty of xml->midi converters. the quality of the wav file depends strongly on the midi->wav converter part.

I have only played the stuff, never actually produced files, but have never had any problems, using http://www.programfabriken.com/

Nik answered 18/11, 2015 at 9:9 Comment(2)
Thank you, it plays well. Any idea how I can record the sound played to a file ? I might be able to tweak the source code to do this otherwise. Anyway I will look into XML to midi and then midi to wav though, sounds more promisingMaibach
Someone just needs to invent MusicCSS now.Semolina
M
0

Just to quickly add this information here as well:

MusicXML are just the notes. To convert it to WAV, you'll need to actually "play" it.

As you need a font for displaying text, you need a way to make these notes play a sound. There are other ways, but what often is referred to as soundfonts had the best quality to me so far. As fonts contain a representation of each character, soundfonts contain a recording of each instrument played in a variation (normal, stacato, etc). As instruments and their players differ in sound, there also is quite a variety of soundfonts. If you want very good quality, I guess you'll have to buy a package like Logic Pro X by Apple, which currently contains a library of Over 2700 instrument and effect Patches. Nevertheless, there are also quite some good free alternatives available. Here are some I found on a quick research:

When you got hands on them, you'll just need a notation program which supports importing them, like the free MuseScore: https://musescore.org/en/handbook-sound-and-playback/soundfonts

But MuseScore seems to be a manual work. Maybe you can automize it, or you'd have to take a look for another program/library.

Mountbatten answered 25/9, 2017 at 5:35 Comment(0)
S
0

Rosegarden 19.12 on Ubuntu 20.04 can import MusicXML and export MIDI. I just haven't gotten it to work on Ubuntu yet, likely due to: https://askubuntu.com/questions/510052/how-do-you-get-rosegarden-to-play-sound-when-playing-a-midi-in-it Then you can convert MIDI to anything with timidity + ffmpeg: Convert midi to mp3

Semolina answered 23/11, 2020 at 18:54 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.