How to make image of template matching result
Hi,
I wanted to know that how can we extract the image out of the result we get by matchTemplate method of opencv.
I don't know how to use its location to make an image (colored), we can though put a rectangle on it if matched as shown in the following example, but how can we make a separate image of this rectangle?
hmm, the "result" image from template matching contains the probability density for the matching at each pixel. do you just need a better visualization for this ? it's a bit unclear, what you wanted.
We can put rectangle in the image where the template is detected, right? as shown in the link I gave.
I just want to crop that area and make another image of it, how can we do that using the "result" Matrix. We can draw rectangle on it, then surely we would be able to extract it as well, don't we?
sorry for being extra dumb, but i still don't get it.
in the result image, only a single point (the max or min) is relevant. drawing a rectangle there (or extracting the roi) has no significance.
did you mean: cropping the roi from the query image, where the template was found ?
You're berek from my previous question too right?
Significance for me in it is i would get colored part in the Main Image as i had shown previously.
I want to match and extract that colored part.
See here
I want to match and when detected, i want to extract that colored part from Main Image.