官术网_书友最值得收藏!

Rect object type

Rect is another important template class for defining 2D rectangles defined by the following parameters:

  • The coordinates of the upper-left corner

  • The width and height of a rectangle

The Rect template class can be used to define a region of interest (ROI) of an image, as follows:

Mat img=imread("lena.jpg");
Rect rect_roi(0,0,100,100);
Mat img_roi=img(r);
主站蜘蛛池模板: 哈巴河县| 兰溪市| 秦安县| 鹤庆县| 延安市| 甘洛县| 洪湖市| 阳原县| 镇巴县| 东乡族自治县| 太原市| 特克斯县| 新野县| 墨竹工卡县| 平阴县| 边坝县| 定远县| 太康县| 阿瓦提县| 长沙市| 益阳市| 仪陇县| 南和县| 安塞县| 上杭县| 陇南市| 柳林县| 耿马| 乐山市| 清丰县| 南京市| 延寿县| 南京市| 新乡市| 江山市| 华阴市| 田林县| 衢州市| 阜康市| 德惠市| 青铜峡市|