3
我用JavaCV來拼接圖像,但在控制檯輸出以下:拼接一些圖像用JavaCV
Finding features...
Features in image #1: 888
Features in image #2: 1483
Finding features, time: 0.523706 sec
Pairwise matching
1->2 matches: 456
1->2 & 2->1 matches: 485
.Pairwise matching, time: 0.14468 sec
Removed some images, because can't match them or there are too similar images: (2).
Try to decrease --match_conf value and/or check if you're stitching duplicates.
Need more images
這是我的代碼:
public static void main(String[] args) {
Stitcher stitcher = Stitcher.createDefault(true);
MatVector images2 = new MatVector(2);
images2.put(1, cvLoadImage("sample1.png"));
images2.put(0, cvLoadImage("sample2.png"));
IplImage result = new IplImage();
int status = stitcher.stitch(images2, images2);
result = cvLoadImage("sample1.png");
final CanvasFrame canvas = new CanvasFrame("My Image", 1);
canvas.setDefaultCloseOperation(javax.swing.JFrame.EXIT_ON_CLOSE);
// Show image on window.
canvas.showImage(result);
}
他們可以的LoadImage但沒有拼接圖像,爲什麼?
我在http://ramsrigoutham.com/2012/11/22/panorama-image-stitching-in-opencv/這裏更改了圖片。它正在工作,但他們產生了其他問題。 像這樣: 波修正... 波修正,時間:4.82209e-005秒 翹曲圖像(輔助)... OpenCV的錯誤:斷言失敗(K == MAT)在未知功能 是什麼問題在哪?謝謝你的幫助。 – user2001167