Cherry Blossoms

Saw this tree thing done by Jared Tarbell sometime ago, here’s my take on it. Used the cherry blossoms since I think they look pretty cool. Figured I could create a growing tree using recursion (i think that’s what a function that calls itself is called). Used the undocumented setTimeout function in lieu of an otherwise messy setInterval setup. There are some performance issues when the number of branches top over a thousand, but it seems to run pretty ok. No source yet coz its a bowl of spaghetti.

I just realized this would look really cool if it was projected on a wall with a motion sensor. As people walk by, a new tree would grow or maybe a bunch of trees trailing the person walking.


About this entry