On Tuesday 17 March 2009 01.29.38 S C Rigler wrote:
> Maybe I'm missing something completely obvious, but I've noticed that midi
> files that I've imported into LMMS 4.3 always end up transposed down three
> half steps. This is happening when I run it on Fedora 10 or on Vista. Has
> anybody noticed this? Am I missing something obvious here?


Hi
This problem was also discussed in ##lmms on irc.freenode.org on March 8th, 2009. I will just post a little log here. It is not really very well edited , I don't have the time for that , but if you read through it you will see that it is similar to the problem you reported but different in that the difference is reported as 9 semitones not 3...


Sun Mar 8 2009] [00:31:08] <ElvenSpellmaker> Why are all MIDI files I import 9 semitones too high? I am using LMMS 0.4.3 on Windows.
[Sun Mar 8 2009] [00:31:22] <ElvenSpellmaker> I can change it with the master pitch, but its annoying to have to lower it every time


[Sun Mar 8 2009] [00:41:14] <pgib> ElvenSpellmaker, are you sure it is?
[Sun Mar 8 2009] [00:41:29] <pgib> when we do midi-import we transpose the notes from C to A
Sun Mar 8 2009] [00:41:46] <pgib> since MIDI are in C and I think LMMS is A
[Sun Mar 8 2009] [00:42:09] <pgib> so rather then changing the root-note on each instrument, we transpose the notes
[Sun Mar 8 2009] [00:42:10] <superjoe> that needs to change



[Sun Mar 8 2009] [00:42:58] <pgib> LMMS's root note is A
[Sun Mar 8 2009] [00:43:02] <Skiessi> why
[Sun Mar 8 2009] [00:43:10] <pgib> Because that is the way it has always been
[Sun Mar 8 2009] [00:43:22] <pgib> haven't you noticed the root-note on the piano for each instrument window?


