Quantcast
Channel: OpenCV Q&A Forum - RSS feed
Viewing all articles
Browse latest Browse all 41027

ROI out of bounds issue

$
0
0
Hello forum, I would like to crop out a part of my image using > Mat crop = frame(_rectangle); The problem is, I get an error when _rectangle is out of bounds of my 1920 x 1080 frame. Is there a simple function that I could use to just crop out the section where the Rect and the Mat intersects ? I could write my own function for it but it would be simpler if opencv has a built-in function to resolve the out of bounds issue. Regards, Haziq

Viewing all articles
Browse latest Browse all 41027