|
Post by vandorb12 on Dec 8, 2011 23:50:36 GMT
This was the single most useful online resource when I wrote FoFLC's MIDI parser: www.sonicspot.com/guide/midifiles.htmlMake sure to look into how running status works, that website didn't really go into it. lol I found that site a day before you told me about it. What guide would you recommend to learn about running status?
|
|
|
Post by raynebc on Dec 9, 2011 0:11:06 GMT
This is as good as any other site about that: home.roadrunner.com/~jgglatt/tech/midispec/run.htmIt's a mechanism to allow the MIDI event type to be repeated automatically if it's the same as the prevent event (ie. multiple Note On events in a row), saving some space.
|
|
|
Post by vandorb12 on Dec 10, 2011 9:46:19 GMT
Is that even necessary? Would there be any performance issues (in any rhythm game that uses MIDI) if i decided to pair each note-on with a note-off?
|
|
|
Post by David on Dec 10, 2011 10:32:55 GMT
If you are only writing then no, if you want to import a midi then you'll need it.
David
|
|
|
Post by vandorb12 on Dec 12, 2011 19:44:30 GMT
I see...
|
|
|
Post by vandorb12 on Dec 29, 2011 10:13:42 GMT
I'm done with all my notation research on the gh 5 format (still haven't found much for the gh:wt one). Now all that needs to be done is coding. I'm still stuck in a rut with converting milliseconds to a three byte hexidecimal array that one of the core Java functions must use. 10ms would translate to [(byte)0x00, (byte)0x00, (byte)0x0A] I'll have a sketch of the GUI up later (i'll update the post the reduce spam) as a little treat. @asskick I'm still eagerly waiting for that project logo =D Edit: Here's a sketch of the GUI I made when I first started planning this project. bayimg.com/fAlPJaADJ
|
|
|
Post by David on Dec 29, 2011 10:51:09 GMT
What exactly is the hex issue you're having? Remeber that Midi Files use a Big Endian system.
David
|
|
|
Post by vandorb12 on Dec 29, 2011 11:08:25 GMT
My issue is going from decimal number to a hexadecimal array. The Java MIDI class function I'm using requires a byte array with 3 values to describe the milisecond delta time of the MIDI event.
I could be wording this totally wrong: I'm tired from basking in the glow of my computer monitor, and I haven't touched any of my code for a few weeks.
I'll post a working code sample of the function later today.
|
|
|
Post by raynebc on Dec 29, 2011 15:49:41 GMT
So you just need to store the number in big endian format into an array? You could do something like this:
array[0] = (value & 0xFF0000) >> 16; array[1] = (value & 0xFF00) >> 8; array[2] = (value & 0xFF);
This manually stores each byte of the "value" variable into the chosen array. I haven't programmed in Java in ages, but I assume they have typical bitwise operators such as AND and shifts.
|
|
|
Post by Bluzer on Dec 30, 2011 0:36:22 GMT
I'm done with all my notation research on the gh 5 format ( still haven't found much for the gh:wt one). Will this do? gh_wt_midqb.zipHad this for awhile, ya should have asked.
|
|
|
Post by vandorb12 on Dec 30, 2011 4:45:14 GMT
I'm done with all my notation research on the gh 5 format ( still haven't found much for the gh:wt one). Will this do? gh_wt_midqb.zipHad this for awhile, ya should have asked. You never fail to amaze me about what you pull out of that magical Canadian Mountie hat of yours ;D
|
|
|
Post by vandorb12 on Dec 30, 2011 4:50:09 GMT
So you just need to store the number in big endian format into an array? You could do something like this: array[0] = (value & 0xFF0000) >> 16; array[1] = (value & 0xFF00) >> 8; array[2] = (value & 0xFF); This manually stores each byte of the "value" variable into the chosen array. I haven't programmed in Java in ages, but I assume they have typical bitwise operators such as AND and shifts. I did not learn that in my Java class. I guess you learn something every day! I checked the Oracle website, and Java does support bitwise shifts. I'll spend some time learning this new snytax, and I'll see if I can get my code to work.
|
|
|
Post by Bluzer on Dec 31, 2011 3:14:26 GMT
You never fail to amaze me about what you pull out of that magical Canadian Mountie hat of yours ;D Yeah, I DL shizz I don't need or use, but at some point someone might have a use for...like the said file.
|
|
|
Post by vandorb12 on Dec 31, 2011 9:22:01 GMT
You never fail to amaze me about what you pull out of that magical Canadian Mountie hat of yours ;D Yeah, I DL shizz I don't need or use, but at some point someone might have a use for...like the said file. the qb format that gh:wt uses is hard to wrap my head around. It's not like the GH5 format at all (which feels more straightforward). Do you know if there are differences between the mid.qb formats from one game console system to another? On another note, that code example that ray gave me was just what I needed.
|
|
|
Post by vandorb12 on Jan 13, 2012 3:54:09 GMT
So I (finally) found out that BPM doesn't matter, and all that I really need is the delta of two points in time =P. Wasted a lot of time on that =P
I'm not sure what sort of method/technique I should use to read the input file. Over my programming classes, all that I've done was read user input from the console, and rudimentary text files within a working folder. That's my latest roadblock.
It's easiest to read the values of the input file as hexadecimal, but binary is doable, though a stretch.
The release might be pushed to mid March.
|
|