import processing.opengl.*; import processing.video.*; import netscape.javascript.*; float xtime = 3.85; float ytime = 50.0; float a= 5; float increment = 0.008; float ztime = 10.0001; float ttime = 10.0; void setup(){ size(720,400, P3D); background(255); } void draw(){ background(20,20,20,5); //noise movimento float x = noise(xtime)*width; float y = noise(ytime)*height; xtime += increment; ytime += increment; //primeiro rect fill(200,0,0,63); stroke(153,0,0,127); translate(mouseX/100+ x, mouseY/100+ y, 0); rotateY(x/10-(y/100)); box(20,20,70); float z = noise(ztime)*width/2; float t = noise(ttime)*height/2; ztime += increment; ytime += increment; //2 rect fill(200,0,0,63); stroke(153,0,0,127); translate(mouseX/100+ x, mouseY/100+ y, 0); rotateY(y); box(50,60,70); }