Reference edits for 2.0, text corrections

This commit is contained in:
Casey Reas
2012-11-20 21:40:43 +00:00
parent fadec581ce
commit f594ff3746
2 changed files with 5 additions and 4 deletions

View File

@@ -20,6 +20,7 @@ void setup() {
float amount = map(i, 0, width, 0, PI);
coswave[i] = abs(cos(amount));
}
background(255);
noLoop();
}
@@ -27,21 +28,21 @@ void draw() {
int y1 = 0;
int y2 = height/3;
for (int i = 0; i < width; i++) {
for (int i = 0; i < width; i+=2) {
stroke(coswave[i]*255);
line(i, y1, i, y2);
}
y1 = y2;
y2 = y1 + y1;
for (int i = 0; i < width; i++) {
for (int i = 0; i < width; i+=2) {
stroke(coswave[i]*255 / 4);
line(i, y1, i, y2);
}
y1 = y2;
y2 = height;
for (int i = 0; i < width; i++) {
for (int i = 0; i < width; i+=2) {
stroke(255 - coswave[i]*255);
line(i, y1, i, y2);
}