数据结构
1. Point
Point pt;
pt.x = 10;
pt.y = 8;
Point pt = Point(10, 8);
Point represents a 2D point, specified by its image coordinates
2. Scalar
Scalar( a, b, c )
- Represents a 4-element vector. The type Scalar is widely used in OpenCV for passing pixel values.
- we will use it extensively to represent BGR color values (3 parameters). It is not necessary to define the last argument if it is not going to be used.
椭圆
void cv::ellipse (
InputOutputArray img,
Point center,
Size axes,
double angle,
double startAngle,
double endAngle,
const Scalar & color,
int thickness = 1,
int lineType = LINE_8,
int shift = 0
)
圆
void cv::circle (
InputOutputArray img,
Point center,
int radius,
const Scalar & color,
int thickness = 1,
int lineType = LINE_8,
int shift = 0
)
新tip
imshow( atom_window, atom_image );
moveWindow( atom_window, 0, 200 );
imshow( rook_window, rook_image );
moveWindow( rook_window, w, 200 );
-
moveWindow
可以移动窗口到屏幕指定位置
网友评论