I am trying to develop an application similar to tonematrix in C #. I tried first with the .net and NAudio library, now I'm trying with XNA, but it looks like all I can get is cacophony.
With NAudio, I generate 8 simple sine waves with different frequencies, ranging from (440 Hz * 1) to (440 Hz * 8).
With XNA, I use several SoundEffectInstance of the same audio file (for example, note D4 for piano), each of which has a different Pitch value; the Pitch value can rise or fall by a maximum of an octave.
In both cases, when the sounds overlap, I get noise instead of music. Maybe I misunderstood everything, and this is not about mixing sounds of different tones / frequencies.
It’s hard for me to believe that tonematrix uses nothing more than a “simple sinusoidal synthesizer” because the sounds are quite rich and when they mix together they always generate a harmonic melody, while a simple sinusoid always sounds ugly and artificial to me.
Do I have a bad approach to creating harmonies? Do you have an idea of what exactly is happening with the sinusoids used by tonematrix?
source
share