Apple Live Photo file format

A live photo has two resources. They are tied together with an asset identifier (a UUID as a string). A JPEG; this must have a metadata entry for kCGImagePropertyMakerAppleDictionary with [17 : assetIdentifier] (17 is the Apple Maker Note Asset Identifier key). A Quicktime MOV encoded with H.264 at the appropriate framerate (12-15fps) and size … Read more

How to get an ALAsset URL from a PHAsset?

Create the assetURL by leveraging the localidentifier of the PHAsset. Example: PHAsset.localidentifier returns 91B1C271-C617-49CE-A074-E391BA7F843F/L0/001 Now take the 32 first characters to build the assetURL, like: assets-library://asset/asset.JPG?id=91B1C271-C617-49CE-A074-E391BA7F843F&ext=JPG You might change the extension JPG depending on the UTI of the asset (requestImageDataForAsset returns the UTI), but in my testing the extensions of the assetURL seems to be … Read more