[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Cropping a large collection of .PNG screenshots

On 04/09/2014 12:03 PM, Kevin O'Gorman wrote:
I have a few hundred screen shots I want to put on a web page, but
they are all full-screen and I want to crop to the real contents.
This is an identical region in all cases.  So I want to script it.

So, 2 questions:
A) What's the best tool for the job?  Gimp, irfanview, or something else?
B) Is there a script already in existence where I can just change the
crop rectangle?  I really don't want to learn a new language for a
one-time job.

If you have a powerful machine with many cores you can speedup the batch process by using xargs or parallel with -Px argument.
The following one liner will utilize 8 cores for example:
assuming you have your files in one dir

 find . -name "*.png" | parallel -P8 convert -quality 95 {} -geometry 1280 /tmp/{.}.jpg
Adjust for the crop instead of resize ..


Reply to: