Sha256: fbe65df0f39a0fedc475ea60a9bbd87f4de4577d2a0ac82bb470064efa19e91e

Contents?: true

Size: 537 Bytes

Versions: 5

Compression:

Stored size: 537 Bytes

Contents

# encoding: utf-8
# frozen_string_literal: true
# grey circles : borrowed from https://github.com/quil/quil
require 'propane'

class GreyCircles < Propane::App

  def setup
    size(323, 200)
    smooth
    frame_rate(1)
    background(200)    
  end

  def draw
    stroke_setup
    diameter = rand(100)
    ellipse(rand(width), rand(height), diameter, diameter)
  end

  def stroke_setup
    [:stroke, :stroke_weight, :fill].each do |method|
      send(method, rand(255))
    end
  end
end

GreyCircles.new title: 'Oh so many circles'

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
propane-0.7.0-java examples/regular/grey_circles.rb
propane-0.6.0-java examples/regular/grey_circles.rb
propane-0.5.0-java examples/regular/grey_circles.rb
propane-0.4.0.pre-java examples/regular/grey_circles.rb
propane-0.3.0.pre-java examples/regular/grey_circles.rb