I am looking for a way to play chords (4 notes together), threw audiotrack.
What is the best way to do this?
I consider about starting from a single sampled note, applying pitch filters to it. Is there a simpler solution for doing this?
A simpler way is to have an audio file for each note.
To play them at the same you will need to sum the signals of all the files. A java virtual machine is not the best environment to do this, take a look at the ByteBuffer API if you want to do it this way.
0
pawlinsky
On
You can also use audiotrack objects in 4 different threads, so the write methode of AudioTrack won't block the other audiotracks playing sounds, I do this with 5 threads and it works.
A simpler way is to have an audio file for each note.
To play them at the same you will need to sum the signals of all the files. A java virtual machine is not the best environment to do this, take a look at the ByteBuffer API if you want to do it this way.