Experiments with ruby-processing (processing-2.2.1) and JRubyArt for processing-3.0

Saturday 13 July 2013

Minimalist Perlin noise sketch in ruby-processing

In response to a Casey Reas challenge, R Brauer published a vanilla processing sketch which I've re-coded in ruby:-
S, V, D = 400, [], 0.02

def draw
  S.times { |a| V << [a, rand * S]; g = noise(V[a][0] * D, V[a][1] * D) * 6; point(V[a][0] += sin(g), V[a][1] += cos(g))}
end

No comments:

Post a Comment

Followers

Blog Archive

About Me

My photo
I have developed JRubyArt and propane new versions of ruby-processing for JRuby-9.1.5.0 and processing-3.2.2