A)
color ruby = color(211, 24, 24, 160);
color pink = color(237, 159, 176);
background(pink);
noStroke();
fill(ruby);
rect(35, 0, 20, 100);
B)
size(100, 100);
ellipse(width*0.5, height*0.5, width*0.66,
height*0.66);
line(width*0.5, 0, width*0.5, height);
line(0, height*0.5, width, height*0.5);
C)
background(56, 90, 94);
smooth();
int x = 0;
strokeWeight(12);
for (int i = 51; i <= 255; i += 51) {
stroke(242,
204, 47, i);
line(x, 20,
x+20, 80);
x += 20;
}
D)
triangle(55, 9, 110, 100, 85, 100);
triangle(55, 9, 85, 100, 75, 100);
triangle(-1, 46, 16, 34, -7, 100);
triangle(16, 34, -7, 100, 40, 100);
E)
fill(0);
rect(0, 40, 100, 20);
fill(255, 51);
rect(0, 20, 33, 60);
fill(255, 127);
rect(33, 20, 33, 60);
fill(255, 204);
rect(66, 20, 33, 60);
F)
rect(20, 15, 20, 70);
noStroke();
rect(50, 15, 20, 70);
rect(80, 15, 20, 70);
G)
size(100, 100);
ellipse(width*0.5, height*0.5, width*0.66,
height*0.66);
line(width*0.5, 0, width*0.5, height);
line(0, height*0.5, width, height*0.5);
H)
colorMode(HSB);
for (int i = 0; i < 100; i++) {
stroke(132,
i*2.5, 204);
line(i, 0, i,
100);
}
I)
colorMode(HSB);
for (int i = 0; i < 100; i++) {
stroke(132,
108, i*2.5);
line(i, 0, i,
100);
}
J)
fill(0, 76);
noStroke();
smooth();
for (int y = -10; y <= 100; y += 10) {
for (int x = -10; x
<= 100; x += 10) {
ellipse(x + y/8.0, y + x/8.0, 15 + x/2,
10);
}
}
K)
noStroke();
fill(0);
beginShape();
vertex(40, 10);
for (int i = 20; i <= 100; i += 5) {
vertex(20, i);
vertex(30, i);
}
vertex(40,
100);
endShape();
L) RECORTAR
EL GRÁFICO ute.jpg
PImage img;
img = loadImage("ute.jpg");
tint(102); // tonalidad Tint gray
image(img, 0, 0);
noTint();
image(img, 50, 0);
M)
PImage img;
img = loadImage("ute.jpg");
tint(0, 153, 204); // tonalidad Tint azul
image(img, 0, 0);
noTint();
image(img, 50, 0);
N)
color yellow = color(220, 214, 41);
color green = color(110, 164, 32);
color tan = color(180, 17, 132);
PImage img;
img = loadImage("ute.jpg");
tint(yellow);
image(img, 0, 0);
tint(green);
image(img, 33, 0);
tint(tan);
image(img,
66, 0);
O)
PImage img;
img = loadImage("ute.jpg");
background(255);
tint(255, 102);
image(img, 0, 0, 100, 100);
tint(255, 204, 0, 153);
image(img, 20, 20, 100, 100);
P)
PImage img;
img = loadImage("ute.jpg");
background(255);
tint(255,
51);
//
Dibuja la imagen 10 veces, moviéndose a la derecha
for (int i = 0; i < 10; i++) {
image(img,
i*10, 0);
}
Q)
size(700, 100);
noStroke();
fill(0);
float angle = 0.0;
for (int x = 0; x <= width; x += 5) {
float y = 50 +
(sin(angle) * 35.0);
rect(x, y, 2, 4);
angle +=
PI/40.0;
}
R)
smooth();
noFill();
randomSeed(0);
strokeWeight(10);
stroke(0, 150);
for (int i = 0; i < 160; i += 10) {
float inicio =
radians(i);
float fin = inicio
+ HALF_PI;
arc(67, 37, i, i,
inicio, fin);
}
S)
smooth();
noFill();
randomSeed(0);
strokeWeight(10);
stroke(0, 150);
for (int i = 0; i < 160; i += 10) {
float inicio =
radians(i);
float fin = inicio
+ HALF_PI;
arc(67, 37, i, i,
inicio, fin);
}
T)
noStroke();
smooth();
float radio = 1.0;
for (int grado = 0; grado < 360*6; grado += 11) {
float angulo =
radians(grado);
float x = 75 + (cos(angulo) * radio);
float y = 42 + (sin(angulo) * radio);
ellipse(x, y, 6, 6);
radio = radio +
0.34;
}
U)
smooth();
strokeWeight(10);
stroke(0, 130);
line(0, random(100), 100, random(100));
line(0, random(100), 100, random(100));
line(0, random(100), 100, random(100));
line(0, random(100), 100, random(100));
line(0, random(100), 100, random(100));
V)
smooth();
strokeWeight(20);
stroke(0, 230);
float r = random(5, 45);
stroke(r * 5.6, 230);
line(0, r, 100, random(55, 95));
r = random(5, 45);
stroke(r * 5.6, 230);
line(0, r, 100, random(55, 95));
r = random(5, 45);
stroke(r * 5.6, 230);
line(0, r, 100, random(55, 95));
W)
size(100, 100);
translate(width/2, height/2);
line(-width/2, 0, width/2, 0);
line(0, -height/2, 0, height/2);
smooth();
noStroke();
fill(255, 204);
ellipse(0, 0, 45, 45);
ellipse(-width/2, height/2, 45, 45);
ellipse(width/2, -height/2, 45, 45);
X)
void setup() {
size(100,
100);
noStroke();
smooth();
}
void draw() {
fill(255);
ellipse(50,
50, 60, 60);
fill(0);
ellipse(50+10,
50, 30, 30);
fill(255);
ellipse(50+16,
45, 6, 6);
}
Y)
void setup() {
size(100,
100);
noStroke();
smooth();
}
void draw() {
fill(255);
ellipse(50,
50, 60, 60);
fill(0);
ellipse(50+10,
50, 30, 30);
}
Z)
void setup() {
size(100,
100);
}
void draw() {
for (int i =
0; i < 50; i += 2) {
point(mouseX+i, mouseY+i);
}
}