Saari Development

Ali Rizvi's Technical Blog as a Professional Software Development Engineer

Ruby: Rotating Image Files Description

leave a comment »

I was looking for a tool that would do the same thing that flick does on upload, that is rotate the files appropriately based on information embedded in the image files.

Finally I decided to just do it!

Since all my photos are on my windows machine that was my platform of choice.

Thankfully RMagick package for windows comes with ImageMagick installer. The only thing tricky was to install the gem file from the locally downloaded gem file.

While searching for EXIF library for Ruby I found quite a few on RubyForge but finally exifr seemed most functional/friendly.

Entry below shows the code I ended up with.

Instructions for outputting the html for the code in gVim on windows:

* :colorscheme delek
* Syntax -> Convert to HTML
* remove html, head and body tags
* paste to blogspot


Written by imsaar

June 25, 2007 at 12:48 pm

Posted in ruby

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: