Featuring JRuby-9.1.5.0 and processing-3.2.1
Ruby Java
Latest commit 4bf9128 Oct 8, 2016 @monkstone monkstone committed on GitHub Update README.md
Permalink
Failed to load latest commit information.
chp01_vectors
chp02_forces
chp03_oscillation
chp04_systems
chp05_physicslibraries
chp06_agents Guess what even more keyword args Sep 2, 2015
chp07_CA
chp08_fractals
chp09_ga
chp10_nn finishing off Sep 3, 2015
.gitignore modified: .gitignore Jul 25, 2015
LICENSE
README.md

README.md

The-Nature-of-Code-Examples-in-JRubyArt

A new ruby port of the examples from The Nature of Code by Daniel Shiffman. Samples have been adapted to run with JRubyArt (processing-3.1+ and ruby-2.2+), from the original ruby port, which should be used with ruby-processing (processing-2.2.1 and ruby-1.9.3). Some of the changes in this version are required because of changes to processing (eg. size now belongs in settings), but others have been made to take advantage of newer ruby syntax. In particular the fact keyword arguments are now first class citizens, so argument order should no longer be an issue, and method signatures can have more meaning.

Although many of the sketches here stand on their own merit, you should remember that they were originally designed to illustrate the book (so to get the most from them you should definetly get the book). Since the sketches have been translated to a more idiomatic ruby, some of the sketches may not exactly match the points made in the book. However such sketches do serve to demonstrate the differences between processing and JRubyArt. Since the book is now also available in Japanese it would be great if someone would fork this and add Japanese annotations. For the most part the code is just ruby and processing, but see glossary for some convenience methods unique to JRubyArt (eg load_library, map1d, constrained_map).

Tested versions

ruby 2.2

jruby-9.1.5.0

JRubyArt gem version 1.2.4 (processing-3.2.1)

pbox2d gem version 0.9.1