本文主要是介绍手眼标定(外参),希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
1. 传统使用张正友相机标定,角点检测
//张正友相机标定,角点检测
for(int i=1;i<=images_number;i++){Mat image=imread(images_path+to_string(i)+String("/color.jpg"));Mat output=image.clone();image_size.width=image.cols;image_size.height=image.rows;if(0==findChessboardCorners(image,board_size,image_points_buf)){cout<<i<<" can not find chessboard"<<endl;exit(1);}else{Mat view_gray;cvtColor(image,view_gray,COLOR_BGR2GRAY);find4QuadCornerSubpix(view_gray,image_points_buf,Size(5,5));image_points_seq.push_back(image_points_buf);drawChessboardCorners(output,board_size,image_points_buf,false);}}Size square_size = Size(25, 25); vector<vector<Point3f>> object_points;Mat cameraMatrix = Mat(3, 3, CV_64FC1);vector<int> point_count
这篇关于手眼标定(外参)的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!