Skip to content
Snippets Groups Projects
Commit 973f1d99 authored by Angel Santamaria-Navarro's avatar Angel Santamaria-Navarro
Browse files

fix for test_roi_orb.cpp

parent 0f30ec85
No related branches found
No related tags found
1 merge request!128Updates for OpenCV 3 api (keeping OpenCV 2 back compatibility)
...@@ -131,8 +131,8 @@ IF(OpenCV_FOUND) ...@@ -131,8 +131,8 @@ IF(OpenCV_FOUND)
# TARGET_LINK_LIBRARIES(test_tracker_ORB ${PROJECT_NAME}) # TARGET_LINK_LIBRARIES(test_tracker_ORB ${PROJECT_NAME})
# ORB tracker test # ORB tracker test
# ADD_EXECUTABLE(test_ROI_ORB test_ROI_ORB.cpp) ADD_EXECUTABLE(test_ROI_ORB test_ROI_ORB.cpp)
# TARGET_LINK_LIBRARIES(test_ROI_ORB ${PROJECT_NAME}) TARGET_LINK_LIBRARIES(test_ROI_ORB ${PROJECT_NAME})
ENDIF(OpenCV_FOUND) ENDIF(OpenCV_FOUND)
IF(Ceres_FOUND) IF(Ceres_FOUND)
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
//opencv includes //opencv includes
#include "opencv2/features2d/features2d.hpp" #include "opencv2/features2d/features2d.hpp"
#include <opencv2/highgui/highgui.hpp> #include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/core/core.hpp> #include <opencv2/core/core.hpp>
int main(int argc, char** argv) int main(int argc, char** argv)
...@@ -34,7 +35,7 @@ int main(int argc, char** argv) ...@@ -34,7 +35,7 @@ int main(int argc, char** argv)
unsigned int img_height = image.rows; unsigned int img_height = image.rows;
std::cout << "Image size: " << img_width << "x" << img_height << std::endl; std::cout << "Image size: " << img_width << "x" << img_height << std::endl;
cv::Feature2D* detector_descriptor_ptr_; cv::Ptr<cv::FeatureDetector> detector_descriptor_ptr_;
unsigned int nfeatures = 20; unsigned int nfeatures = 20;
float scaleFactor = 1.2; float scaleFactor = 1.2;
...@@ -45,7 +46,7 @@ int main(int argc, char** argv) ...@@ -45,7 +46,7 @@ int main(int argc, char** argv)
unsigned int scoreType = 0; //#enum { kBytes = 32, HARRIS_SCORE=0, FAST_SCORE=1 }; unsigned int scoreType = 0; //#enum { kBytes = 32, HARRIS_SCORE=0, FAST_SCORE=1 };
unsigned int patchSize = 31; unsigned int patchSize = 31;
detector_descriptor_ptr_ = new cv::ORB(nfeatures, // detector_descriptor_ptr_ = cv::ORB::create(nfeatures, //
scaleFactor, // scaleFactor, //
nlevels, // nlevels, //
edgeThreshold, // edgeThreshold, //
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment