c++ opencv函数putText用法详解
#include <stdio.h>
#include <iostream>
#include <opencv2/opencv.hpp>
#include <opencv2/core.hpp>
#include <opencv2/imgcodecs.hpp>
#include <opencv2/highgui.hpp>
using namespace cv;
using namespace std;
#define w 800
int main(int argc, char **argv) {
Point pt(20, 500);
Mat img = Mat::zeros( w, w, CV_8UC3);
namedWindow("opencv", WINDOW_FREERATIO);
putText(img, "In the above example:", pt, 1, 4, Scalar(0, 0, 255), 4,
LINE_8);
imshow("111", img);
int k = waitKey(0);
return 0;
}