This should work (if you are sure that type of the image is CV_64F):
void cvHomography::accessElements(const cv::Mat& aCvMat)
{
// assert aCvMat.type() == CV_64F
for( int i = 0; i < aCvMat.rows; i++){
for( int j = 0; j < aCvMat.cols; j++){
cout << aCvMat.at<double>(i,j) << endl;
}
}
}
Also an overloaded operator << for std::ostream works with cv::Mat if you would like just to display image elements.