ImageRuby-Devil - Bridge between ImageRuby and Devil image library

Implements a set of features for ImageRuby using Devil image library (

  • Support to load and save formats supported by devil library including jpg, tga, png, etc…

  • New image operations: “alienify”, “blur”, “contrast”, “edge_detect”, “enboss”, “equalize”, “flip”,

    "gamma_correct", "mirror", "negate", "nosify", "rotate", "sharpen", "to_blob" inherited from
    devil library see devil documentation at

NOTE: imageruby-devil requires imageruby-bmp or imageruby-bmp-c gems in order to to work


Gem installation

sudo gem install imageruby-devil


No explicit require is needed, examples

Example 1: PNG

require "imageruby"

include ImageRuby

# create image (red gradient and random green)
image =,255) {|x,y| Color.from_rgb(x,rand(200),0) }

# save image on png format"image.png", :png)

Example 2: Blur and mirror

require "imageruby"

include ImageRuby

# load image generated in the previous example
image = Image.from_file("image.png")

# apply blur effect
image = image.blur(10)

# mirror image
image = image.mirror

# save image on png format"image2.png", :png)


Copyright © 2011 Dario Seminara, released under the GPL License (see LICENSE)