Register - Login
Views: 87833885
Main - Memberlist - Active users - Calendar - Wiki - IRC Chat - Online users
Ranks - Rules/FAQ - JCS - Stats - Latest Posts - Color Chart - Smilies
12-15-17 12:23:36 AM

Jul - SM64 Hacking - Mario 64 MusicXML Importer New poll - New thread - New reply
Pages: 1 2 3Next newer thread | Next older thread
messiaen
Catgirl
Level: 64


Posts: 864/1085
EXP: 2167292
For next: 46805

Since: 11-20-07


Since last post: 3.0 years
Last activity: 2.0 years

Posted on 05-23-10 01:29:03 PM (last edited by messiaen at 05-23-10 01:29 PM) Link | Quote
So this weekend I had some time to work again on the new music importer and decided to unveil it a bit more and explain how the importing process will work.

First, for those wondering, what the heck is MusicXML? MusicXML is a XML-based music notation format designed by Recordade so that different music notation programs can swap data around, since each one of the leading notation programs use their own different proprietary formats.

The reason I chose MusicXML as input is because it's an easy format to deal using .NET C# Xml libraries. Dealing with MIDI files would be harder since it can get incredible messy, especially in polyphonic settings. On other hand, this new music importer will be highly dependant of whatever music notation software you use to convert MIDI -> MusicXML.

One disadvantage of working with MusicXML is that it doesn't usually handle MIDI events such as pitch bends, volume/modulation changes (unless this is somehow incorporated in the notation, such as crescendo/decrescendo or dynamic signs). Still, it's a huge improvement over the old mml2m64, which due to the limitations of MML format couldn't deal with chords in the same channel and complex rhythms.

So, what are these notation programs I'm talking about? Unfortunately, the best three are all commercial products: Finale, Sibelius and Encore (by far the easiest to use). There is also a free, open source alternative, MuseScore, which can get decent results on simpler files but may mess up on more complex ones.

Let me show you a bit the steps of the importing process, using the Final Fantasy 7 Highwind theme (just because I used it in this video). First, I downloaded two MIDI versions of it from vgmusic.com. Before converting to MusicXML, it's important to choose the cleaner version, in which you can't spot obvious notation mistakes:

First MIDI File in MuseScore:



First MIDI File in Encore:



Second MIDI File in MuseScore (much neater!):



Second MIDI File in Encore:



Even without expert knowledge on music notation, it should be clear that the second file is much better than the first. Now it's time to export to MusicXML
(important tip: if it LOOKS good, it will probably be imported nicely) and open it with the importer interface:



In the importer interface, you can map each part to a specific instrument (depending on which instrument set you choose) and assign other parameters such as volume, pan and transposition. You can choose the same part twice, ie, if you want a specific part to be played by two instruments at once.

