效果
代码
#include <iostream>
#include <string>
#include <sstream>
#include <cmath>
//#include <memory>
using namespace std;
// OpenCV includes
#include "opencv2/core/utility.hpp"
#include "opencv2/imgproc.hpp"
#include "opencv2/highgui.hpp"
using namespace cv;
// OpenCV command line parser functions
// Keys accecpted by command line parser
const char *keys =
{
"{help h usage ? || print this message}"
"{@image1 | /opencv4_vscode/opencv4例程/Chapter_05/data/test.pgm| Image1 to process}"
"{@image2 | /opencv4_vscode/opencv4例程/Chapter_05/data/light.pgm| Image2 to process}"