opencv学习(二) 作者: BeefLiu 时间: 2026-04-09 分类: 编程记录,C++ 评论 #include <opencv2/opencv.hpp> #include <opencv2/imgproc.hpp> #include <opencv2/highgui.hpp> #include <iostream> #in More...
std::map学习 作者: BeefLiu 时间: 2026-04-08 分类: 编程记录,C++ 评论 1、声明 #include <map> #include <string> int main() { // 声明一个键为int类型,值为std::string类型的std::map std::map<int,std::string More...
opencv学习(一) 作者: BeefLiu 时间: 2026-04-07 分类: 编程记录,C++ 评论 图像创建 CV_8UC1 : 8位无符号单通道(灰度图) CV_8UC3 : 8位无符号三通道(彩色图,BGR顺序) CV_32FC1 : 32位浮点单通道(用于深度图、特征图等) CV_8UC4 : More...
nlohmann::json使用 作者: BeefLiu 时间: 2026-04-03 分类: 编程记录,C++ 评论 #include <nlohmann/json.hpp> #include <iostream> #include <string> struct Person { std::string name; std::string More...
遍历数组 作者: BeefLiu 时间: 2026-03-08 分类: 编程记录,C++ 评论 1、C-Style for(size_t i =0; i < players.size(); i++) { if(players[i].hp == 0.f) players[i].hp = 100.f; } 2、C++11 for(auto& playe More...