Coding (Session 1)
October 10, 2013 § Leave a comment
Thinking & Practice
This first session was an introductory lesson on how to create codes on the Processing app and what different things you can do with them. We typed in various codes and learned their meaning in order to make the app do certain things. Initially we inserted text into the app, after this we put in different pinpoints so that the app would draw a line for us. Then we added more pinpoints and commands so that the line would repeat itself in a spiralling motion.
We then went on to saving a random passport image as a jpeg and setting up the codes in Processing in a similar style to last week’s session. Having saved the photo as a ‘source’ image in a folder on the desktop, we then used the codes to link it to Processing so the image could then be opened.
We then went about finding a random pixel in the image and pinpoint it somwhere else on the screen. We type in a code into processing that allowed it to tell us exactly how many pixels there are in the image. Mine consisted of 124,000 pixels. We chose a number a number between 0 and the number of pixels there were and embedded it into the code.
After this we selected a random rectangle and told the app to cut and stick a certain portion of the image repeatedly. The result is as shown.