10. November 2010
the planet earth image is attached to the mouse.PImage[] imageList = null; // variable sauber initialisieren void setup() { size(600,600); // def. fenstergroesse imageList = new PImage[4]; imageList[0] = loadImage("./images/1.png"); imageList[1] = loadImage("./images/2.png"); imageList[2] = loadImage("./images/3.png"); imageList[3] = loadImage("./images/4.png"); } void draw() { background(0); pushMatrix(); translate(90,100); for(int i=0;i < imageList.length-1; i++) { image(imageList[i],0,0,140,140); translate(150,0); } popMatrix(); imageMode(CENTER); //rotate(PI/0.3); image(imageList[3],mouseX,mouseY,140,140); } void mousePressed() { } void mouseDragged() { } void mouseReleased() { println("released"); }