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

List:       opensuse
Subject:    Re: [oS-en] How to stitch scanned papers?
From:       Daniel Bauer <linux () daniel-bauer ! com>
Date:       2024-03-24 8:44:22
Message-ID: e1dc89be-e501-47a9-ae20-145a1e1ff865 () daniel-bauer ! com
[Download RAW message or body]



Am 23.03.24 um 23:56 schrieb Carlos E. R.:
> On 2024-03-23 14:44, Daniel Bauer wrote:
...
>>>> % > % How to stitch scanned papers?
>>>> % > % I have a map that is larger than my scanners, so I took 3 
>>>> partial scans. I
>>>> % > [snip]

>> 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.

...

> To do this, select the layer and then go to Layer > Transparency > Color 
> to Alpha. 
...

Ah, that's something else. Sorry, for me the basic Gimp functions are so 
very natural that I didn't explain any further...

> 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.

Yes, that's it in this case.

> Trying again this way. 

...
> 
> 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.

Can be that the scanner isn't absolutely accurate, but before buying a 
new scanner ( :-P ) try:

leave the center of rotation in the middle of the layer, do not move 
that center to any other position. Then rotate.

Not sure if this helps, but could be.

(You'll have to start with a new image, not use the already rotated layers)

> 
> 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).

The scanner probably tries to do a correction finding out which are the 
correct colors/brightness/contrast, so if the color mix on the different 
parts of the map is a bit different (e.g. more red lines), it will 
result in different correction.

Maybe you can turn off "automatic exposure/color correction", or save 
the correction from the first scan and apply it to the others, but I 
don't know.

You can try to adjust the colors in Gimp, but then I'm sure your next 
post will be in two days :-) There are so many different ways to do 
that... (Save an xcf with the moved/rotated layers and then work with a 
copy so you can always go back to the original, or duplicate the layers 
and work with the duplicates)

It also depends on how important is a perfect result. In most cases 
"good enough" is good enough...
-- 
Daniel Bauer photographer Basel Málaga
Twitter: @Marsfotografo (often explicit nudes)
https://www.patreon.com/danielbauer
https://www.daniel-bauer.com (nudes)
[prev in list] [next in list] [prev in thread] [next in thread] 

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