$search
00001 #include "checkerboard_pose_estimation/estimator.h" 00002 00003 namespace checkerboard_pose_estimation { 00004 00005 visual_pose_estimation::PoseEstimator createCheckerboardEstimator(int width, int height, float square_size) 00006 { 00007 cv::Mat_<cv::Vec3f> grid_points(width*height, 1); 00008 int j = 0; 00009 for (int y = 0; y < height; ++y) { 00010 for (int x = 0; x < width; ++x) { 00011 grid_points(j, 0) = cv::Vec3f(x*square_size, y*square_size, 0.0f); 00012 ++j; 00013 } 00014 } 00015 00016 return visual_pose_estimation::PoseEstimator(grid_points); 00017 } 00018 00019 } //namespace checkerboard_pose_estimation