(1)将vector
vector2.1 文档数据读取vd{ { 1.1, 2.2 }, { 3.3, 4.4 }, {5.5, 6.6} }; vector v(vd.begin(), vd.end());
(1)从txt中读取坐标数据(每一行为 x, y 格式,如下图所示),并赋值给vector
ifstream infile;
infile.open("distortPoints/"+names[i]+"_points.txt");
if (!infile.is_open()) {
std::cout << "read txt file is failed!" << std::endl;
return false;
}
vector Points;
float x, y;
char delim;
while (infile >> x >> delim>> y) {
Points.emplace_back(Point2f(x, y));
}



