Donny Ahumada Pizarra tarea 4
De Casiopea
Título | Pizarra colores |
---|---|
Tipo de Proyecto | Proyecto de Curso |
Palabras Clave | tarea 4 |
Asignatura | Taller Inicial 1ª y 2ª Etapa, Taller Inicial Común 1ª y 2ª Etapa, |
Del Curso | Imagen Escrita 2012, |
Carreras | 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. |
Alumno(s) | Donny Ahumada |
Profesor | Herbert Spencer |
PFont helv; int r = 255; int g = 255; int b = 255; int w = 1; int u,i,o,p;
void setup() {
size (700,700); background (0); helv = loadFont("Helvetica37-CondensedThin-48.vlw"); textFont (helv, 14); fill(255); text ("Presione tecla para cambiar color y tamaño de lápiz", 15,18); text ("Presione botón derecho del mouse para borrar", 400, 18); text ("A", 15, 36); text ("B", 45, 36); text ("C", 75, 36); text ("D", 105, 36); text ("E", 135, 36); text ("F", 165, 36); text ("G", 195, 36); stroke (0); strokeWeight(0); fill (181,230,29); rect (25, 24, 14, 14); fill (255,200,10); rect (55, 24, 14, 14); fill (255,0,0); rect (85, 24, 14, 14); fill (22,74,255); rect (115, 24, 14, 14); fill (107,0,179); rect (145, 24, 14, 14); fill (40,255,148); rect (175, 24, 14, 14); fill (255,255,255); rect (205, 24, 14, 14);
stroke (255,255,255); /*stroke (255); strokeWeight (1); line (310, 14, 330, 14); fill (255); text ("1", 300, 18); strokeWeight (4); line (312, 32, 328, 32); text ("2", 300, 36); strokeWeight (6); line (356, 14, 374, 14); text ("3", 340, 18); strokeWeight (10); line (358, 32, 372, 32); text ("4", 340, 36);*/
saveFrame ("pizarra.jpg");
}
void draw() {
smooth(); float j = random (1,10); strokeWeight(j); /*strokeWeight(w);*/ stroke (r,g,b); if (mousePressed == true && (mouseButton == RIGHT)) { setup(); }
}
void mouseDragged() {
u = mouseX; i = mouseY; o = pmouseX; p = pmouseY; line (u,i,o,p);
}
void keyPressed() {
if ((key == 'a') || (key == 'A')) { r = 181; g = 230; b = 29; } if ((key == 'b') || (key == 'B')) { r = 255; g = 200; b = 10; } if ((key == 'c') || (key == 'C')) { r = 255; g = 0; b = 0; } if ((key == 'd') || (key == 'D')) { r = 22; g = 74; b = 255; } if ((key == 'e') || (key == 'E')) { r = 107; g = 0; b = 179; } if ((key == 'f') || (key == 'F')) { r = 40; g = 255; b = 148; } if ((key == 'g') || (key == 'G')) { r = 255; g = 255; b = 255; } /*if ((key == '1') || (key == '1')) { w = 1; } if ((key == '2') || (key == '2')) { w = 4; } if ((key == '3') || (key == '3')) { w = 6; } if ((key == '4') || (key == '4')) { w = 10; }*/
}