Instance Property

livePhotoAutoTrimmingEnabled

A Boolean value that specifies whether to automatically trim Live Photo movie captures to avoid excessive movement.

Declaration

@property(nonatomic, getter=isLivePhotoAutoTrimmingEnabled) BOOL livePhotoAutoTrimmingEnabled;

Discussion

Use this option to enable the same automatic trimming behavior found in the Camera app. By default, a Live Photo capture is about three seconds in duration (centered on the time of the capture request). However, if the user raises or lowers the camera during capture, iOS analyzes the movie capture in real time and automatically trims the duration of the Live Photo to avoid capturing excess movement.

When the livePhotoCaptureSupported is YES, this property’s value also defaults to YES.

Enabling or disabling this feature requires that a capture session set up its internal rendering pipeline differently. For best results, change this property’s value before calling the AVCaptureSession startRunning method. Changing this property while the session is running requires a lengthy reconfiguration of the capture render pipeline: Live Photo captures in progress will end immediately, unfulfilled photo requests will abort, and video preview will temporarily freeze.

See Also

Configuring Live Photo Capture

livePhotoCaptureSupported

A Boolean value indicating whether the capture output currently supports Live Photo capture.

livePhotoCaptureEnabled

A Boolean value that specifies whether to configure the capture pipeline for Live Photo capture.

livePhotoCaptureSuspended

A Boolean value that specifies whether to suspend, but not disable, Live Photo capture.

availableLivePhotoVideoCodecTypes

The list of video codecs currently available for capturing Live Photos with the photo output.