Created
March 6, 2014 05:23
-
-
Save spoletto/9383098 to your computer and use it in GitHub Desktop.
The undocumented behavior of ALAssetPropertyDate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* In practice, what I've found is that ALAssetPropertyDate, which is documented as the "asset creation time" | |
* will return (always in UTC): | |
* | |
* (1) If taken from the native camera, a ms-precision time of when the photo was taken. | |
* (2) If EXIF exists, EXIF time converted to UTC based on the timezone the device was in when | |
* the photo was saved to the camera roll. This is sec-precision. | |
* (3) If EXIF does not exist, the time the photo was written into the camera roll. This is sec-precision. | |
*/ | |
NSDate *timeTaken = [asset valueForProperty:ALAssetPropertyDate]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
From this article, I found three types of date time in EXIF, so I am wondering which exif time convert to ALAssetPropertyDate? I can't make it out because I don't have a photo that has three different date time.