Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
batch divide scanned images
#1
Hi I am new to Gimp but a proficient photoshop user. I have some photo album pages with 4-6 images on each and I want to run an auto crop action, photoshop does not work for this. I have downloaded and installed Batch divide scanned images and diskew plugins. But when I try to run the batch divide the dialogue box comes up I can set the load from and destination folders but nothing happens.

Can anyone help with this and or recommend a way to batch divide a lot of scanned pages?
Thanks
Reply
#2
It would be helpful to see a sample image. But here are 2 things you can try.

1. Put guides where you want the cut to be. Then use (Image > Transform > Guillotine). Each photo is put into a new image.

2. Use G'MIC (Arrays & Tiles > Extract Objects). The photos are auto detected and each photo is put onto its own layer.
Reply
#3
The problem with guillotine is it is not a batch method and often one of the guides will go through one of the images.

The divide scanned images script is old, last update 2010, it was really made for Gimp 2.6 I do think that it will be updated, so stuck with it, as not much in the way of Gimp alternatives.

The deskew plugin is a pita as well. It does work but only for small angles and can be fooled into rotating.

Did you scan the photos yourself? Does the scanner software come with an auto-divide function. No, then back to PS for you.
If you use linux or a Mac, then there is an ImageMagick (IM) bash script that might work. Fiendishly complicated, one of Fred's scripts. You would need to ask on the IM user forum.

   
You should try a typical scan manually before using the batch option.
Some things that help.
A clear border/space between each image.
A nice clean background
Do not rely on the default settings, increase the select threshold and select offsets.

Just as demo, an example and some tips. About 3 minutes duration.


Reply
#4
Thank you both for your replies I have tried to attached an image of one of the many scans but for some reason it won't allow me.

Essentially they are photos of photo album pages that are collection items in a museum. They are the old 70's albums with the lines of glue behind a plastic cover. The glue and the pages have yellowed and are patchy in colour and hue. They must be photographed as a whole I.E. no taking the photos out to get a clean background. I tried running the divide scanned images but as it runs on a colour selection mode I didn't have much luck because of the variance of the background colour. I have tried many different things but  I really need something that can detect straight lines and I'm beginning to think that might be me.

Thanks
Reply
#5
(04-10-2017, 05:33 AM)Michael Wrote: ...snip... I really need something that can detect straight lines and I'm beginning to think that might be me.

In case you ever come back, I think you are correct there.

It is the batch requirement which is mostly the problem.

Once you make your mind up that each image has to be hand processed, it is then a search to find an efficient method.

I suggest using mostly standard Gimp with the exception of ofnuts plugin to straighten an image

see: http://sourceforge.net/projects/gimp-too...s/scripts/ and download ofn-layer-straightener.zip
unzip and put ofn-layer-straightener.py in your Gimp profile C:\Users\your-name\.gimp-2.8\plug-ins

Look at using key shortcuts for as much as possible https://docs.gimp.org/en/gimp-concepts-shortcuts.html
I set up A = python-fu-ofn-straighten S = Remove Alpha D = AutoCrop Image The others already have assigned shortcuts. screenshot: http://i.imgur.com/zcZXzpz.jpg

The procedure might be:
Open the image.
F to get the free select tool - then make your selection.  
ctrl-C copies the selection
shift-ctrl-V pastes as a new image. screenshot http://i.imgur.com/rGF0bVP.jpg

In the new image
B selects the path tool - draw a path in along an edge
A applies the straighten plugin screenshot: http://i.imgur.com/e46dN4b.jpg

to tidy up - not absolutely necessary - if exported to a jpeg you lose transparency anyway.
S removes any transparency from the rotate
D removes the excess layer boundary screenshot: http://i.imgur.com/thneHkv.jpg

Export image as png or jpg or tif - whatever you use.
repeat for next.

Hope you are using a stand for all this (unlike my hand help photo)
Reply


Forum Jump: