Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Problem when using dot product with Xcode

Dear friends,

Please give me some idea how to solve this problem. image description

click to hide/show revision 2
None

updated 2018-07-26 09:38:47 -0600

berak gravatar image

Problem when using dot product with Xcode

Dear friends,

Please give me some idea how to solve this problem. image description problem.

Problem when using dot product with Xcode

Dear friends,

Please give me some idea how to solve this problem.problem. I wrote a very simple program that executes dot product between two points, A = (1,2), B = (2,5). However, I could not implement it because of the error No viable overload '=' (compiler explains: "candidate function not viable: no known function from 'int' to 'const cv::Point_<int>' for 1st argument"). I am using Open CV 3.4.2 and Xcode 9.2. Below is my implementation.

#include<iostream>
#include<opencv2/opencv.hpp>
#include<opencv2/imgproc/imgproc.hpp>
#include<opencv2/core/core.hpp>
#include<opencv2/highgui/highgui.hpp>
#include<opencv2/core/types.hpp>
using namespace cv;
using namespace std;
int main()
{
Point A(1,2);
Point B(2,5);
Point C = B.dot(A); 
return 0;
}