Mod Archive Forums

Music Production => Tracking => Topic started by: Jay on August 25, 2019, 22:29:18

Title: OpenMPT MIDI export - "double time" tempo
Post by: Jay on August 25, 2019, 22:29:18
I've written a few modules in "double time", e.g. using 3@130 for 32nd note granularity at 130BPM instead of 16th notes. I've been using OpenMPT to export these to MIDI.

The .mid files OpenMPT outputs have a baked in tempo of 260BPM if I do this, which makes it annoying to open them in DAW software (especially when I'm trying to mix songs in "single time" and "double time".)

Is there a way to get MPT to set the tempo correctly, but keep the song timing as it is?
Title: Re: OpenMPT MIDI export - "double time" tempo
Post by: Saga Musix on August 27, 2019, 16:56:11
Yes there is - MIDI export uses the time signature that is specified in the Song Properties (https://wiki.openmpt.org/Manual:_Song_Properties#Time_Signature). If you use a speed of 3 then most likely your track is using 8 rows per beat rather than 4, so set the time signature to 8/32 instead of 4/16 and the correct tempo will be calculated.
You can go to Player -> Approximate Real BPM to find out the tempo value that MIDI export would be using.
Title: Re: OpenMPT MIDI export - "double time" tempo
Post by: Jay on September 21, 2019, 11:10:15
Just getting back to these songs. Thanks! That worked, and I ended up converting them to mptm to get Accurate tempo too. It's a much better way to generate .mids than how I was previously doing it.

If you're wondering what I'm doing with my MIDI-modules, well, this (https://soundcloud.com/jmph-1/overflow-006-set-28082019) (also video (https://youtu.be/vlx4NH1siIU?t=2464), but the first link is better because I fixed a big DJ flub in the middle.) 100% Impulse Tracker General MIDI, converted to .mid in OpenMPT and mixed live on stage in Ableton. :P

I'm still having a slight issue with SOME synths stuttering when playing these, and I think the reason is this: in 'tracker land', every note-on is accompanied by a program change (instrument #), even when it's not necessary. Some GM synths aren't bothered by this, like my SC-55 and Korg 05R/W, but my (much newer) JV-1010 chokes when a bunch of notes (& program change commands) hit at once. Not sure if there's anything that can be done about it, aside from importing the .mid into a DAW and doing a ton of editing after the fact.

It would be nice if I could set one program for each TRACK, to be sent at the start of the song, and have OMPT just not export program changes with note-ons... is that possible?
Title: Re: OpenMPT MIDI export - "double time" tempo
Post by: Saga Musix on September 21, 2019, 15:33:13
OpenMPT only writes program change events when they are necessary. If you keep playing the same instrument on a MIDI channel, it should not send any program change events. If you want to absolutely have this program change at the start of the file, I suggest you put a silent note in the first pattern. Anything else isn't really possible with the way OpenMPT approaches MIDI export (which is essentially a live playback of the module funneled into a MID file, so it doesn't know in advance which instrument is going to play on which channel).
Title: Re: OpenMPT MIDI export - "double time" tempo
Post by: Jay on September 23, 2019, 22:16:58
That's good to know, thanks. I'll try pre-sending my program changes and see if that tidies things up.

Does what "track" (tracker channel) a note is on make any difference to the MIDI export? I have some stuff where some instruments "track hop" in the module. Each one has its own MIDI program # & MIDI channel. So on a single track in the module you might get something like this:

C-5, MIDI program 50, channel 1
...
A#4, MIDI program 32, channel 2
...
F-4, MIDI program 50, channel 1

etc.

How does MPT export this?
I know I "should" give each MIDI channel its own tracker track, but I've converted some old sample-based modules and that's just how they were written.

(Typically I don't re-use MIDI channels for different programs doing GM. In the case of MT-32 or FB-01 modules where I only have 8 channels to work with, sometimes.)
Title: Re: OpenMPT MIDI export - "double time" tempo
Post by: Saga Musix on September 26, 2019, 16:32:30
If you don't assign instruments to a specific channel, they will be spread over all MIDI channels except for MIDI channel 10, with a direct pattern to MIDI channel mapping (i.e. pattern channel 1 is MIDI channel 1, etc.), so this is a dangerous mode if you have multiple instruments mapped the same way as they might stop each other if the MIDI device in question cannot sustain notes that happened before a program change.