Attempting to use composePanorama multiple times from the stitching module, yields very strange results. First time composePanorama is used, the resulting panorama is perfect, however the next time composePanorama, from the same stitch object is used, the resulting panorama is very strange.
The code that triggers the bug, can be boiled down to:
Stitcher stitcher = Stitcher::createDefault(try_use_gpu);
Mat pano; stitcher.composePanorama(pano);
Mat pano2; stitcher.composePanorama(imgs, pano2);
Attempting to use composePanorama multiple times from the stitching module, yields very strange results. First time composePanorama is used, the resulting panorama is perfect, however the next time composePanorama, from the same stitch object is used, the resulting panorama is very strange.
The code that triggers the bug, can be boiled down to:
this blog post describes and illustrates the problem very well: http://www.scriptscoop.net/t/8d0bf668c48b/opencv-stitcher-class-with-overlapping-stationary-cameras.html