My 2 cents is that defaulting to two file writes for a single image is not desirable behaviour, a big reason why the Exif Writer exists is that it avoids multiple file writes, which the iOS native libraries would otherwise require.
Behaviour should be: write to a single specified location. To clarify what is occuring: Here is where the image is written to camera roll: https://github.com/apache/cordova-ios/blob/master/CordovaLib/Classes/CDVCamera.m#L275 Here is where Exif data is spliced in, while the image is still in memory: https://github.com/apache/cordova-ios/blob/master/CordovaLib/Classes/CDVCamera.m#L301 Here is where the image with the exif splice is written to a custom file URI: https://github.com/apache/cordova-ios/blob/master/CordovaLib/Classes/CDVCamera.m#L321 All three of these occur with a single image taken through the image picker controller. Thanks for your work on this James! - Lorin On Fri, Apr 5, 2013 at 7:55 AM, James Jong <[email protected]> wrote: > I have been looking at Lorin's iOS image metadata writer that was recently > merged in 2.6.x and noticed that the exif metadata was missing from the > saved photos. After troubleshooting some w Lorin, I discovered that the > image saved to the photo album is the image before scaling and writing of > the exif metadata. This results in 2 different images which was confusing > to me. Is this correct intent? This refers to iOS code but my question is > intended for the Camera API. Do other platforms that support this follow > the same behavior? > > ref code in camera > > https://github.com/apache/cordova-ios/blob/master/CordovaLib/Classes/CDVCamera.m#L275 > > -James Jong > >
