[prev in list] [next in list] [prev in thread] [next in thread] 

List:       opensuse
Subject:    Re: [oS-en] How to stitch scanned papers?
From:       "Carlos E. R." <robin.listas () telefonica ! net>
Date:       2024-03-23 22:56:18
Message-ID: 2e5b05f7-34d5-4544-8bae-c2c4b8128a4a () telefonica ! net
[Download RAW message or body]

[Attachment #2 (multipart/mixed)]

[Attachment #4 (text/plain)]

On 2024-03-23 14:44, Daniel Bauer wrote:
> 
> 
> Am 23.03.24 um 13:49 schrieb Carlos E. R.:
> > On 2024-03-23 05:10, David T-G wrote:
> > > Carlos, et al --
> > > 
> > > ...and then Carlos E. R. said...
> > > % On 2024-03-23 02:29, David T-G wrote:
> > > % >
> > > % > ...and then Carlos E. R. said...
> > > % > %
> > > % > % How to stitch scanned papers?
> > > % > %
> > > % > % I have a map that is larger than my scanners, so I took 3 
> > > partial scans. I
> > > % > [snip]
> > > % >
> > > % > ImageMagick
> > > %
> > > % It can join photos, yes, edge to edge; but I need to position the 
> > > edges
> > > % manually, one or two centimetres overlap. For this a GUI is needed.
> > > 
> > > Ah.  I thought I recalled it doing edge detection, but I haven't played
> > > with it (like about 90% of the amazing functionality :-)  Are you sure,
> > > or have you checked with the Magick support folks?
> > 
> > I have joined pngs, but I knew the edge was exactly at the limit of 
> > the png, there was no overlapping.
> > 
> > I can not imagine how to do it with ImageMagic with unknown overlap.
> > 
> > 
> > > % >
> > > % > Or I use BimoStitch on my Android phone; it seems pretty good at 
> > > edge
> > > % > matching.
> > > %
> > > % No, I can not work with such a small display to join the scans.
> > > 
> > > You don't have to; you select from your pile all of the pictures that
> > > touch each other and it figures out how they overlap and comes up with
> > > one final [huge] image.  Way better than trying to do so by hand, too.
> > > 
> > > Good luck! :-)
> > 
> > Ok, I may try. Each of the three photos are about 60 Megs, very big 
> > for a tiny procesor.
> 
> If it's only one image I'd simply do it with the Gimp, easy and probably 
> faster than searching for a software, install, try...
> 
> Open one image in the gimp. Enlarge canvas to the full end size or larger.
> Load the other images as layers.
> Show only first layer and an adjoining one. Make the adjoining one 
> semi-transparent and move it around until it fits. Make it nontrasparent 
> again.

I have two problems here.

One, amazingly, the second scan seems to have a different "scale" or 
zoom that the first. This is imposible! But it happens. I superimpose 
horizontal lines, and one centimetre below it, other horizontal lines 
appear parallel, 1 mm apart.

I did the rotation as best as I could, setting the center at the end of 
the horizontal line mentioned above. And features anywhere else do not 
match.

It is amazing. There is distortion. Different distortion in the two 
scans of the same paper.



And then I try to undo transparency, but I am stuck. I'm probably not 
doing transparency right.

<https://www.google.com/search?q=gimp%3A+change+transparency+of+layer&client=firefox-b \
-e&sca_esv=7994f51f647571a9&ei=D07_ZaflBJL3i-gP5cG7qAQ&ved=0ahUKEwjnqNamrouFAxWS-wIHHe \
XgDkUQ4dUDCBA&uact=5&oq=gimp%3A+change+transparency+of+layer&gs_lp=Egxnd3Mtd2l6LXNlcnA \
iImdpbXA6IGNoYW5nZSB0cmFuc3BhcmVuY3kgb2YgbGF5ZXIyBxAAGIAEGBNIuH1Q6hRYpXBwA3gBkAEAmAGnA \
aABoxeqAQQzMS4xuAEDyAEA-AEBmAIjoAK9GMICChAAGEcY1gQYsAPCAgUQABiABMICChAAGIAEGIoFGEPCAgY \
QABgWGB7CAggQABiABBixA8ICCBAAGBYYHhgTwgIKEAAYFhgeGA8YE8ICCBAAGBYYHhgPmAMAiAYBkAYIkgcEMjYuOaAHkZkB&sclient=gws-wiz-serp>


To do this, select the layer and then go to Layer > Transparency > Color 
to Alpha. Within the image editing jargon, “alpha” refers to the “alpha 
channel” of an image, which controls the transparency level of the 
pixels. In the “Color to Alpha” window, choose a color that will be 
considered as transparent.

Working with layers on GIMP - PSL Explore
PSL Explore
https://explore.psl.eu › tools-and-training › tutorials › w...

<https://explore.psl.eu/en/tools-and-training/tutorials/working-layers-gimp>





Found a different method here:

<https://smallbusiness.chron.com/make-semitransparencies-gimp-50854.html>

Press "Ctrl-L" to display the Layers toolbox at the right of the GIMP 
window. You can also click "Windows" at the top and select "Layers" from 
the menu. The layer that contains the image is selected by default.
3.

Click and drag the "Opacity" slider at the top of the Layers toolbox to 
the left to decrease the opacity and increase the transparency.



Trying again this way. I match the two photos at the left tip of the 
"110" line, where I "pencilled" a tiny black dot on both scans for 
easier alignment:

https://paste.opensuse.org/pastes/ecbec3d8650e

You can see how other lines below it do not align.


Now I have to rotate on the right end of the images, where I also drew a 
dot. I will use the first dot as centre of rotation.

[...]

Done rotating. See:

https://paste.opensuse.org/pastes/b09e2b4b1b3c

I am aligning on the tiny black dot at the end of the dash to the right 
of the "35". See how the "36" doesn't align?

Maybe this is a scanner defect in the movement of the head. I used 600 dpi.

Now unzooming and undoing transparency... wow, the result is perfect to 
the naked eye, aside from a different colour (even though I did not 
change scanner settings in xsane).



> Continue with the remaining layers.
> Save as jpg, png or whatever (or as xcf if you want to preserve layers)
> Done.


Ah, supper time. Spanish time, I mean, it is 23:52. You know that, but 
I'm hungry :-D


Saved work as xcf.



Thanks a lot for the method, it is working.




-- 
Cheers / Saludos,

		Carlos E. R.
		(from 15.5 x86_64 at Telcontar)


["OpenPGP_signature.asc" (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic