Installing a modern jpegtran binary for Gallery2
I probably should add a tutorial content type already.
Okay, I was having problems with a new gallery2 install not rotating resized images correctly. I didn't have the correct software installed on my system, and gallery2 really isn't supported on Ubuntu systems later than, say, 2007, so, this install is a less than desirable configuration in many ways. I really can't stand Gallery3, and dislike the style of focusing on a single photo, leaving a photo stream as a second class citizen, of other gallery packages I tested, so back to the somewhat bloated world of gallery2.
Which wasn't quite working. No rotating.
Blah blah blah. The fix:
Install the jpegtrans
binary:
$ sudo apt-get install libjpeg-progs
It'll likely be version 8d.
In the gallery install, In the file modules/jpegtran/classes/JpegtranToolkitHelper.class
, around line 141, change this line:
if (preg_match("/Independent JPEG Group's JPEGTRAN/", $line)) {
to this line:
if (preg_match("/Independent JPEG Group's/", $line)) {
Yay! Code is now updated to work with the current jpegtran
binary! Configure it in gallery2 by going to Site Admin > Plugins at main.php?g2_view=core.SiteAdmin&g2_subView=core.AdminPlugins
in your gallery2 install.
Activate the module by adding the jpegtran binary path, then enable the module.
Clear the image cache by going to lib/support/index.php
in the gallery2 install, and clearing the thumbnail / resized image cache. Bleh.
I think this solved my problem. I'll find out at some other point soon, I guess. I also tried this solution, which involves exiv2, so I'm uncertain which did what.
Comments
1) Go to my gallery data
Add new comment