Type Method


Returns the list of data resources associated with a Live Photo object.


class func assetResources(for livePhoto: PHLivePhoto) -> [PHAssetResource]



A Live Photo object.

Return Value

The underlying resources that constitute the Live Photo.


A Live Photo is a picture, taken with a compatible device, that includes movement and sound from the moments just before and after its capture. A PHLivePhoto object represents the displayable combination of image, motion, and sound data. You can obtain such objects from the Photos library using the PHImageManager class or construct them from asset resources exported from a Photos library using the PHLivePhoto class.

Use this method to export the underlying resources that constitute a Live Photo. For example, a social networking app can retrieve those data files and upload them to a server. Then, on another user’s device, the app downloads those data files and uses the PHLivePhoto class to re-create a Live Photo object for display using the PHLivePhotoView class.

See Also

Retrieving an Asset’s Data Resources

class func assetResources(for: PHAsset) -> [PHAssetResource]

Returns the list of data resources associated with an asset.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software