MdaPiano and microtonality

Hi all,

I was messing around with the MdaPiano extension today, in combination with scale/degree/tuning variations in the context of Pbind and Events. After about an hour of feeling like I was slowly going insane, I came to the conclusion that MdaPiano does not support tuning systems outside of twelve-tone equal temperament:

s.boot;

{MdaPiano.ar(452, Line.kr(1,-1,2,doneAction:2), 50)}.play(fadeTime:0);
//internally rounded to 69.midicps = 440 Hz

{MdaPiano.ar(453, Line.kr(1,-1,2,doneAction:2), 50)}.play(fadeTime:0);
//internally rounded to 70.midicps = 466.16 Hz

I don’t know the internals of this plugin — is there anyone familiar with MdaPiano who can confirm this? Or am I overlooking something?

Eli

From experience, I can confirm. No microtuning.

I even saw an instance where a frequency in Hz got rounded to the wrong MIDI note and sounded a half step too… flat IIRC.

hjh

MdaPiano is a sampler adapted from an old VST plugin. There are many free piano sample libraries out there, such as Ivy Audio Piano in 162 and U. Iowa, that I would recommend instead. In both cases, you will need to auto-trim and fade out the samples a bit since they’re very long, but it shouldn’t be hard to rig something up with PlayBuf.

In general, it’s best to try to stay away from sc3-plugins in production code IMO. There are rumblings from the dev team about an exit strategy for that project.

Interesting, thanks both. I’ve rigged up at alternative using my own piano sample library and PlayBuf. I had been operating under the assumption that MdaPiano was synthesis-based (where are the samples actually stored?). I generally avoid the sc3-plugins for my own personal projects — but in this case I’m working on a lecture on tunings and temperaments, and thought MdaPiano might save time. But since it can’t do microtonality, it’s not much use in this particular case.

That’s a cute joke actually: 58600+ lines of decimal integers in https://raw.githubusercontent.com/supercollider/sc3-plugins/main/source/MdaUGens/mdaPianoData.h :laughing:

hjh

2 Likes

Wow. Was not expecting that!

1 Like