Closed hanetzer closed 10 years ago
Hard to give any suggestions when you're not telling me how or what exactly you did =P
In general, doing what the Readme says should always work, ie. placing the converted ogg with exactly the same name as the midis (sans extension) in the path where the game expected the midis.
Well, the first time I did the conversion was probably a year or two ago, so I have not a clue exactly what I did, some timidity stuff.
This go around I did like so:
timidity source.mid -Ow -o dest.wav
oggenc dest.wav
(Note: I used a for loop in bash to do it all, lol. No way in hell I'm doing that amount manually)
then I deleted the midi and intermediary wav files, still no joy.
I get an SDL error, unsupported format. If it makes a difference I'm on arch linux and as such my libs may be newer and expect different things than is expected.
Did you compile mkxp yourself? If yes, did you make sure SDL_sound was compiled with ogg support?
Yep, I compiled mkxp myself. I'll have to recompile SDL_sound; I was hoping to avoid that, but since creating the pkg-config file, while allowing it to compile properly with qmake I guess that patch does a bit more than I expected.
The patch itself doesn't do much besides pkg-config support and making sure the sound headers are installed to SDL2/
instead of SDL/
. What's important is that you compile it with --enable-ogg
.
pkg-config is great aint it? Alrighty, next time I get access to my arch box I'll give it another shot. And for the record, this is sdl, not sdl2, sound correct?
If you want to do it the easy way, just install this AUR package: https://aur.archlinux.org/packages/sdl_sound-patched-hg/
It works for me.
excellent, PKGBUILD's make stuff so damned easy :D
Far easier to write a PKGBUILD than to make a debian package.
hmm. --enable-ogg
should end up in the ./configure
step, yes?
On another note, I've done midi work in a project I was working on, basically the same idea as mkxp, mayhaps I'll fiddle with this and get you a nice pr for midi ;) Also, I notice you compile a font right into the executable; perhaps one should do the same with an agreed upon default/fallback soundfont
hmm. --enable-ogg should end up in the ./configure step, yes?
Yes, the flag is for the configure step, but looking at the dependency list, it should already be compiled in in the arch package.
On another note, I've done midi work in a project I was working on, basically the same idea as mkxp, mayhaps I'll fiddle with this and get you a nice pr for midi ;)
Cool! You might want to check out #6 for reference. I'm always open for discussion.
Also, I notice you compile a font right into the executable; perhaps one should do the same with an agreed upon default/fallback soundfont
Hm. All soundfonts I have come across so far were in the 20-50 MB range, which would blow up the executable immensely for a feature that might not even be wanted.
oh ouch... mayhaps some form of external shared library instead then. Also, I'm curious as to how you actually embedded the font into the executable; I've seen xpm images used (most notably in the xscreensaver's xmatrix binary for the glyphs) but this is the first time I've seen a ttf font embedded.
I mean, if we could find a sfont on the scale of 1-2MB, it would certainly make sense to bundle it with mkxp (if license allows, of course). But this is a small problem compared to midi decoding support itself =)
Also, I'm curious as to how you actually embedded the font into the executable
xxd -i
will spit out an unsigned char[]
'ed version as a C header for any file you give it, giving you a compile time equivalent of allocating a buffer and reading the entire file into it.
Interesting indeed. I'll see what I can do regarding getting midi to work; the rubyland command line options should have a soundfont config file added in, and if none is assume a fallback.
Note: with patched SDL_sound with --enable-ogg the files I had previously converted to ogg worked. Working on a SDK type thing for doing mkxp on windows, wish me luck.
I had previously converted the midi audio for RMXP to ogg for the sake of my PlayOnLinux wrapper script, but it seems mkxp doesn't like the way I did it. I don't suppose you have any suggestions?