Class cv::Point_#
Template class for 2D points specified by its coordinates x and y. View details
#include <opencv2/core/types.hpp>Collaboration diagram for cv::Point_:
Detailed Description#
Template class for 2D points specified by its coordinates x and y.
An instance of the class is interchangeable with C structures, CvPoint and CvPoint2D32f . There is also a cast operator to convert point coordinates to the specified type. The conversion from floating-point coordinates to integer coordinates is done by rounding. Commonly, the conversion uses this operation for each of the coordinates. Besides the class members listed in the declaration above, the following operations on points are implemented:
pt1 = pt2 + pt3;
pt1 = pt2 - pt3;
pt1 = pt2 * a;
pt1 = a * pt2;
pt1 = pt2 / a;
pt1 += pt2;
pt1 -= pt2;
pt1 *= a;
pt1 /= a;
double value = norm(pt); // L2 norm
pt1 == pt2;
pt1 != pt2;
Member Typedef Documentation#
value_type#
typedef Tp cv::Point::value_type
Constructor & Destructor Documentation#
Point_()#
cv::Point_::Point_()
default constructor
Point_()#
cv::Point_::Point_(
_Tp _x,
_Tp _y )
Point_()#
cv::Point_::Point_(const Point_ & pt)
Point_()#
cv::Point_::Point_(const Size_< _Tp > & sz)
Point_()#
cv::Point_::Point_(const Vec< _Tp, 2 > & v)
Point_()#
cv::Point_::Point_(Point_ && pt)
Member Function Documentation#
cross()#
double cv::Point_::cross(const Point_ & pt)
cross-product
ddot()#
double cv::Point_::ddot(const Point_ & pt)
dot product computed in double-precision arithmetics
dot()#
Tp cv::Point::dot(const Point_ & pt)
dot product
inside()#
bool cv::Point_::inside(const Rect_< _Tp > & r)
checks whether the point is inside the specified rectangle
operator Point_< _Tp2 >()#
template<typename _Tp2>
cv::Point_::operator Point_< _Tp2 >()
conversion to another data type
operator Vec< _Tp, 2 >()#
cv::Point_::operator Vec< _Tp, 2 >()
conversion to the old-style C structures
operator=()#
Point_ & cv::Point_::operator=(const Point_ & pt)
operator=()#
Point_ & cv::Point_::operator=(Point_ && pt)
Member Data Documentation#
x#
Tp cv::Point::x
x coordinate of the point
y#
Tp cv::Point::y
y coordinate of the point
Source file#
The documentation for this class was generated from the following file:
opencv2/core/types.hpp