Archive for October, 2007

Along came a spider…

Wednesday, October 31st, 2007

spider screen shot
view the sketch—view the code

How do you use it?
Move the mouse up and down over the image.

What is it?
Happy Halloween!

Why is it cool?
It probably isn’t. Well, I did use a for loop to draw the concentric circles.

Pop! goes the matrix II

Tuesday, October 30th, 2007

pushMatrix(), popMatrix 2
view the sketch—view the code

How do you use it?
Move the mouse up and down over the image. Use the Up and Down cursor keys to change the size of the squares.

What is it?
Same thing as yesterday’s post, but re-written to work with any size square.

Why is it cool?
None of the parameters are hard-coded numbers. All of the translations and positioning are now based on the sqrSize variable.

Pop! goes the matrix.

Monday, October 29th, 2007

pushMatrix(), popMatrix
view the sketch—view the code

How do you use it?
Move the mouse up and down over the image.

What is it?
An example of how to use the pushMatrix() and popMatrix() functions for controlling changes to the coordinate grid.

Why is it cool?
The translate() and rotate() functions are often confusing to the uninitiated because they are cumulative in their effect, and it is easy to loose track of which end is up. pushMatrix() and popMatrix() give you the ability to localize the displacements and can help you keep your bearing.

Every day, eh?

Sunday, October 28th, 2007

When I began this project I knew it would be difficult; a program every day for a year. The more I think about it, aside from eating and brushing my teeth there are very few things that I do EVERY day. But, I’m doing my best to stick with it.

Actually, it turns out that writing a program on a daily basis has been much easier than posting a daily blog entry. It’s really two projects in one. So I’ve ended up with quite a backlog of Processing sketches. In the interest of just getting them all on-line I’m going to make an effort to push them all out in the next couple of weeks. I may have to skimp on some of the documentation at first, but it is more important for the integrity of the project to get them out there than to sit on them dreaming about how perfect they will be some day.

Drawing Tool

Saturday, October 27th, 2007

Drawing Tool
view the sketch—view the code

How do you use it?
Move the mouse around to draw a line. Click to add a shape.

What is it?
A drawing tool. Shows how to use mousePressed in an if statement within the draw() loop. The other way to use mousePressed is to set it up as a function. Maybe we’ll look at that tomorrow…

More Interactive Spectra

Wednesday, October 24th, 2007

More Interactive Spectra
view the sketch—view the code

How do you use it?
Move the mouse left and right over the image.

What is it?
Three nested for loops generate the R, G and B values of a bunch of lines.

Why is it cool?
Just having fun with yesterday’s sketch.

Interactive RGB Spectrum

Tuesday, October 23rd, 2007

Interactive RGB Spectrum
view the sketch—view the code

How do you use it?
Move the mouse left and right over the image.
What is it?
A for loop counts from 0-255. This counter is used to increment RGB values of stroke() and then draw parallel lines until the window is filled with color.

Why is it cool?
It’s not what I imagined it would be.