Book Image

Processing 2: Creative Coding Hotshot

By : Nikolaus Gradwohl
Book Image

Processing 2: Creative Coding Hotshot

By: Nikolaus Gradwohl

Overview of this book

Processing makes it convenient for developers, artists, and designers to create their own projects easily and efficiently. Processing offers you a platform for expressing your ideas and engaging audiences in new ways. This book teaches you everything you need to know to explore new frontiers in animation and interactivity with the help of Processing."Processing 2: Creative Coding Hotshot' will present you with nine exciting projects that will take you beyond the basics and show you how you can make your programs see, hear, and even feel! With these projects, you will also learn how to build your own hardware controllers and integrate devices such as a Kinect senor board in your Processing sketches.Processing is an exciting programming environment for programmers and visual artists alike that makes it easier to create interactive programs.Through nine complete projects, "Processing 2: Creative Coding Hotshot' will help you explore the exciting possibilities that this open source language provides. The topics we will cover range from creating robot - actors performing Shakespeare's "Romeo and Juliet", to generating objects for 3D printing, and you will learn how to run your processing sketches nearly anywhere from a desktop computer to a browser or a mobile device.
Table of Contents (16 chapters)
Processing 2: Creative Coding Hotshot
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Mission Accomplished


Our current mission was to build a custom input controller for our Smilie-O-Mat. We started with a variable resistor and connected it to the Arduino—an AVR microcontroller development board. Arduino is programmed in C++, but the API is very similar to the Processing language, and the Arduino IDE uses the same framework as the Processing IDE. We created a program in the Arduino IDE that reads the value of our resistor and sends it to the computer via a serial port. On the Processing side, we used the serial library to read the messages and display them.

In the second task, Building your controller, we created a prototype of the controller by connecting three variable resistors and a button to a solderless breadboard. We created a simple protocol for the messages we send to the computer, which allowed us to send the value of the input and also which controller has changed. The button sends a click message to the computer every time the push button's state changes from pressed...