title: Resize and set quality on JPEG image while retaining EXIF in iOS
body: <p>In an iOS app, I have an <code>NSData</code> object that is a JPEG file that needs to be resized to a given resolution (2048x2048) and needs the JPEG quality set to 75%. These need to be set while retaining EXIF data in the file. The photo is not in the camera roll -- it was pulled over the network from a DSLR camera and is just temporarily stored with the app. If the image takes a trip through UIImage, the EXIF data is lost. How can I perform a resize and set quality without losing EXIF? Or is there a way to strip the EXIF data before the conversion and a way to add it back when done? </p>