Stitcher module for non-linear stitching
Hi all, this is a very particular question. I have some picture taken by a flying drone, and I need to stitch them together. Could the built in stitcher module stitch non linear images? To better explain myself, i made these "images"
the black line is the drone trajectory (so are the frames) and the white part of the images should remain black because I haven't pictures for that part.
Is this possible? What are good parameter for the stitcher to make this happen?
EDIT Suppose my drone fly above this area
And the path that my drone do is this
but it does the path in 3 times, so I have these
can the built in stitcher module produce this mosaic?
*EDIT 2 * Finally the built in stitching module worked! But I obtain image with this kind of error:
How can I fix that?
Can't you fabricate a desired example with paint or photoshop and add that instead? Your explanation is not very clear for now.
Sure, later I'll edit the post with the information you required ;)
I'm not a specialist of stitching but my results with two images are here or here With image on left I haven't got any success
I'm using opencv 3 with the default stitcher and it doesn't work!
Why do you mean by it doesn't work? with sample/cpp/stitching_detailed.cpp it works with two images. With left image I have result but it's not good at all!
A problem is that both images are compressed only in y direction.I think that we are not verify a Pure 3D rotation. In your case may be you can match some features and after ony use a translation and no rotation
Your drone works like a scanner so you cannot use stitching algorithm. You need intrensic camera parameter, coorect your image logk for matching and just translate and zoom
@LBerger I'm not using the stitching_detailed but the Stitcher class! How do I get the intrinsic camera parameters? By the way, when I create the mini-mosaics, it works pretty well, but it's my code, not the built in stitcher because I'm creating the mosaic frame by frame!
What you should do is manually define regions of interest that you want to map and then it should work. define the end of streak one as region one. The beginnen of streak 2 as region 2. Then apply feature matching on both regions and then calculate a transformation matrix. Apply that and merge. You will need some elements from stiching pipeline.
The problem is that in my case it should be an automatic process, so I can't define manually the regions :S
You can define them automatically. For example the last 5 seconds that you flew in one direction before switching to a second direction. No manual input needed at all.
Mmmm it sounds interesting! For getting automatically the direction, can I do a control on the mini-mosaic size? To better explain: if it's higher than the previus frame i'm going up/down and if it's larger I'm going left/right. It sounds correct to you? There are more precise method? The task hasn't to be in real time!