I have been trying to minimize my memory footprint with UIImagePickerController
, but I\'m starting to think that the memory problems I am having are resulting from
Memory warnings are extremely common when dealing with the UIImagePickerController. This is especially true when using the camera. Keep in mind that while a JPG or PNG on disk may only amount to a few MB, the uncompressed in memory bitmap used to draw the image uses considerably more.
There's nothing that you're doing wrong necessarily, but some improvements can be made:
Rather than storing the image bytes in Core Data, why not write the image to disk and store the path to the file in your database?
Rather than using so many autoreleased images, can you find a way to manage their lifecycle directly and release them sooner?
Your best bet may be to write the images to disk as soon after processing as possible and free up the memory they're using. Then store their location using Core Data rather than the raw data.