큰 문제가 있습니다. 인터넷 검색을 통해 좋은 해결책을 찾지 못했습니다. opencv (2.3)를 통해 파일의 이미지를 읽고 조작했습니다. 그 다음에는 wxwidgets (2.9.3)로 작성된 응용 프로그램에 결과를 표시하려고합니다. 가장 큰 문제는 내 이미지가 회색조이므로 단일 데이터 포인터 만 가지고 있지만 wxwidgets는 RGB 만 사용한다는 것입니다. 작은 예제 :opencv와 wxwidgets간에 이미지 변환
cv::imread(filename,CV_LOAD_IMAGE_GRAYSCALE).convertTo(pictureMatrix,CV_32F,(float)(1/2.0f),0);
// here are some more floating point calculations
cv::Mat output;
pictureMatrix.convertTo(output,CV_8U);
wxImage test(output.rows, output.cols, output.data, true);
wxInitAllImageHandlers();
// saving the picture is just for testing, if it works
test.SaveFile("test.png", wxBITMAP_TYPE_PNG);
이 솔루션도 작동하지만 픽셀 단위 액세스는 필요하지 않습니다. 고마워 – Sonic