Once everything is set, the .m64 file is generated and you can insert it into the game (haven't worked yet into the inserter interface).

Before anyone asks, no estimated release date!, but I'll try to keep you guys updated and if someone wants to send a MusicXML file I can try and see how well it works and explaing why it will or won't work.
Me-me
340
Level: 39


Posts: 111/341
EXP: 387390
For next: 17381

Since: 08-05-07


Since last post: 5.0 years
Last activity: 3.0 years

Posted on 05-23-10 04:22:28 PM Link | Quote
Cool, music editing is also very important to make original mods. I'm eagerly waiting for it's release, but I'll also be patent
By the way, if you haven't noticed, I sent you an XML file. I've been constantly trying to get it to sound good in the game, but no, it just don't want to. Hope it works better with the new importer.
messiaen
Catgirl
Level: 64


Posts: 866/1085
EXP: 2167292
For next: 46805

Since: 11-20-07


Since last post: 3.0 years
Last activity: 2.0 years

Posted on 05-23-10 05:20:03 PM (last edited by messiaen at 05-23-10 05:27 PM) Link | Quote
The file you sent to me is a very good candidate for a nice import: neatly organized subdivisions and not too much polyphony in the same staff. By the way, did you use MuseScore?

The only part that doesn't work very well are the harp glissandi, that maybe would need a minor rewrite (in the music notation) in order to work 100%. It would be nice to try the same MIDI file with other notation programs (if you have access to them).

Here is the result: evo.mp3. This is how my settings looked like:



That reminds me I have to adjust the volume parameter, it needs more precision since samples have very different volumes, depending on which range you use them. Pan (balance between L and R channel) can also be used for that purpose.

One problem is that the resulting file was way too big, which can result in crashes. I have to check, but I'm pretty sure your original MIDI repeats twice. In order to deal with that, you have to find the point where the music starts to repeat, cut everything after that and let the game loop it.

Another item in my "To Do" list is an introduction setting, in case your file needs to loop after a few measures of introduction.
Me-me
340
Level: 39


Posts: 112/341
EXP: 387390
For next: 17381

Since: 08-05-07


Since last post: 5.0 years
Last activity: 3.0 years

Posted on 05-24-10 11:49:52 AM (last edited by Me-me at 05-24-10 12:07 PM) Link | Quote
Sounds good, but the melody (check it in a editor if you don't know wich) seems to be out of sync.
It goes to fast and finishes before the other instruments finish. But it was a big improvement! I was quite happy about it.
And yes, being the cheapskate I am I used MuseScore.
I don't have any money to spend on the better ones, but maybe they have a free trial period at least? I'll check it out.

"My" MIDI repeats twice and many others on vgmusic does, but I found a online MIDI editor and it's free to use!
Here's a link: http://midi.mathewvp.com/index.htm

Isn't transposition used to delay notes? Frankly, I don't know what it means. Heheheh, language barriers.
So can you please tell me what it means? Sorry for the inconvenience.
Lyskar
12210
-The Chaos within trumps the Chaos without-
Level: 183


Posts: 5593/12211
EXP: 83374225
For next: 1126878

Since: 07-03-07
From: 52-2-88-7

Since last post: 3.0 years
Last activity: 2.0 years

Posted on 05-24-10 03:36:08 PM Link | Quote
IIRC, Transposition means to move the notes up or down some notes, making them as a whole higher pitched or lower pitched.

Useful in this case as what sounds good on MIDI instruments may not in the same pitch on SM64 instruments.
messiaen
Catgirl
Level: 64


Posts: 868/1085
EXP: 2167292
For next: 46805

Since: 11-20-07


Since last post: 3.0 years
Last activity: 2.0 years

Posted on 05-25-10 12:02:31 AM Link | Quote
Yes, transposition in this case means moving all the notes in a specific part up or down in pitch (by semitones), so a value of "12" means shift it up twelve semitones, or one octave. To shift down, negative values are used. Naturally, only integer values are valid (I'm sorry, no microtones support hehe). It's a good tool in case your song doesn't fit the range of a specific instrument.

I'm trying to deal with syncronization errors, I'll probably need some rounding algorithm so that even if the division fails for some reason in the end of each measure all parts are in sync.
TheGreatMan55580
Utter failure
Level: 9


Posts: 7/14
EXP: 2798
For next: 364

Since: 02-21-10
From: Binary

Since last post: 7.0 years
Last activity: 6.0 years

Posted on 05-25-10 01:59:48 PM (last edited by TheGreatMan55580 at 05-25-10 02:00 PM) Link | Quote
@messian
That's very good!
but if you change the setting's and Upload it and your Sound dosen't sounds like you want then you need to change it again and again
you can make an Preview button so they can hear their changed MIDI file.
It's only an Idea


~TheGreatMan55580~
BTTF Forever
Member
Level: 19


Posts: 66/70
EXP: 31358
For next: 4419

Since: 02-08-10
From: Australia

Since last post: 6.0 years
Last activity: 6.0 years

Posted on 06-01-10 08:02:43 AM Link | Quote
wow, havnt been here in a while, everything is looking great!
i sort of stopped with the SM64 hacking for a while, but now i think im ready to get back into it...

@messiean: i was wondering, if i sent you a musicxml file converted already, could you test it in game for me? i would really appreciate it, it is a big file and i wanna test the LIMITS of the importer and the game itself, iv'e always wondered how it will sound in game.

here it is: http://www.megaupload.com/?d=PTER7JBZ

BTW its the Back to the future theme song, YAY!

thank you so much, you have helped me out with SM64 hacking a lot over the last couple of months, and i do really apreciate it, ill be getting some more mods done soon, so look out for me!

cya!
messiaen
Catgirl
Level: 64


Posts: 912/1085
EXP: 2167292
For next: 46805

Since: 11-20-07


Since last post: 3.0 years
Last activity: 2.0 years

Posted on 07-19-10 06:49:14 PM Link | Quote
Worked a bit more on the user interface and now that it's actually usable I decided to release this early alpha, at least for the Jul community:

Download.

There are some missing features, most notably proper handling of ties in polyphonic channels, but it still might give better results in simpler files than mml2m64. Be sure to save your settings so you can try them again in newer versions.

Other limitations:
- Individual channel transposition won't work.
- Unicoded-encoded .xml files may not open properly.

The first post should cover most basic usage. Unfortunately, better results will only be obtained with commercial software such as Finale or Sibelius.
Vinnyboiler
Catgirl
Level: 63


Posts: 337/1028
EXP: 1988674
For next: 108478

Since: 12-27-07
From: London, England

Since last post: 162 days
Last activity: 53 days

Posted on 07-19-10 08:02:06 PM Link | Quote
Just downloading it now, are their instuctions on how to use this program or will I have to figure it out myself
Lyskar
12210
-The Chaos within trumps the Chaos without-
Level: 183


Posts: 6070/12211
EXP: 83374225
For next: 1126878

Since: 07-03-07
From: 52-2-88-7

Since last post: 3.0 years
Last activity: 2.0 years

Posted on 07-19-10 08:24:12 PM Link | Quote
Figure out how not to double post first, Vinny.
messiaen
Catgirl
Level: 64


Posts: 913/1085
EXP: 2167292
For next: 46805

Since: 11-20-07


Since last post: 3.0 years
Last activity: 2.0 years

Posted on 07-19-10 09:15:47 PM Link | Quote
Originally posted by vinnyboiler
Just downloading it now, are their instuctions on how to use this program or will I have to figure it out myself

Basic usage:

- Convert your .MIDI file to MusicXML (see first post) and open it (hint: "Load File" button) into the importer.
- If everything is correct, a list of "parts" will be compiled. If your MIDI didn't contain part names, they will be listead as Unnamed staff 1, 2, 3 etc.
- Toggle a channel on, select a parts and a instruments for it.
- Click on "create .m64 file"

Now you'll have to rely on the old sequence inserter from mml2m64, until I do a new one with a graphical interface and which will actually change the instrument set (this may be finished on a few days).
Me-me
340
Level: 39


Posts: 222/341
EXP: 387390
For next: 17381

Since: 08-05-07


Since last post: 5.0 years
Last activity: 3.0 years

Posted on 08-07-10 03:05:34 PM Link | Quote
Awesome importer! You never cease to amaze me Messiaen.
I've tried importing some music with this new importer, and it obviously works a lot better than mmlm64.
However, I noticed a problem with notes in either the importer or the game itself.
It seems like the game/importer have difficoulties playing these (marked in red) notes:

As you can see, they're all strings so I applied the Inside Castle strings to them, but the strings are not played in-game.
Yoshi Party
User
Level: 9


Posts: 6/14
EXP: 2823
For next: 339

Since: 12-31-09


Since last post: 6.0 years
Last activity: 6.0 years

Posted on 08-08-10 06:19:40 AM Link | Quote
would you be able to add a "play" button or "convert to mp3", so you don't always have to inject the music?

however, well done!
Emoluvjd2
Member
Level: 19


Posts: 36/69
EXP: 31253
For next: 4524

Since: 10-24-09


Since last post: 74 days
Last activity: 2 days

Posted on 08-11-10 05:12:51 PM Link | Quote
I've been trying to insert Lavender Town from Pokemon RBY, but only the last two tracks are working. I've tried over ten different configurations, even changing the actual Midi, but none seem to work. Maybe you could help. http://www.mediafire.com/download.php?idhr56ndi1jmmhc In this .zip, I've included the .midi, the .m64, the .set and the MusicXML.
Me-me
340
Level: 39


Posts: 224/341
EXP: 387390
For next: 17381

Since: 08-05-07


Since last post: 5.0 years
Last activity: 3.0 years

Posted on 08-18-10 01:31:56 AM Link | Quote
Most notation programs is File > Export > MusicXML (.xml)
And yes you get to choose the instruments in the importer. The best instrument set right now for me would be the inside castle one.
It's practically the only set that has pizzicato strings.
Yoshi Party
User
Level: 9


Posts: 10/14
EXP: 2823
For next: 339

Since: 12-31-09


Since last post: 6.0 years
Last activity: 6.0 years

Posted on 08-28-10 09:10:41 AM Link | Quote
@messiaen

I downloaded your samples and I was also impressed by the classic background music from the Missing Stars. That's why I wanted to ask you if you could publish them for other people?

I used your sample files for Super Mario 64(2) for Wii and many people liked them very much :T

regards Yoshi Party
Flames540
User
Level: 10


Posts: 5/16
EXP: 3311
For next: 1103

Since: 08-17-10


Since last post: 7.0 years
Last activity: 6.0 years

Posted on 09-18-10 01:45:15 PM Link | Quote
Ok.... i've made a Xml file with Musescore and opened it up with the MusicXML importer messing around/tried something out
and created a m64 file and it made a file named Parts and another file named output.m64

so what do I do now?

Flames540
RDX

Level: 30


Posts: 139/198
EXP: 158239
For next: 7630

Since: 02-14-09


Since last post: 6.0 years
Last activity: 6.0 years

Posted on 12-26-10 05:02:31 PM Link | Quote
Anyone know of any other midi to xml programs? Musescore only works occasionally for me, and while Encore is perfect I can't get it to export my xml files (Probably cause it's only the trial version).

I would start writing in music in the xml format to begin with, but that would require me to have more music knowledge than I already have
BTTF Forever
Member
Level: 19


Posts: 70/70
EXP: 31358
For next: 4419

Since: 02-08-10
From: Australia

Since last post: 6.0 years
Last activity: 6.0 years

Posted on 01-26-11 09:20:48 PM Link | Quote
Hi Guys, just wanted to let Messiaen know that his MusicXML Importer works great, however, there is a limit to the size of midi files you can put into SM64, i have tested many midi's, i have tried midi files of about 40kb, there is no sound, a bit smaller, still no sound, i found some midi's that were 5-6kb and they worked well, every sound was imported.

And i also came to the conclusion that the size of the midi you want in SM64, is the same size as the outputed .m64 file after you have gone through the steps from MIDI---XML---M64. And i read that the maximum size of a m64 file you can put in was something around 1,420 Bytes.

So in conclusion, the maximum file size for a MIDI which you can successfully import (well for me anyways) is a MIDI file of no more than 14 KB. Which sucks cause theres so much good music out there but the music files are 100 to 200 kb, and i hate cutting notes off, it doesn't sound right, i guess ill have to stick with importing music from other games.

Wait a minute, with the importer, Messiaen gave us 20 or so places of custom music space right?, so if we want to import an m64 file of about 36kb, instead of coming up with a warning saying it exeeds 14kb, why not take some extra space from 2 more custom places, 3 x 14kb = 42kb, more then enough room to have the entire track in there, right?
Pages: 1 2 3Next newer thread | Next older thread
Jul - SM64 Hacking - Mario 64 MusicXML Importer New poll - New thread - New reply




Rusted Logic

Acmlmboard - commit 2f1bc75 [2017-08-27]
©2000-2017 Acmlm, Xkeeper, Inuyasha, et al.

31 database queries, 6 query cache hits.
Query execution time: 0.136534 seconds
Script execution time: 0.017062 seconds
Total render time: 0.153596 seconds