Im trying to make .mp3 audio play from 3 separate arrays randomly. Each Array has 3 or 4 tracks. On a key or mouse press i want each array to play one track at the same time. Then on mouse press repeat and play a different 3 tracks.
My code is incomplete but I have
import ddf.minim.*;
import ddf.minim.analysis.*;
import ddf.minim.effects.*;
import ddf.minim.signals.*;
import ddf.minim.spi.*;
import ddf.minim.ugens.*;
import ddf.minim.*;
Minim minim;
AudioSample[] songArray = new AudioSample [10];
void setup()
{
size(100, 100);
minim = new Minim(this);
for (int i = 0 ; i < 3 ; i++) {
songArray[i] = minim.loadSample("sound" + i +".mp3");
}
for (int p = 0 ; p < 3 ; p++) {
songArray[p] = minim.loadSample("sounds" + p +".mp3");
}
for (int s = 0 ; s < 4 ; s++) {
songArray[s] = minim.loadSample("soundss" + s +".mp3");
}
}
void draw()
{
}
void mousePressed(){
.play();
}
If anyone can add useful pointers I'd be grateful
thanks