trig one-liners

October 10th, 2011. Filed under: processing.

Inspired by Robert Hodgin’s Introduction to Cinder, I started experimenting with animated patterns using trigonometry functions in Processing.js. The size of the circles are calculated by a single line of code which uses their x,y position and an angle variable that is incremented over time. Here’s one of them: “ellSize = sin(x*y+angle)*7 + cos(angle)*8;”. Things got pretty op-arty! Click to cycle through different patterns:

Leave a Reply

You must be logged in to post a comment.