This is a product that I’ll come back to later – but wanted to introduce now so people could explore. In Computer Science education, kids are still stuck in what “computer programming” looks like – they want lines of code and a color inverted screen, they want semi-colons and “var =”, but they don’t understand the struggle to get there. Most self taught programmers that use this stuff didn’t think twice about why these things were like the were, they just knew to memorize them so they could get to the next part. Today’s students question everything (not a bad things at all) so saying “that’s just how it is” doesn’t always work like it used to. When Java comes up, students want to interact with it but that involves a sometimes complicated loading of additional packages and files. Processing is built from the MIT Media Lab and skips a lot of that and has a simple language that you can start “drawing” in right away!
April 11th – Processing
Processing is a Java based programming language with a canvas built in. This means that you can simply type “rect(10, 10, 50, 50);” and a rectangle will pop up on the screen in the default canvas.
The single line of code breaks down like this:
- rect is rectangle, the shape you are drawing
- the first 10 is the x-position starting point, with the origin always in the top left corner (for a rectangle)
- the second 10 is the y-position starting point
- the first 50 is the width
- the second 50 is the height
Basically within that single line of code you’ve instructed the computer to draw a rectangle that starts at x-position and y-position 10 (with 0,0 on the canvas always in the top left corner to avoid negative values) and make it 50 pixels wide and 50 pixels in height. And that is simply what a lot of computer programming is, giving the computer instructions to perform a task. For a fun bonus, replace the x-pos and y-pos with “mouseX” and “mouseY” and check out the documentation to change the size of the canvas. Then you’ve got something interactive!