I 프레임을 가지고와 specefic 위치에 사각형을 직사각형을 그리려에 OpenCV의와 RECT 그리기 : 내가 코드를 실행프레임
#include "opencv2/opencv.hpp"
#include <opencv2/core/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include<conio.h>
int main() {
cv::Mat frame = cv::imread("cmd.png");
cvRectangle(
&frame,
cvPoint(5,10),
cvPoint(20,30),
cvScalar(255,255,255)
);
cv::imshow("test " , frame);
while (cv::waitKey() != 23) ;
return 1;
}
wenn 내가 메모리 오류가 발생합니다.
Unhandled exception at 0x000007fefd42caed in OpenCV_capture.exe: Microsoft C++
exception: cv::Exception at memory location 0x0018ead0..
이걸 어떻게해야합니까, 어떻게 내가이
는 당신에게 값이 max.x 확실하고 max.y 프레임의 경계 내에있는? –
네, 확신합니다 최대 프레임에서 한 지점입니다 – Engine
난 그냥 다른 코드와 테스트를했고 잘 작동하지 않습니다 :(, 내가 잘못하고 있는거야? 내 편집 된 질문을 참조하십시오 – Engine