CvDrawRect Method (CvArr, Int32, Int32, Int32, Int32, CvScalar, Int32, LineType, Int32) OpenCvSharp Class Library
Draws simple, thick or filled rectangle

Namespace:  OpenCvSharp
Assembly:  OpenCvSharp (in OpenCvSharp.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax

public static void DrawRect(
	CvArr img,
	int pt1X,
	int pt1Y,
	int pt2X,
	int pt2Y,
	CvScalar color,
	int thickness,
	LineType lineType,
	int shift
)

Parameters

img
Type: OpenCvSharpCvArr
Image.
pt1X
Type: SystemInt32
X-coordinate of the one of the rectangle vertices.
pt1Y
Type: SystemInt32
Y-coordinate of the one of the rectangle vertices.
pt2X
Type: SystemInt32
X-coordinate of the opposite rectangle vertex.
pt2Y
Type: SystemInt32
Y-coordinate of the opposite rectangle vertex.
color
Type: OpenCvSharpCvScalar
Line color (RGB) or brightness (grayscale image).
thickness
Type: SystemInt32
Thickness of lines that make up the rectangle. Negative values, e.g. CV_FILLED, make the function to draw a filled rectangle.
lineType
Type: OpenCvSharpLineType
Type of the line, see cvLine description.
shift
Type: SystemInt32
Number of fractional bits in the point coordinates.
See Also

Reference