RMVL  1.1.1
RoboMaster Vision Library
samples/tutorial_code/dataio/sample_read_corners.cpp

角点数据读取例程

#include <iostream>
#include <rmvl/rmvl.hpp>
using namespace std;
using namespace cv;
int main()
{
for (uint32_t n = 0; n < 5; ++n)
{
vector<vector<Point2f>> corners;
// read data
if (!readCorners("ts.yml", n, corners))
continue;
// print the data
for (size_t i = 0; i < corners.size(); ++i)
for (size_t j = 0; j < corners[i].size(); ++i)
cout << i << "." << j << " = " << corners[i][j] << endl;
}
return 0;
}
bool readCorners(const std::string &path, uint32_t idx, std::vector< std::vector< cv::Point2f >> &corners)
从指定 YAML 文件中读取角点数据
Definition: uty_math.hpp:65