Skip to content

Instantly share code, notes, and snippets.

@jashkenas
Created April 28, 2009 01:32
Show Gist options
  • Save jashkenas/102869 to your computer and use it in GitHub Desktop.
Save jashkenas/102869 to your computer and use it in GitHub Desktop.
load_library 'video'
import 'processing.video.MovieMaker'
def setup
size 300, 150
@mm = MovieMaker.new(self, width, height, "drawing.mov")
background 20, 20, 100
fill 147, 246, 258, 20
smooth
no_stroke
end
def draw
pace = frame_count * 7
ellipse pace, height / 2 + sin(frame_count / 2.5) * 30, 30, 30
@mm.add_frame
if pace > width
@mm.finish
exit
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment