Andrefaupel (talk | contribs) |
Andrefaupel (talk | contribs) |
||
Line 2: | Line 2: | ||
=Jonas Jülch= | |||
[[File:Pixel_pattern_jonas.jpg|300px|thumb|]] | [[File:Pixel_pattern_jonas.jpg|300px|thumb|]] | ||
Line 121: | Line 121: | ||
=Andre Faupel= | |||
<gallery> | <gallery> | ||
File:Af_houseworm.png | File:Af_houseworm.png | ||
Line 129: | Line 129: | ||
based on the patch by jonas | based on the patch by jonas | ||
you can find the code [http://pastebin.com/etYe2LxU | you can find the code [http://pastebin.com/etYe2LxU here] | ||
==Group B== | ==Group B== |
Revision as of 18:56, 20 November 2014
Group A
Jonas Jülch
float rotationVal = -0.02;
void setup(){
size(1000, 600);
}
void draw(){
background(40,50,60);
pattern();
}
void pattern(){
pushMatrix(); for(int i = 0; i < 10 ; i++){ stroke(22,188,229); pattern1(); stroke(22,100,229); pattern2(); translate(0,100); } popMatrix(); pushMatrix(); for(int i = 0; i < 10 ; i++){ stroke(100,255,61); pattern3(); stroke(100,160,61); pattern4(); translate(100,0); }
popMatrix();
}
void pattern1(){
float mid = width * 0.5; for(int i = 0; i < 10 ; i++){
line (0,10*i, mid, 0); line (0,10*i, mid, 100); pushMatrix(); rotate(rotationVal); popMatrix();
}
}
void pattern2(){
float mid = width * 0.5; for(int i = 0; i < 10 ; i++){
line (mid,0, 1000, 10*i); line (mid,100, 1000 , 10*i); pushMatrix(); rotate(rotationVal); popMatrix();
}
}
void pattern3(){
float midy = height * 0.5; for(int i = 0; i < 10 ; i++){
line (10*i,0, 0, midy); line (10*i,0 , 100, midy); pushMatrix(); rotate(rotationVal); popMatrix();
}
}
void pattern4(){
float midy = height * 0.5; for(int i = 0; i < 10 ; i++){
line (0, midy, 10*i, 600); line (100, midy, 10*i, 600); pushMatrix(); rotate(rotationVal); popMatrix();
}
}
Andre Faupel
based on the patch by jonas
you can find the code here
Group B
Dhora Tego
float r, g, b;
void setup(){
size(500,500); background(255);
}
void draw(){
for(int x=0; x<500; x+=60+60*sin(PI/6)){ for(int y=0; y<500; y+=60*cos(PI/6)){ drawHexagon(x, y, 30); drawHexagon(x+30+30*sin(PI/6), y+30*cos(PI/6), 30); }
} }
void drawHexagon(float x, float y, float radius) {
pushMatrix(); translate(x, y); beginShape(); for (int i = 0; i < 6; i++) { pushMatrix(); float angle = PI*i/3; vertex(cos(angle) * radius, sin(angle) * radius); popMatrix(); } endShape(CLOSE);[ popMatrix(); fill (mouseX, (mouseX+mouseY), mouseY); ellipse ( x, y, 40, 40 ); rect ( x, y, 10, 10 );
}
Group C
Group D
Maria Estel
void setup () { size(displayWidth, displayHeight); }
void draw () {
if (mousePressed) { background(255,120,0); pushMatrix(); translate(1600,700); for (int i=10; i<width; i+=1){ rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(20,20,20); stroke(0); } } else {
background(20,20,20);
pushMatrix(); translate(250,250); for (int i=10; i<width; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(255,120,0); stroke(0); }
}
popMatrix(); }
Carina Weiß
void setup () { size(displayWidth, displayHeight); }
void draw () { background(0);
pushMatrix(); translate(1500,500); for (int i=10; i<width; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255,215,0); } popMatrix();
pushMatrix(); translate(450,250); for (int i=10; i<150; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255); } popMatrix();
pushMatrix(); translate(250,650); for (int i=10; i<150; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255); } popMatrix();
pushMatrix(); translate(1000,400); for (int i=10; i<100; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255); } popMatrix();
pushMatrix(); translate(800,600); for (int i=10; i<100; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255); } popMatrix();
pushMatrix(); translate(1100,700); for (int i=10; i<100; i+=1){
rectMode(CENTER); rotate(mouseY); rect(i,i,20,20); fill(0); stroke(255); } popMatrix(); }
Fernando Millan
void setup () { size(2000, 1000); } void draw () { background(20, 20, 20); float Mouse = 5+(mouseX/100); float Distance = mouseX; float MY = mouseY*.90;
if (mousePressed) { noStroke(); } else { stroke(0); } pushMatrix(); translate(666, height*0.5); for (int i=30; i<MY; i+=5) { for (int F=0; F<Mouse; F+=1) { if ( i % 2 == 0) { fill(100, 50); } else { fill(255, 0, 0, 50); } rectMode(CENTER); rotate(radians(F)); rect(i, i, 30, 30); } } popMatrix(); //println (mouseY); //println (mouseX); }
Rubab Paracha
OPTION 1
void setup () {
size (800,800);
}
void draw (){
element ();
}
void element () {
frameRate(3); background (0); stroke(0);
pushMatrix(); translate(width * 0.5, width * 0.5 ); for(int i= 3; i < width; i++){
rotate(mouseX * 0.0005); rect(i,i,30,30); fill(random(255),random(255),random(255), 150); } popMatrix(); }
OPTION 2
void setup () {
size (800,600); //(displayWidth,displayHeight);
}
void draw (){
background (255); translate (width * 0.08, height * 0.08 ); element1 (); translate (width * 0.25, height * 0.25 ); element2 (); translate (width * 0.25, height * 0.25 ); element1 (); translate (width * 0.25, height * 0.25 ); element2 ();
}
void element1 () {
frameRate(4); stroke(0);
pushMatrix(); for(int i= 1; i < width/5; i++){
rotate(mouseX * 0.001); ellipse(i,i,20,20); fill(0,150); } popMatrix(); }
void element2 () {
frameRate(4); stroke(0);
pushMatrix(); for(int i= 2; i < width/2; i++){
rotate(-mouseY * 0.001); rect(i,i,10,10); fill(0, 150); } popMatrix(); }