This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#3005 - Midi player update
Attached to Project:
Rockbox
Opened by Karl Kurbjun (kkurbjun) - Friday, 10 February 2006, 01:21 GMT+2
Last edited by Karl Kurbjun (kkurbjun) - Friday, 10 February 2006, 07:16 GMT+2
Opened by Karl Kurbjun (kkurbjun) - Friday, 10 February 2006, 01:21 GMT+2
Last edited by Karl Kurbjun (kkurbjun) - Friday, 10 February 2006, 07:16 GMT+2
|
DetailsHere's an updated version of the midi player. I've
been testing it with files from here: http://www.theparticle.com/midi/doommidi.html on my H300. Most of them work fine. I'm still getting buffer misses occasionally though so more work needs to be done on it. Don't forget the patch set: http://wam.umd.edu/~stevenm/patchset.tbz2 It will still crash if you don't have a patch set installed. |
This task depends upon
Closed by Karl Kurbjun (kkurbjun)
Monday, 19 June 2006, 19:14 GMT+2
Reason for closing: Accepted
Additional comments about closing: Patches Committed
Monday, 19 June 2006, 19:14 GMT+2
Reason for closing: Accepted
Additional comments about closing: Patches Committed
This update to the midi player needs the same patch that
doom does. The only difference between the two is the
plugin buffer size (the midi player doesn't need a modified
buffer size to run) and the makefile doesn't need to be
modifed in plugins. This cvs diff includes the hold status
information for H300's and access to vsnprintf. If you
don't want to apply the cvs patch you can comment out the
insides of printf.
midiplay.rock should replace midi2wav in viewers.config
i.e.
ch8,viewers/chip8,70 70 7f 7f 70 70
txt,viewers/viewer,55 55 55 55 55 55
nfo,viewers/viewer,55 55 55 55 55 55
txt,rocks/text_editor, 55 55 55 55 55 55
jpg,viewers/jpeg,18 24 3C 3C 24 18
mp3,viewers/vbrfix,10 08 58 38 04 02
m3u,viewers/search,00 00 00 00 00 00
txt,viewers/sort, 00 00 00 00 00 00
gb,viewers/rockboy, 0C 2A 59 7A 2E 0C
gbc,viewers/rockboy, 0C 2A 59 7A 2E 0C
m3u,viewers/iriverify,00 00 00 00 00 00
mid,viewers/midiplay, 20 70 70 3F 00 00
ss,rocks/sudoku, 55 55 55 55 55 55
wav,viewers/wav2wv, 00 00 00 00 00 00
wav,viewers/mp3_encoder, 00 00 00 00 00 00
I just applied patch to code, changed a few other things and put in CVS. Thank you very much!
I changed the sampling rate back to 22K to make it sound better, but I cut back on the number of active voices instead. I know it is below the MIDI spec but we can raise that once the synth code runs faster. For now, it just replaces old voice objects with new ones. Notes get cut, but it is not as bad as having more buffer misses. Hopefully at some point, with ASM and stuff it would be possible to run it with all voices enabled. I have a few files here of moderate complexity that actually play as intended.
Thanks again for the patch.
Stepan
If not,
http://wamm.umd.edu/~stevenm/patchset.tbz2
Untar that into the .rockbox directory
http://wam.umd.edu/~stevenm/patchset.tbz2
I need to wake up
I've also been working on a way of making the ramping code more efficient, as samples do not need to be recalculated for every voice being ramped. Maybe make 2 global ramping variables, one for left and for right channels, and just add stuff onto them (pre-scaled for both note and channel volume) and then let each approach 0 with each sample. Ramping gives way too much trouble for me, so this will take some time.
Please check out the latest version- let me know what needs to be immediately fixed etc.
Excellent- glad you like it
Looping? I did not know MIDI files could loop. To my knowledge this is not possible, and I have not seen anything anywhere in the file format specifications about an event that would cause looping or any sort of jumping within the file. How does doom's music system work? Is it real midi, or is it just FM / Audlib?