Ruby Fractal Library 1.2.0
Posted by Ryan Baxter Thu, 27 Aug 2009 02:36:00 GMT
I’ve finally released version 1.2.0 of the Ruby Fractal Library. It’s still just as small and easy to use, but with a few new twists. I’ve removed most of the duplicate code, added Procs where appropriate, and made the syntax more consistent. The result is much more readable and should be easier to maintain.
- The source code has been split into multiple files. One for each module.
- Each of the fractals has been distilled to a single block passed to the Fractal base class’ constructor. This makes it easy to construct new orbits fractals by either inheriting from Fractal or instantiating it directly.
- Classes have been added for the Burning Ship and Newton fractals.
- A ‘Winter’ theme has been added.
- Users can now choose which dependancy nightmare they’d prefer. PNG, RMagick and JRuby each have their own renderer. PNGRenderer is the default, but is easy to override with the renderer= method.
- bailout and max_iterations are no longer constructor parameters. This is the biggest breaking change.
- Unit tests have been added for each fractal.
- Several rake tasks have been added to make installation and gem creation easier.
- RDoc documentation is now available.
A project for this library has been created at RubyForge, but the source code can still be found at the same old place. I’m considering a move to github, but I’ll make an announcement if that happens. If you decide to download the Ruby Fractal Library, be sure to check out examples.rb in the project’s source. You should also take a look at the README file and documentation before getting started. Make some fractals and enjoy! Bugs can be filed at the RubyForge tracker.
- Meta 2 comments, permalink, rss, atom
Subversion: Merging a Branch into Trunk
Posted by Ryan Baxter Wed, 26 Aug 2009 01:21:00 GMT
I can never remember how to merge a Subversion branch into trunk. So for future reference, here is how it’s done.
First, get a working copy of the head revision of trunk.
svn checkout svn://svnserver/project/trunk projectNext, merge the branch with your working copy.
svn merge svn://svnserver/project/trunk svn://svnserver/project/branches/branch projectFinally, commit the results of the merge.
cd project
svn commit -m "Merging branch X.X.X into trunk."You can also specify a revision number in your merge.
svn merge svn://svnserver/project/trunk@223 svn://svnserver/project/branches/branch@223 projectThat’s it.
- Posted in Code Snippets
- Meta 3 comments, permalink, rss, atom
Installing RMagick on Ubuntu*
Posted by Ryan Baxter Thu, 20 Aug 2009 17:00:00 GMT
Because I always forget how…
sudo apt-get install libmagickwand-dev
sudo gem install rmagickand you reference it in code like so:
# Don't forget the capital "RM"!
require 'RMagick'
include RMagick*I’ve only done this using Ubuntu 9.04. Your mileage may vary.
- Posted in Code Snippets
- Meta no comments, permalink, rss, atom
Older posts: 1 2

