tinyapps.org / blog


Batch crop a stack of visually overlaid images like Briss #

Briss allows cropping a stack of visually overlaid PDF pages to remove extraneous space.Briss cropping a stack of visually overlaid pages

I searched high and low for an app that could do the same for images. The only thing I found was PixEdit, which does the job admirably, but at a cost of £1,250. ImageMagick's awesome command line tools were not well-suited to the task, as the images were highly variable.

I posted a plea for help on SuperUser that was promptly downvoted and closed, but not before ForeverWintr kindly pointed me in the right direction: ImageJ. Johannes Schindelin generously filled in the details that I was dark on. Here is the complete walkthru:

  1. Open desired images in ImageJ (To enable multiple selection in the open file dialog box: Edit > Options > Input/Output... > Use JFileChooser to open/save > OK. Alternatively, simply drag and drop multiple files onto ImageJ's toolbar.)
  2. Image > Stacks > Images to Stack > OK
  3. Image > Stacks > Z Project... > OK
  4. Click the rectangle icon in the toolbar
  5. Click and drag over desired area (called a "region of interest" in ImageJ) in the Z projection
  6. Click on the stack created in step 1 > Edit > Selection > Restore Selection
  7. Image > Crop
  8. File > Save As > Image Sequence... > choose desired image format and options > OK

/misc | May 03, 2013


Subscribe or visit the archives