Created
July 27, 2019 14:48
-
-
Save jamesmichiemo/a52bb3396f8cecc601258ed2205db60a to your computer and use it in GitHub Desktop.
processing + propane sketch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env jruby | |
# frozen_string_literal: false | |
require 'propane' | |
# row and columns | |
# propane graffiti by 8mana | |
# based on code by Casey Reas and Ben Fry | |
class RowColumns < Propane::App | |
def settings | |
size 480, 120 | |
end | |
def setup | |
sketch_title 'rows and columns' | |
end | |
def draw | |
background 0 | |
$y = 0 | |
while $y <= height+45 do | |
fill 255, 140 | |
ellipse 0, $y, 40, 40 | |
$y +=40 | |
end | |
$x = 0 | |
while $x <= width+45 do | |
fill 255, 140 | |
ellipse $x, 0, 40, 40 | |
$x +=40 | |
end | |
end | |
end | |
RowColumns.new |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment