code below running in VC2010 ,no error but failed,help!
Mat src,dst,dst1; IplImage* pI; int count_black=0; char*window_name="window"; int main() { src=imread("F:\peo.jpg",1); cvtColor(src,dst,CV_BGR2GRAY); threshold(dst,dst1,10,255,0);
Mat dst1;
IplImage* pI = &dst1.operator IplImage();
int count_black=cvCountNonZero (pI);
cout<<" "<<count_black<<endl;
namedWindow("window",CV_WINDOW_AUTOSIZE);
imshow("window",dst1);
waitKey(0);
return 0;
}
============================================================ pick up my mistake please, —a newbie
maybe try to find debug mode and opencv dll, lib are the same?
请问这位老师,我可以在一段程序中同时使用c &c++ 数据结构并且相互转换吗?
yes,you can ,i am an engineer not a teacher
ok sorry,we used to call that for a respect in Shandong…maybe have something to do with Confucius,welcome to Shandong!