How to find the displacement (in X,Y) between two slides?

Tags: #<Tag:0x00007fa30abbd578>


Hi Friends,
I have two image files taken in two cameras (/channel). I want to know about the displacement in X,Y between the two slides after import image sequentially. Can you please tell me how can I do that?


Good day,

I suppose you are capturing stereo pairs.

If you are capturing 3D scenes then there will be no unique displacement, because it depends on the depth too.

Please post a typical image pair in original TIFF- or PNG-format. No JPG-format though, because JPG introduces artifacts! You may also post images as Zip-archives.




Thanks Herbie…it’s a 2D image…due to camera (diff colour) alignment there is a slight displacement in X axis of the two images. I want to translate the value (? i am looking for) with 2nd picture so that they are in equal coordinate.


Hey @nir9
Try this plugin:

Depending on what you use as a template, it will give you the XY displacement of the subsequent images in your stack.



Hello pr4deepr,
Thank you so much for your suggestion.


If you deal with pure translations in x and y I would just compute the Correlation Function of the image pair and look for the maximum position of it.

“Process >> FFT >> FD-Math >> Correlate”




I tend to use StackReg. It is based on a more generic registration plugin written by the same group and there are other parties that have further built upon it to do things like virtual stack registration and 3D registration. But I suppose that doesn’t really matter in your case. The transform parameters are sent to the results table so you can save them for later use.