Point p1 =Point(200,200);
Point p2 =Point(300,200);
cv::circle(src,p1,5,Scalar(0,255,0));
cv::circle(src,Point(200,300),5,Scalar(0,255,0));
cv::circle(src,Point(200,100),5,Scalar(0,255,0));
cv::circle(src,Point(100,200),5,Scalar(0,255,0));
cv::circle(src,Point(300,200),5,Scalar(0,255,0));
vector<cv::Point> points;getStraightLineAllPoint(p1.x,p1.y,p2.x,p2.y,points);for(vector<cv::Point>::iterator it = points.begin(); it !=points.end();++it ){
cv::circle(src,*it,1,Scalar(0,0,255));}