Erik
2007-Aug-29 14:48 UTC
libjpeg collision when using RMagick (ImageMagick) and ImageScience (FreeImage)?
I have a Rails app that uses BackgroundRB to process images. I''ve been using a class that uses RMagick for quite some time without any issues at all. I recently added a new class that processes images using image_science instead of RMagick. After adding this new class and the image_science gem RMagick throws the following error: JPEG parameter struct mismatch: library thinks size is 428, caller expects 464 `'' - (Magick::ImageMagickError) on this method: magick_image = Magick::Image.from_blob(image_blob) When I uninstall image_science the class that uses RMagick ceases to throw the above error. Here are my thoughts: image_science uses FreeImage, which ships with its own version of libjpeg. When Rails boots up it loads the image_science gem first, which loads FreeImage, which loads its own libjpeg. When RMagick gets loaded, is it possible that RMagick/ ImageMagick will not use the libjpeg that is in /usr/lib and instead use the one that was loaded by image_science/FreeImage? This is of FC4 (i686 athlon i386 GNU/Linux) with Ruby 1.8.4 and the most recent versions of ImageMagick and RMagick. Any help would be greatly appreciated! Erik --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---