Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

OpenCV C++ converting Vector to Mat

Hi I have 2 vectors and i want to perform cross and dot product operations on them.

double va[] = {1.0, 2.0, 3.0};
double vb[] = {0.0, 0.0, 1.0};
double vc[3];

cv::Mat VA(1, 3, CV_32FC1, va);
cv::Mat VB(1, 3, CV_32FC1, vb);

std::cout << VA << std::endl;

When i print them my both va and VA are not the same !!!!