Renders fractals using native Java libraries.
Writes the image to the specified file path.
# File lib/fractals/renderers.rb, line 171 def write(file_path='fractal.png') import java.awt.image.BufferedImage import javax.imageio.ImageIO buffered_image = BufferedImage.new(@width, @height, BufferedImage::TYPE_INT_RGB) render do |x, y, color| buffered_image.setRGB(x, y, to_rgb(color)) end ImageIO.write(buffered_image, file_path.split('.').last, java.io.File.new(file_path)) end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.