How does one access (i,j) th location and k th channels of a 2D cv::Mat. Here k is not constant at runtime. I was thinking cv::Mat at<T>(i,j,k) will do it. But it does not. So how do I do this?
double x=Data.at<double>(i,j*Data.channels()+k);
How does one access (i,j) th location and k th channels of a 2D cv::Mat. Here k is not constant at runtime. I was thinking cv::Mat at<T>(i,j,k) will do it. But it does not. So how do I do this?
double x=Data.at<double>(i,j*Data.channels()+k);