MIDI files don't work
Moderator: Forum Moderators
- Atreides
- Posts: 1090
- Joined: March 30th, 2019, 10:38 pm
- Location: On the 2nd story of the centre village of Merwuerdigliebe turning the lights on and off
MIDI files don't work
Hi, not sure if this is the right board but I am stumped as to why the midi files in my campaign don't play (or are audible). I know the wml works because I subbed in a mainline ogg for one midi and the ogg played fine. I also know the midi files play when I access them from my OS (Linux).
I tried to find some info on whether midi files are no longer supported but zilch so as a last resort I ask for help.
I tried to find some info on whether midi files are no longer supported but zilch so as a last resort I ask for help.
Re: MIDI files don't work
Wesnoth uses SDL_mixer, which optionally supports MIDI playback using fluidsynth or timidity on Linux. This support may not always be available, compiled in, usable out of the box, or fully functional on all platforms for which Wesnoth is distributed, so we don't officially support using MIDI files in Wesnoth. Only Ogg Vorbis and pcm/wav are officially supported by the game on all platforms, so the recommendation is to convert files in any other format to Ogg Vorbis (music and sound effects) or wav (sound effects) before distribution. This has the added benefit of removing the issue of playback differences between platforms and devices for formats like MIDI.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
- Atreides
- Posts: 1090
- Joined: March 30th, 2019, 10:38 pm
- Location: On the 2nd story of the centre village of Merwuerdigliebe turning the lights on and off
Re: MIDI files don't work
Thank you for the reply. I inherited them from an old campaign I updated. I'll leave them as is, as it seems some people may be able to hear them based on the info you provided. I may try and research how to convert them.Iris wrote: ↑February 23rd, 2021, 8:27 pm Wesnoth uses SDL_mixer, which optionally supports MIDI playback using fluidsynth or timidity on Linux. This support may not always be available, compiled in, usable out of the box, or fully functional on all platforms for which Wesnoth is distributed, so we don't officially support using MIDI files in Wesnoth. Only Ogg Vorbis and pcm/wav are officially supported by the game on all platforms, so the recommendation is to convert files in any other format to Ogg Vorbis (music and sound effects) or wav (sound effects) before distribution. This has the added benefit of removing the issue of playback differences between platforms and devices for formats like MIDI.
Re: MIDI files don't work
If you have the
timidity
program installed, you should be able to convert to Ogg Vorbis with this command:Code: Select all
timidity FILE.mid -Ov -o FILE.ogg
- Atreides
- Posts: 1090
- Joined: March 30th, 2019, 10:38 pm
- Location: On the 2nd story of the centre village of Merwuerdigliebe turning the lights on and off
Re: MIDI files don't work
Thank you very much, that was quite easy! It works now, woo hoo!gnombat wrote: ↑February 24th, 2021, 10:23 am If you have thetimidity
program installed, you should be able to convert to Ogg Vorbis with this command:
Code: Select all
timidity FILE.mid -Ov -o FILE.ogg