06.01.2013 Views

Learning Processing: A Beginner's Guide to Programming Images ...

Learning Processing: A Beginner's Guide to Programming Images ...

Learning Processing: A Beginner's Guide to Programming Images ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

x Introduction<br />

Traditionally, programmers are taught the basics via command line output:<br />

1. TEXT IN → You write your code as text.<br />

2. TEXT OUT → Your code produces text output on the command line.<br />

3. TEXT INTERACTION → Th e user can enter text on the command line <strong>to</strong> interact with the program.<br />

Th e output “ Hello, World! ” of this example program is an old joke, a programmer’s convention where the text<br />

output of the fi rst program you learn <strong>to</strong> write in any given language says “ Hello, World! ” It fi rst appeared in a<br />

1974 Bell Labora<strong>to</strong>ries memorandum by Brian Kernighan entitled “ <strong>Programming</strong> in C: A Tu<strong>to</strong>rial. ”<br />

Th e strength of learning with <strong>Processing</strong> is its emphasis on a more intuitive and visually responsive<br />

environment, one that is more conducive <strong>to</strong> artists and designers learning programming.<br />

1.<br />

2.<br />

3.<br />

TEXT IN → You write your code as text.<br />

VISUALS OUT → Your code produces visuals in a window.<br />

MOUSE INTERACTION → Th e user can interact with those visuals via the mouse (and more as<br />

we will see in this book!).<br />

<strong>Processing</strong> ’s “ Hello, World! ” might look something like this:<br />

Hello, Shapes!<br />

Th ough quite friendly looking, it is nothing spectacular (both of these fi rst programs leave out #3:<br />

interaction), but neither is “ Hello, World! ” However, the focus, learning through immediate visual<br />

feedback, is quite diff erent.<br />

<strong>Processing</strong> is not the fi rst language <strong>to</strong> follow this paradigm. In 1967, the Logo programming language was<br />

developed by Daniel G. Bobrow, Wally Feurzeig, and Seymour Papert. With Logo, a programmer writes<br />

instructions <strong>to</strong> direct a turtle around the screen, producing shapes and designs. John Maeda’s Design By<br />

Numbers (1999) introduced computation <strong>to</strong> visual designers and artists with a simple, easy <strong>to</strong> use syntax.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!