Quantcast
Channel: OpenCV Q&A Forum - Latest question feed
Viewing all articles
Browse latest Browse all 19555

CvMat zero initialization confusion with cv::Mat

$
0
0
I was reading a code which was like this : CvMat * MyMat[10]; for(int i = 0; i<10; i++) { MyMat[i] = 0; } what does this do ? Does it initialize the MyMat to 0. And if I want to do the same in `cv::Mat` , can I do cv::Mat MyMat[10]; for(int i = 0; i<10; i++) { MyMat[i].setTo(Scalar::all(0)); }

Viewing all articles
Browse latest Browse all 19555

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>