diff --git a/PointCloudRegistration/main.cpp b/PointCloudRegistration/main.cpp index d7ba933..1cf8adc 100644 --- a/PointCloudRegistration/main.cpp +++ b/PointCloudRegistration/main.cpp @@ -39,6 +39,15 @@ const double SAC_MAX_CORRESPONDENCE_DIST = 1000; // 2000 const double SAC_MIN_CORRESPONDENCE_DIST = 3; int main(int argc, char *argv[]){ + string filename1, filename2; + if (argc == 3){ + filename1 = argv[1]; + filename2 = argv[2]; + } else{ + filename1 = "pcd/a3.pcd"; + filename2 = "pcd/a4.pcd"; + } + time_t starttime = time(NULL); cout << "Loading clouds...\n"; cout.flush(); @@ -47,8 +56,8 @@ int main(int argc, char *argv[]){ pcl::PointCloud::Ptr cloud1(new pcl::PointCloud); pcl::PointCloud::Ptr cloud2(new pcl::PointCloud); - pcl::io::loadPCDFile("pcd/a3.pcd", *cloud1); - pcl::io::loadPCDFile("pcd/a4.pcd", *cloud2); + pcl::io::loadPCDFile(filename1, *cloud1); + pcl::io::loadPCDFile(filename2, *cloud2); // downsample the clouds pcl::PointCloud::Ptr cloud1ds(new pcl::PointCloud); diff --git a/Readme.md b/Readme.md index 9e2a574..0d6b07c 100644 --- a/Readme.md +++ b/Readme.md @@ -1,4 +1,11 @@ SCA-IA === -SCA-IA point cloud registration -Developed By VS2013update5 and PCL(Point Cloud Library) \ No newline at end of file +SCA-IA point cloud registration and ICP to solve RT matrix +Developed By VS2013update5 and PCL(Point Cloud Library) + +use program in cmd: + +``` +PointCloudRegistration.exe source.pcd target.pcd +``` +