What does normalizedPath refer to and how can I draw it over an image in iOS?

183 Views Asked by At

I have two images, one that is a monochrome one which is a mask and another one with full color. What I need to do is find the CGRect of the mask (white pixels) in the other full color one.

What I did is to first find the contour of the mask using the Vision framework. Now, this returns a CGPath which is normalised. How can I translate this path into coordinates to the other image? Both have been scaled the same way to make them the same size so the translation should be "easy" but I can't figure it out.

0

There are 0 best solutions below