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

Re: Cropping a large collection of .PNG screenshots

On Tue, 15 Apr 2014, Kevin O'Gorman wrote:

> On Wed, Apr 9, 2014 at 3:03 AM, Kevin O'Gorman <kogorman@gmail.com>
> 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.
> >
> SOLVED.  Thanks to whoever gave me the clue that convert(1) could do
> the cropping.  That and 2 bash scripts do all the work.

Take a look at convert's cousin mogrify.  It does everything convert
does but saves the changes to the original file name. So, use it on
copies if you want to save the originals.  Works great for batch
processing.  I could never get convert to batch process properly.

Use rename to batch rename.

Using those two utilities, you won't need any scripts.


Reply to: