![]() | 1 | initial version |
Try something similar to the following:
//
// This is a deep copy, OpenCV has no CV_64(U|S) types, only CV_32S:
//
cv::Mat mat_32(size, CV_32SC(c));
for (size_t i = 0; i < image_elements; ++i) {
reinterpret_cast<int32_t*>(mat_32.data)[i] = *(static_cast<int64_t*>(tf_data) + i);
}