how to merge two similar image's differences into one image in terminal?

0

I don't know if this has been done before, can we merge two pictures in terminal. when I say merge I mean merge their differences and keep the common parts and NOT merge them into a bigger size picture and keep both.

For example imagine two photos of a highway from same angle, with one car moving, I want the merge of those two pictures to produce one highway picture with two cars in it.

I know how to do this in Gimp but I want a terminal based approach.

P.S: Lets assume the camera is at same location and angle. and we dont care about the quality of the merge, as long as it merges it somehow...

Medya

Posted 2016-01-20T17:24:17.807

Reputation: 113

Gimp has command-line batch abilities. – Ƭᴇcʜιᴇ007 – 2016-01-20T17:38:45.593

There seem to me to be too many variables to be handled by an automated process: camera position, focus, light intensity, shadow angles, distinguishing foreground from background (otherwise you could equally finish up with an empty road), overlaps (cars in similar positions on road), etc. All of these will need manual resolution, so you may as well use a GUI program to do so. – AFH – 2016-01-20T17:49:51.493

lets assume the camera angle is same across all. – Medya – 2016-01-20T17:59:25.033

I was assuming that. Even with a tripod, you can get a few pixels shift from one image to another; movement of the sun will cause some shift in the shadows; changing cloud cover will modify the lighting and shadows (intensity, contrast and hue); not to mention grasses or leaves moving in the wind. To separate foreground from background you will need a third image of an empty road: it's obvious when you look at two photos, but I can't imagine how a pixel comparison would make that decision. – AFH – 2016-01-20T19:21:21.620

I don't care how the merged photo is gonna look like, as long as there is an automated way of doing it... for example look a tthis picture http://salavon.com/work/City/ it is like an artistic Average of many photos in which the sky is the same but the buildings are not and they are overlayed.

– Medya – 2016-01-20T20:16:04.447

No answers