---
title: "photoOutput(_:didFinishProcessingLivePhotoToMovieFileAt:duration:photoDisplayTime:resolvedSettings:error:)"
framework: avfoundation
role: symbol
role_heading: Instance Method
path: "avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishprocessinglivephototomoviefileat:duration:photodisplaytime:resolvedsettings:error:)"
---

# photoOutput(_:didFinishProcessingLivePhotoToMovieFileAt:duration:photoDisplayTime:resolvedSettings:error:)

Provides the delegate the movie file URL resulting from a Live Photo capture.

## Declaration

```swift
optional func photoOutput(_ output: AVCapturePhotoOutput, didFinishProcessingLivePhotoToMovieFileAt outputFileURL: URL, duration: CMTime, photoDisplayTime: CMTime, resolvedSettings: AVCaptureResolvedPhotoSettings, error: (any Error)?)
```

## Parameters

- `output`: The photo output performing the capture.
- `outputFileURL`: The file URL at which the movie content of the Live Photo was written.
- `duration`: The duration of the Live Photo movie.
- `photoDisplayTime`: The timestamp within the movie to which the still image part of the Live Photo corresponds.
- `resolvedSettings`: An object describing the settings used for this capture. Match this object’s doc://com.apple.avfoundation/documentation/AVFoundation/AVCapturePhotoSettings/uniqueID value to the doc://com.apple.avfoundation/documentation/AVFoundation/AVCapturePhotoSettings/uniqueID property of the photo settings object you initiated capture with to determine which capture request this delegate call corresponds to. You can also use this object to find out which values the photo output has chosen for automatic settings.
- `error`: If the capture process could not proceed successfully, an error object describing the failure; otherwise, nil.

## Mentioned in

Capturing and saving Live Photos Tracking photo capture progress

## Discussion

Discussion Use this method to receive the results of a Live Photo capture. When the photo output calls this method, the movie component of the Live Photo has been written to the location specified by the outputFileURL parameter and the Live Photo is ready for consumption. (To receive the still image component of the Live Photo, implement the photoOutput(_:didFinishProcessingPhoto:previewPhoto:resolvedSettings:bracketSettings:error:) method.) tip: To add captured Live Photos to the user’s Photos library, use the PHAssetCreationRequest class. To use Live Photos from the Photos library, use the PHLivePhoto and PHLivePhotoView classes. To display Live Photo content on the web, use the LivePhotosKit JS framework. You don’t need to implement this method if you’re not requesting Live Photo capture. important: You must implement this method if you request Live Photo capture (by setting the livePhotoMovieFileURL property of your photo settings object). The photo output validates this requirement when you call its capturePhoto(with:delegate:) method; if your delegate does not implement the correct methods, the photo output raises an exception. The photo output calls this method only once for each Live Photo capture.

## See Also

### Receiving capture results

- [photoOutput(_:didFinishProcessingPhoto:error:)](avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishprocessingphoto:error:).md)
- [photoOutput(_:didFinishRecordingLivePhotoMovieForEventualFileAt:resolvedSettings:)](avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishrecordinglivephotomovieforeventualfileat:resolvedsettings:).md)
- [photoOutput(_:didFinishCapturingDeferredPhotoProxy:error:)](avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishcapturingdeferredphotoproxy:error:).md)
- [photoOutput(_:didFinishProcessingPhoto:previewPhoto:resolvedSettings:bracketSettings:error:)](avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishprocessingphoto:previewphoto:resolvedsettings:bracketsettings:error:).md)
- [photoOutput(_:didFinishProcessingRawPhoto:previewPhoto:resolvedSettings:bracketSettings:error:)](avfoundation/avcapturephotocapturedelegate/photooutput(_:didfinishprocessingrawphoto:previewphoto:resolvedsettings:bracketsettings:error:).md)
