title: Getting the area of the two different image parts of UIImage
body: <p><img src="https://i.stack.imgur.com/pZpzd.png" alt="enter image description here"></p>
  
  <p>This is UIImage that i am showing on the image view . My requirement is to get the area of these two different shapes separately in term of the pixels .I have tried a lot. Currently I am getting the addition of the pixels enclosed by those two areas. How can i get this areas differently is there any library or algorithm to do this?</p>