0
我正在使用Visual Studio 2012上的OpenCV 2.3.1進行圖像拼接項目。 由於某個未知原因,我的程序無法使用!使用openCV查找單應矩陣
#include "opencv2/highgui/highgui.hpp"
#include "opencv/cv.h"
#include <stdio.h>
#include <iostream>
using namespace cv;
using namespace std;
Mat getHomography()
{
vector<Point2f> points1;
vector<Point2f> points2;
points1.push_back(Point2f(10, 100));
points1.push_back(Point2f(100, 10));
points1.push_back(Point2f(200, 20));
points1.push_back(Point2f(80, 30));
points2.push_back(Point2f(220, 20));
points2.push_back(Point2f(10, 220));
points2.push_back(Point2f(90, 120));
points2.push_back(Point2f(100, 20));
Mat H = findHomography(Mat(points1), Mat(points2), 8, 3.0);
return H;
}
int main(){
Mat HH = getHomography();
cout<<HH;
system("pause");
return 0;
}
我的問題: 任何幫助plzzz
然後我就試試吧:d – 2013-03-17 15:27:55
「getHompgraphy」,呵呵,我喜歡它,聽起來不錯:) – berak 2013-03-17 15:31:09
hhhhhhhhhhh 10x:D – 2013-03-17 15:32:24