Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何将数组中的元素写入 OpenCV Visual Studio 中的文本文件?
std::ofstream f("C:/file_to_write_to.txt"); // writing element my_matrix[10, 10] to file. assuming it's a float. f << my_matrix.at<float>(10, 10) << std::endl; f.close();