[問題] opencv findHomography

作者: a462428 (技偉)   2014-12-03 13:46:57
開發平台(Platform): (Ex: VC++, GCC, Linux, ...)
問題:
findHomography 餵入四組點 可以解出homography matrix
不過編譯過了 但執行到以下code箭頭那行時就錯了@@
想請問問題出在哪 感謝!!!!
std::vector<cv::Point2f> queryPoints;
std::vector<cv::Point2f> trainPoints;
queryPoints.push_back(cvPoint(0,0));
queryPoints.push_back(cvPoint(1,0));
queryPoints.push_back(cvPoint(0,1));
queryPoints.push_back(cvPoint(1,1));
trainPoints.push_back(cvPoint(2,2));
trainPoints.push_back(cvPoint(2,3));
trainPoints.push_back(cvPoint(3,2));
trainPoints.push_back(cvPoint(3,3));
std::vector<uchar> inliers(queryPoints.size(),0);
→ Mat homography =
cv::findHomography(queryPoints,trainPoints,CV_RANSAC,3,inliers);
作者: a462428 (技偉)   2014-12-04 16:13:00
已解決

Links booklink

Contact Us: admin [ a t ] ucptt.com