Forum: Ruby on Rails ImageScience, Mini-Magick and RMagick

C812af97480d1ed752603936d73f7744?d=identicon&s=25 Miles (Guest)
on 2007-05-23 17:42
(Received via mailing list)
I'm going to be generating thumbnails from user uploaded images. I'm
looking around at the libraries available to do this sort of thing and
there are three that look promising.

  ImageScience -- http://seattlerb.rubyforge.org/ImageScience.html
  Mini-Magick -- http://rubyforge.org/projects/mini-magick/
  RMagick -- http://rmagick.rubyforge.org/

It looks like a lot of people are seeing problems with memory usage if
they are invoking RMagick often. Mini-Magick looks like it's wrapping
the command line and invoking ImageMagick which should be pretty fast.
ImageScience is using FreeImage and people say it's pretty fast and
isn't too hard on the server.

All things being equal, what have you had success with? Has anyone run
into any real gotcha's with any of these libraries?

Thanks,
-- Miles
6925c1e7ea432d878f1832d857d6dfe8?d=identicon&s=25 Richard Luther (Guest)
on 2007-05-23 18:39
(Received via mailing list)
If all you want to do is resize photos then use ImageScience.
 - Richard
821395fe70906c8290df7f18ac4ac6cf?d=identicon&s=25 Rick Olson (Guest)
on 2007-05-23 18:52
(Received via mailing list)
On 5/23/07, Miles <twitch04@gmail.com> wrote:
>
> I'm going to be generating thumbnails from user uploaded images. I'm
> looking around at the libraries available to do this sort of thing and
> there are three that look promising.
>
>   ImageScience -- http://seattlerb.rubyforge.org/ImageScience.html
>   Mini-Magick -- http://rubyforge.org/projects/mini-magick/
>   RMagick -- http://rmagick.rubyforge.org/

rmagick - Loves memory.  I haven't seen it leak necessarily, just jump
up in memory until the garbage collector runs.

minimagick - I've seen reports with a race condition with temp files:
http://ar-code.lighthouseapp.com/projects/35/ticke...
 .  Basically, if garbage collection runs during a large operation, it
can delete some of the tempfiles while you're still using them.  This
should just require a quick update to the gem though, so it's not a
huge deal.

imagescience - works great if all you need is basic cropping and
resizing.  I implemented the imagemagick geometry strings in my
attachment_fu.  I've noticed it's not as flexible as imagemagick
though, bombing on certain gifs or jpegs only.

--
Rick Olson
http://lighthouseapp.com
http://weblog.techno-weenie.net
http://mephistoblog.com
6925c1e7ea432d878f1832d857d6dfe8?d=identicon&s=25 Richard Luther (Guest)
on 2007-05-23 18:57
(Received via mailing list)
If all you want to do is resize photos then use ImageScience.
 - Richard
2f9a03aa0fcfe945229cb6126eda2cb2?d=identicon&s=25 Philip Hallstrom (Guest)
on 2007-05-23 19:04
(Received via mailing list)
> the command line and invoking ImageMagick which should be pretty fast.
> ImageScience is using FreeImage and people say it's pretty fast and
> isn't too hard on the server.
>
> All things being equal, what have you had success with? Has anyone run
> into any real gotcha's with any of these libraries?

I haven't used ImageScience, but my memory is that if you want to do
things like watermark/drop shadows (ala flex image plugin) you can't.
But
if you don't then it's the WayToGo(tm)...

-philip
C812af97480d1ed752603936d73f7744?d=identicon&s=25 Miles (Guest)
on 2007-05-23 20:20
(Received via mailing list)
Thank you all for the responses. :)

I have been doing some more research myself and I'm going to try
ImageScience. All I need to do is resize the image and based on what
I'm hearing, it's the best solution for this so far. I'll post again
if I run into any interesting problems.

Thanks again,
-- Miles
C812af97480d1ed752603936d73f7744?d=identicon&s=25 Miles (Guest)
on 2007-05-23 20:20
(Received via mailing list)
Thank you all for the responses. :)

I have been doing some more research myself and I'm going to try
ImageScience. All I need to do is resize the image and based on what
I'm hearing, it's the best solution for this so far. I'll post again
if I run into any interesting problems.

Thanks again,
-- Miles
C812af97480d1ed752603936d73f7744?d=identicon&s=25 Miles (Guest)
on 2007-05-23 20:20
(Received via mailing list)
Thank you all for the responses. :)

I have been doing some more research myself and I'm going to try
ImageScience. All I need to do is resize the image and based on what
I'm hearing, it's the best solution for this so far. I'll post again
if I run into any interesting problems.

Thanks again,
-- Miles
C812af97480d1ed752603936d73f7744?d=identicon&s=25 Miles (Guest)
on 2007-05-23 20:21
(Received via mailing list)
Thank you all for the responses. :)

I have been doing some more research myself and I'm going to try
ImageScience. All I need to do is resize the image and based on what
I'm hearing, it's the best solution for this so far. I'll post again
if I run into any interesting problems.

Thanks again,
-- Miles
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.