Trabajo N° 6 pizarra
De Casiopea
Título | trabajo N° 6 pizarra |
---|---|
Tipo de Proyecto | Proyecto de Taller |
Palabras Clave | tarea 6 |
Período | 2012-2012 |
Asignatura | Imagen Escrita 2012, |
Del Curso | Imagen Escrita 2012, |
Carreras | Arquitectura, Diseño Gráfico"Diseño Gráfico" is not in the list (Arquitectura, Diseño, Magíster, Otra) of allowed values for the "Carreras Relacionadas" property., Diseño Industrial"Diseño Industrial" is not in the list (Arquitectura, Diseño, Magíster, Otra) of allowed values for the "Carreras Relacionadas" property. |
Alumno(s) | Daniel Galaz |
Profesor | Herbert Spencer |
int c; float d; float grosor; float x=99; float y= 99; float speed= 9;
void setup () {
size (700, 700); background(0); smooth(); c= color(255);//color inicial del trazo, como lapiz grafito//
} void draw () {
move(); display(); if (mousePressed) {//trazo cuadrado, "pintar"// fill(c); stroke(c, 10); d =dist (mouseX, mouseY, pmouseX, pmouseY); grosor = map (d, 0, 10, 1, 100); strokeWeight (d); //grosor de la línea line(mouseX, mouseY, pmouseX, pmouseY); rect (mouseX, mouseY, 1, 1 );//pinta a cuadrados// } if (key=='q') {//trazo circular, "dibuja"// if (mousePressed) { fill(c); stroke(c); d =dist (mouseX, mouseY, pmouseX, pmouseY); grosor = map (d, 0, 10, 1, 100); strokeWeight (d); strokeCap (PROJECT); line(mouseX, mouseY, pmouseX, pmouseY); ellipse (mouseX, mouseY, 1, 1 ); } }
} void move() {
x=x*speed; if (x>width) { x=350; } y=y+20; if (y<height) { y=20; }
} void display() {
fill(c, 10); triangle(x, y,40, 50, 10, 50);
} //BOTONES DE GRABAR Y COLORES//
void keyPressed() {
if (key == 'g') { saveFrame ("img/######.jpg"); } if (key == 'b') { //borra todo background (0); } if (key=='c') {//borrador c=color(0); } if (key=='r') { c= color(#A50A0A, 100);//rojo } if (key=='v') { c=color(#255F25, 100);//verde } if (key=='y') { c=color(#E9F200, 100);//amarillo } if (key=='a') { c=color(#1000FF, 100);//azul } if (key=='w') { c=color(255);//blanco }
}