Recently I've been looking at Povray, pyprocessing, and cfdg (version 3.0) as tools for creating digital images. I have branched two separate blogs where I mainly explore jruby + processing and

Sunday, 22 August 2010

LSystemUtilities for Processing

I've noticed a big uptrend in interest in my LSystem library since it got included in the Processing contributed libraries section.  There are proportionally fewer downloads than I expected, perhaps more people are downloading the source via SVN or git (but I doubt it).  Why should you want to download it:-

1. It is simple

2. Here are links to stuff I've done with it

Bent Hilbert
Rod Hilbert   Features use of cos/sin look up table utility
Peano Curve
Animated LSystem
Another Animated LSystem
A fern fractal I created before I implemented the Pen class, you could try converting it to use the new Pen class as an exercise.

Why did I create the library, well mainly for the experience?
What inspired me? Jeremy Ashkenas ruby-processing context free DSL.
It is that inspiration that made me try to keep things simple, using domain specific terminology and standard LSystem notation. One of the disappointments of java is how bloody complicated it has become it is a Behemoth, and that is surely one of the reasons for the success of processing.
If you are fed up with all the complication you should try ruby-processing. Links to ruby-processing on my other blog.
Although it doesn't have nice ide like processing there is a textmate bundle for the Apple folks, and I've created a tool (mainly a commando file for JEdit) that lets you launch your applets from the editor. JEdit has syntax highlighting for ruby built in, but you should probably install the RubyPlugin for extra features, and you will need to install the console plugin for the commando feature (JEdit has a superb built in manual so you just need to follow the instructions, while you are at it, learn how to create a macro to launch the commando file). You can even do live editing of your sketch.

By the way you are more than welcome to hack my library if you wish, it is dead easy if you've got netbeans, project kenai is closely integrated with netbeans. You will need to 'create' a processing library to hack processing with netbeans (set the path to the processing core.jar, and whatever other libraries you want to use). Earlier this year there was a bit of hiatus when it appeared as though Oracle was going to throw us amateurs off project kenai, they have since relented. It is possible that they may one day transfer us to, when it gets the kenai functionality (I'm not sure what the status is regarding the creation of new projects).
Update December 2010, Oracle have been true to their word is getting upgraded to be compatible with kenai (and hence netbeans). They expect to transition projects from kenai to next year, so I'm happy to stick with them. The netbeans integration is excellent, and I've never really got on with eclipse. In my experience despite the availability of a template to create processing libraries on eclipse, it is actually far easier to use netbeans....(netbeans does not by default bundle libraries such as core.jar/opengl.jar in your library jar, something which seems to happen for some library developers that use eclipse).

Update 9 September 2012 since version 0.91 my lsystem library is compiled to run with processing-2.0b1+, anyone wanting to use it with earlier version should download version 0.81.

Update 22 November 2012, MouseWheel zoom for ArcBall is failing since NEWT jogl
processing-2.0b7, also you will need to explicitly import the CharacterIterator
import java.text.CharacterIterator;

No comments:

Post a Comment


Blog Archive

About Me

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