etudes in code, with processing

19
Etudes in code (even if you’re not a coder, yet) flavors.me/peterkiRn The tool: processing.org (Ben Fry, Casey Reas, et al) Friday, July 22, 2011

Upload: peter-kirn

Post on 28-Nov-2014

1.483 views

Category:

Technology


2 download

DESCRIPTION

Slides from a presentation to SCOPE Session, presented by Visual Berlin - http://scopesessions.org

TRANSCRIPT

Page 1: Etudes in Code, with Processing

Etudes in code(even if you’re not a coder, yet)

flavors.me/peterkiRn

The tool: processing.org(Ben Fry, Casey Reas, et al)

Friday, July 22, 2011

Page 2: Etudes in Code, with Processing

The blank page

Friday, July 22, 2011

Page 3: Etudes in Code, with Processing

Processing is

a free place

to express ideas

about design with media

in textual

code.

Friday, July 22, 2011

Page 4: Etudes in Code, with Processing

Data: Load an image

PImage img;

loadImage(“image.jpg”);

or

loadImage([uri]);

image(img,0,0);

Friday, July 22, 2011

Page 5: Etudes in Code, with Processing

Interaction

The appearance of movement

Response to an input

mouseX, mouseY

“Draw loop”

setup(), draw()

Friday, July 22, 2011

Page 6: Etudes in Code, with Processing

Adding a behavior

Variables

random(minimum, maximum);

Precision: floats, integers

Friday, July 22, 2011

Page 7: Etudes in Code, with Processing

Adding a behavior

Sampling

color c = img.get(x,y);

or

img.loadPixels();

img.pixels[x,y];

Friday, July 22, 2011

Page 8: Etudes in Code, with Processing

Transparency is magic

gray, alpha

r,g,b,alpha

etc.

Friday, July 22, 2011

Page 9: Etudes in Code, with Processing

Loops and iteration

for(int i=0;i<num;i++) {

//do something ... more than once

}

Friday, July 22, 2011

Page 10: Etudes in Code, with Processing

3D

Different renderers; OPENGL

Mobile, too

Deconstructing an image

Textures

Friday, July 22, 2011

Page 11: Etudes in Code, with Processing

I love waves and circles

Friday, July 22, 2011

Page 12: Etudes in Code, with Processing

Structure isdesign, form

Friday, July 22, 2011

Page 13: Etudes in Code, with Processing

Structure isdesign, form

Friday, July 22, 2011

Page 14: Etudes in Code, with Processing

Adding structure

Method

output doSomething(input variables) {

}

cupcake bake(cup of sugar, etc., etc.) {

}

Friday, July 22, 2011

Page 15: Etudes in Code, with Processing

Adding structure

Class

class Thing {

Thing(inputs) { //make the thing

}

doSomething(input) { }

}

Friday, July 22, 2011

Page 16: Etudes in Code, with Processing

Lists

A group of some kind of things

The ability to point at something in the list

ArrayList<Integer>

.add()

.get()

Friday, July 22, 2011

Page 17: Etudes in Code, with Processing

Let’s talk

Q+A

http://flavors.me/peterkirn

http://createdigitalmotion.com

Follow up series to come

Friday, July 22, 2011

Page 18: Etudes in Code, with Processing

Remember,

no

fear.

Friday, July 22, 2011

Page 19: Etudes in Code, with Processing

Photo creditsSine waves - CC-BY Jason Hargrove

Flickr: salty_soul

Machine scan - CC-BY zigazouFlickr: zigazou76

Striped boots - CC-BY Cameron RussellFlickr: camkage (Lomo-Cam)

US flag stripes - CC-BY Sam HowzitFlickr: aloha75

Friday, July 22, 2011