ljcrop - Tcl/Tk gui for lossless jpeg cropping

Stuff that has yet to be sorted into a category.
Post Reply
Message
Author
disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

ljcrop - Tcl/Tk gui for lossless jpeg cropping

#1 Post by disciple »

I found this cool tcl script at http://astro.ucla.edu/%7Emperrin/software/ljcrop/ljcrop
It requires a version of jpegtran with crop support, so I packaged the two up together. Just extract to /usr/bin or /usr/local/bin or somewhere. It should work in Puppy except Dingo, which I think doesn't have Tcl/Tk.

It would be a good project if anyone wanted to improve it. I think the major drawback is that when you draw your selection it doesn't snap to the 16x16 pixel grid that it has to crop at for lossless cropping.
There is a similar perl/Tk script I've also attached that might have some good features - e.g. the selection scales when you zoom in or out, so the same part of the picture is selected, rather than the same part of the screen.
What Linux really needs is a gui for doing constrained aspect ratio cropping, so you can specify an aspect ratio, and the selection will be locked to that shape. I wonder if it would be possible to extend it to do that?

It would be very easy to integrate it with something like jhead, to remove embedded thumbnails (or regenerate them with mogrify) after cropping, so you don't have thumbnails that don't match the photos.
Attachments
jpegcrop.pl.gz
For interest
(3.04 KiB) Downloaded 469 times
ljcrop.tar.gz
(43.66 KiB) Downloaded 477 times
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

cropgui - lossless jpeg cropping like jpegcrops

#2 Post by disciple »

There's now a pyGTK / pyTK program like this at http://git.unpythonic.net/view/cropgui.git
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#3 Post by disciple »

Of course, rphoto can also do this, and it is the only alternative to jpegcrops (run in wine) for constrained aspect ratio cropping. It crashes a bit though :(
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

Post Reply