[Sun Mar 8 2009] [00:44:02] <Skiessi> I have and now someone mentioned it
[Sun Mar 8 2009] [00:44:30] <superjoe> but because it's always been that way, does that mean it should stay?
[Sun Mar 8 2009] [00:44:40] <superjoe> let me ask a different question
[Sun Mar 8 2009] [00:44:41] <pgib> I don't see why it should change honestly
[Sun Mar 8 2009] [00:44:49] <superjoe> because it doesn't make any sense
[Sun Mar 8 2009] [00:45:04] <pgib> then ask the Toby on the ML why he decided to do it that way
[Sun Mar 8 2009] [00:45:09] <superjoe> ok
[Sun Mar 8 2009] [00:45:16] <superjoe> we've had this discussion before
[Sun Mar 8 2009] [00:45:21] <pgib> I mean, we have to pick *some* value
[Sun Mar 8 2009] [00:45:22] <heinkel_vista> the A (440) is used as the reference note when tuning instruments
[Sun Mar 8 2009] [00:45:24] <superjoe> C
[Sun Mar 8 2009] [00:45:26] <pgib> I really dones see what the big deal is
[Sun Mar 8 2009] [00:45:28] <superjoe> we should pick C
[Sun Mar 8 2009] [00:45:29] <pgib> *don't
[Sun Mar 8 2009] [00:45:39] <pgib> superjoe, *you* should pick C. ;-)
[Sun Mar 8 2009] [00:45:45] <superjoe> because if you start playing notes on the keyboard, they're wrong
[Sun Mar 8 2009] [00:45:57] <superjoe> if someone tries to play sheet music with lmms they'll wonder why all their music is transposed
[Sun Mar 8 2009] [00:46:03] <superjoe> unless they change root note to C
[Sun Mar 8 2009] [00:46:11] <pgib> Is that really the case?
[Sun Mar 8 2009] [00:46:37] <pgib> I mean, have you checked the end result of pressing 'A' on a midi-controller?
[Sun Mar 8 2009] [00:46:47] <pgib> (I don't know if it adjusts for this, that is why I ask)
[Sun Mar 8 2009] [00:47:18] <superjoe> ok let me break this into 2 cases:
[Sun Mar 8 2009] [00:47:39] <pgib> I'm not going to debate this, so I don't really care ;-)
[Sun Mar 8 2009] [00:47:43] <superjoe> case 1: it works correctly when using midi controller: then why go through the trouble of transposing midi inputs? it's a hack. we should just use the real root note as the real root note
[Sun Mar 8 2009] [00:47:47] <pgib> better of making your point to Toby
[Sun Mar 8 2009] [00:47:52] <superjoe> ok
[Sun Mar 8 2009] [00:48:10] <_sim_> i do concur that root note should be c
[Sun Mar 8 2009] [00:48:15] <_sim_> just makes more sense
[Sun Mar 8 2009] [00:49:28] <ElvenSpellmaker> A is fine... it should be the root note
[Sun Mar 8 2009] [00:49:37] <ElvenSpellmaker> Its just that all files do play 9 semitones higher
[Sun Mar 8 2009] [00:49:53] <pgib> well they shouldn't
[Sun Mar 8 2009] [00:50:05] <pgib> it should be adjusted so the final result is the same as the MIDI
[Sun Mar 8 2009] [00:50:21] <pgib> if not, then something is bugged
[Sun Mar 8 2009] [00:50:26] <ElvenSpellmaker> Exactly... The output should be the same if I just played the MIDI in Synthfont for example
[Sun Mar 8 2009] [00:50:39] <superjoe> okay well I'm going to make it configurable in the options then
[Sun Mar 8 2009] [00:50:49] <pgib> ElvenSpellmaker, even if the piano roll shows otherwise.
[Sun Mar 8 2009] [00:51:00] <_sim_> superjoe: to make it configurable to make c the default?
[Sun Mar 8 2009] [00:51:03] <pgib> superjoe, I would talk to toby first
[Sun Mar 8 2009] [00:51:04] <superjoe> yes
[Sun Mar 8 2009] [00:51:14] <pgib> it might just be that we make it just "C"
[Sun Mar 8 2009] [00:51:30] <superjoe> ok
[Sun Mar 8 2009] [00:51:43] <pgib> but... I guess you are talking about a setting for the "default rootnote"
[Sun Mar 8 2009] [00:51:52] <pgib> since instruments already support rootnotes
[Sun Mar 8 2009] [00:51:58] <_sim_> maybe that would be a good idea, everyone could choose their own rootnote
[Sun Mar 8 2009] [00:51:59] <superjoe> right
[Sun Mar 8 2009] [00:52:04] <pgib> I suppose that is a good idea
[Sun Mar 8 2009] [00:52:10] <superjoe> and the default should be "C" :P
[Sun Mar 8 2009] [00:52:32] <pgib> You'll have to make it exposed properly though so plugins (like MIDI import) can make the proper adjustments
[Sun Mar 8 2009] [00:52:39] <ElvenSpellmaker> I'm sure A is the usual default, because its the "Main Note" with the value of A4 = 440Hz
[Sun Mar 8 2009] [00:52:39] <superjoe> ok
[Sun Mar 8 2009] [00:53:04] <pgib> ElvenSpellmaker, Yes, everyone knows the value of A4
[Sun Mar 8 2009] [00:53:09] <ElvenSpellmaker> ;)
[Sun Mar 8 2009] [00:54:09] <superjoe> if the root note is set to A4 in lmms, and you play the "A" note, does it make the same frequency pitch that a piano makes when you press A4?
[Sun Mar 8 2009] [00:54:57] <pgib> one way to find out
[Sun Mar 8 2009] [00:55:17] <pgib> take a triple oscillator, play a note, and measure the wavelength in audacity or something
[Sun Mar 8 2009] [00:55:25] <pgib> (easier than following the code anyways)
[Sun Mar 8 2009] [00:55:42] <pgib> (or have a good ear)
[Sun Mar 8 2009] [00:56:05] <ElvenSpellmaker> Use AP Tuner
[Sun Mar 8 2009] [00:56:16] <ElvenSpellmaker> Or ear
[Sun Mar 8 2009] [00:56:55] <pgib> or another tuned instrument
[Sun Mar 8 2009] [00:57:03] <pgib> or a wave generator
[Sun Mar 8 2009] [00:57:12] <pgib> or an oscilloscope
[Sun Mar 8 2009] [00:57:26] <pgib> or.. or...
[Sun Mar 8 2009] [00:57:38] <ElvenSpellmaker> If I made a MIDI with one A4 note, it would play F#5
[Sun Mar 8 2009] [00:57:47] <ElvenSpellmaker> one of my ocarinas?
[Sun Mar 8 2009] [00:58:28] <pgib> odd
[Sun Mar 8 2009] [01:02:49] <ElvenSpellmaker> As I predicted... I just made a MIDI with the note A4 and it played a F#5 in LMMS, even the piano score is wrong as you said.
[Sun Mar 8 2009] [01:03:53] <ElvenSpellmaker> F#4 even
[Sun Mar 8 2009] [01:04:19] <ElvenSpellmaker> which is 9 semitones to high.
[Sun Mar 8 2009] [01:08:43] <Skiessi> superjoe, are you there?
[Sun Mar 8 2009] [01:09:33] <pgib> well I will investigate
[Sun Mar 8 2009] [01:09:39] <pgib> the new MIDI import is mine




--
Thomas