Can any body tell me how to intialize MatOfRect object with MatOfRect Constructor taking Mat object as a parameter?
I want to store Mat object values in Rect object. To do that I tried to create MatOfRect object with Mat Object values. But it throws an Exception saying Incompatible Mat and then app stops. Can anybody help me to solve this?What am I doing wrong?
"I want to store Mat object values in Rect object." -- wait, this is not possible.
do you want to store submat's somehow ? then use a list or vector of Mat's.
Can I use Converters class methods for what you have told? What does the following method does public static void Mat_to_vector_Rect(Mat m, java.util.List<rect> rs)? Could you also explain me about the second argument in this method?
Ya I do understand the difference. What I wanted to do is Detected rectangular region coordinates of an image to be stored in Rect.
oh, ok. then i partly misread your post, apologies.
When I used cascade classifier it directly stored coordinates in Rect object. I tried template matching there it directly stores the matched template region to another Mat object. But I want those coordinates for further detection of object in this area of interest. So do you know any way I can do this?