cv.rectangle - MATLAB File Help
cv.rectangle

Draws a simple, thick, or filled up-right rectangle

img = cv.rectangle(img, pt1, pt2)
img = cv.rectangle(img, rect)
[...] = cv.rectangle(..., 'OptionName', optionValue, ...)

Input

Output

Options

The function cv.rectangle draws a rectangle outline or a filled rectangle whose two opposite corners are pt1 and pt2, or [x,y] and [x+w-1,y+h-1] (top-left and bottom-right corners of rectange used in the second variant of the function).

See also