Learn creative coding writing simple programs

144. Drawing animated loops

By using an array of PGraphics, in this episode we draw looping flipbooks. The idea is simple: we have a constantly playing animation of 20 frames, and we are able to draw on it. When the mouse is pressed, our ink ends up in the current frame, whichever that is. The resulting effect is quite interesting. Once you have the program running, you can learn different drawing tricks, but I leave that to your own imagination :)

Here two drawings I created using this technique: http://hamoid.tumblr.com/post/65383946931/a-small-loop-drawing-processing-program-inspired

Tags: loop, animation, draw

Code editor

You can make changes to the code below. Then

Questions and comments

Try to stay close to the topic of this episode. Use the Processing forums for help with unrelated Processing projects (or hire me for help ;-)

To indicate that a word in your comment is code, use the `backtick`. Example
Do `float` and `int` smell similar?
To highlight code blocks, surround it with ``` code-fences ``` like this:
``` void setup() { size(600, 600); } ```