int main()
{
try
{
bool try_use_gpu = false;
vector<Mat>imgs;
Mat pano;
imgs.push_back(imread("newyork1.jpg"));
imgs.push_back(imread("newyork2.jpg"));
//Stitcher::Mode mode = Stitcher::PANORAMA;
//Ptr<Stitcher> stitcher = Stitcher::create(mode, try_use_gpu);
Stitcher stitcher = Stitcher::createDefault(try_use_gpu);
Stitcher::Status status = stitcher.stitch(imgs, pano);
if (status != Stitcher::OK)
cout << "Panorama unsuccessful" << endl;
else {
imshow("panorama", pano);
waitKey(0);
imwrite("panoramaimg.jpg", pano);
return 0;
}
i think there might be a problem with my image , any help pls