Sha256: 86d127eeb1cb9d92e5051ef9cdb1425972d9dd5b8bebdfc8f53cbe789556216b
Contents?: true
Size: 342 Bytes
Versions: 6
Compression:
Stored size: 342 Bytes
Contents
load_library :vecmath, :fastmath, :koch def setup size(800, 250) background(255) frame_rate(1) # Animate slowly @k = KochFractal.new(width, height) smooth 8 end def draw background(255) # Draws the snowflake! @k.render # Iterate @k.next_level # Let's not do it more than 5 times. . . @k.restart if @k.count > 5 end
Version data entries
6 entries across 6 versions & 1 rubygems