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

Tuesday, 19 November 2013

Testing the GLW renderer with ruby-processing

Andreas Colubri is working on an alternative renderer for processing (which seems to be stabilising as the GLW renderer). Here is an example sketch translated to ruby-processing requires processing-2.1.1 to run (OK development version as that is not currently available).
load_library :glw

include_package 'processing.glw'

def setup
  size(2560, 1440, GLW::P2D)
  frame_rate(180) # NB: here we are using the "processing" set frame rate method

def draw
  background(255, 0, 0)
  # NB: here we access "processing" frame rate variable 
  text("FPS: #{frame_rate}", mouse_x, mouse_y)

No comments:

Post a Comment


Blog Archive

About Me

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