Is there software for stitching a large number of small digital images without rotating or stretching them?

I have a very large number of small images (360x192), taken sequentially as screenshots from a DOS 2D computer game. They have a decent overlap, and I would like to sew them together into one large composite. By nature, each subsequent image will correspond to a pixel for the next or previous. Thus, no rotation, stretching or distortion is required or not required.

There are many software for stitching panoramic photos. But, unfortunately, they all apply some distortion, even if they are explicitly instructed not to.

Is there any software that will try to do perfect pixel stitching?

0
source share
2 answers

Mathematica 8 has functions for this:

ImageAlign[img1, img2, "Transformation" -> "Translation"] FindGeometricTransform[img1, img2, "Transformation" -> "Translation"] 

By setting the Transformation option to Translation, you guarantee that the result conversion will not have any β€œdistortions” that you mention.

Additional examples in the documentation:

http://reference.wolfram.com/mathematica/ref/ImageAlign.html

http://reference.wolfram.com/mathematica/ref/FindGeometricTransform.html

I know that you can associate Mathematica with perl, but I have not tried it yet.

EDIT: Using the link you submitted, I came up with the following. The only problem is that you need to specify the size of the output in advance --- NB I tried only the first 10 images.

 directory = "~/Downloads/done/"; files = FileNames["*.bmp", directory]; canvas = ImagePad[Import[files[[1]]], {{100, 100}, {500, 100}}, Transparent]; Do[ i = Import[f]; fun = FindGeometricTransform[canvas, i, "Transformation" -> "Translation"]; If[ Head@fun === FindGeometricTransform, Continue[] ]; canvas = ImageCompose[ canvas, ImagePerspectiveTransformation[i, fun[[2]], DataRange -> Full, PlotRange -> Transpose[{{0, 0}, ImageDimensions[canvas]}], Padding -> Transparent], {1, 1, -1}], {f, files[[;; 10]]}] 

enter image description here

+2
source

One of the final libraries for creating panoramas is the Panoramic Tools . You can either forward or call with Perl.

Please note that your specification does not meet the requirements. If your images are not 100% straightforward (i.e. taken 1: 1 using an image with the same size as the image), you MUST compensate for lens distortion. To accurately stitch photos together (pixel by pixel), the image needs distortion compensation.

+1
source

All Articles