title: How to quickly estimate file sizes of resized images on iOS?
body: <p>In Mail, when I add an image and try to send it, it quickly asks me which size I want to send the images as. See screenshot:</p>
  
  <p><img src="https://i.stack.imgur.com/INNS5.jpg" alt="enter image description here"></p>
  
  <p>I want to do something similar in an app where I will be uploading an image and want to enable the user to resize the image before it is uploaded. What is the best way to estimate the file size as Apple does here? </p>
  
  <p>It seems that it would take too long to actually create each of the resized images only to check them for sizes. Is there a better way?</p>
  
  <p>I did find <a href="http://developer.apple.com/library/ios/#samplecode/LargeImageDownsizing/Introduction/Intro.html#//apple_ref/doc/uid/DTS40011173-Intro-DontLinkElementID_2" rel="noreferrer">this Apple sample code</a> which helps a little bit but to be honest is a bit overwhelming. :) </p>