But Abletons, Massive, ABSynth & Synthmaster all sound like 12 evenly spaced notes.
I started making my own synth and found equations on the net like:
Code: Select all
x = (440. * exp(.057762265 * (x - 69.)));
But that only produces 12 evenly spaced notes, so is wrong.
I came up with:
Code: Select all
void CreateNoteTable(SAMPLE_TYPE *table)
{
int no = 0;
long double f = (long double)261.626; //C3
f /= (long double)2.0; //C2
f /= (long double)2.0; //C1
f /= (long double)2.0; //C0
f /= (long double)2.0; //C-1
f /= (long double)2.0; //C-2
for (int i = 0; i < NUM_FREQ; i++) // 128 midi notes
{
no++;
switch (no)
{
case 1:
{
table[i] = f + ((f / (long double)7.0) * (long double)0.0);
}
break;
case 2:
{
table[i] = f + ((f / (long double)7.0) * (long double)0.5);
}
break;
case 3:
{
table[i] = f + ((f / (long double)7.0) * (long double)1.0);
}
break;
case 4:
{
table[i] = f + ((f / (long double)7.0) * (long double)1.5);
}
break;
case 5:
{
table[i] = f + ((f / (long double)7.0) * (long double)2.0);
}
break;
case 6:
{
table[i] = f + ((f / (long double)7.0) * (long double)3.0);
}
break;
case 7:
{
table[i] = f + ((f / (long double)7.0) * (long double)3.5);
}
break;
case 8:
{
table[i] = f + ((f / (long double)7.0) * (long double)4.0);
}
break;
case 9:
{
table[i] = f + ((f / (long double)7.0) * (long double)4.5);
}
break;
case 10:
{
table[i] = f + ((f / (long double)7.0) * (long double)5.0);
}
break;
case 11:
{
table[i] = f + ((f / (long double)7.0) * (long double)5.5);
}
break;
case 12:
{
table[i] = f + ((f / (long double)7.0) * (long double)6.0);
f *= 2.0;
no = 0;
}
break;
table[i] *= 128.0;
}
}
}
Seems I'm a cleverer than the rest so Ill probably create a full synth and find out.
Probably shouldn't post my code as I seem to believe everyone else is totally stupid. lol
Edit: just found a mistake in my code so must be my old code, never mind hehe,
Thing is though if you investigate tuning some people use C3 as the start and some pro orchestra's use A3 as the start. Horses for courses I guess.