|
@@ -208,7 +208,7 @@ class NCLivePhoto {
|
|
|
let videoReaderOutput = AVAssetReaderTrackOutput(track: videoTrack, outputSettings: videoReaderSettings)
|
|
|
videoReader?.add(videoReaderOutput)
|
|
|
// Create Video Writer Input
|
|
|
- let videoWriterInput = AVAssetWriterInput(mediaType: .video, outputSettings: [AVVideoCodecKey : AVVideoCodecH264, AVVideoWidthKey : videoTrack.naturalSize.width, AVVideoHeightKey : videoTrack.naturalSize.height])
|
|
|
+ let videoWriterInput = AVAssetWriterInput(mediaType: .video, outputSettings: [AVVideoCodecKey : AVVideoCodecType.h264, AVVideoWidthKey : videoTrack.naturalSize.width, AVVideoHeightKey : videoTrack.naturalSize.height])
|
|
|
videoWriterInput.transform = videoTrack.preferredTransform
|
|
|
videoWriterInput.expectsMediaDataInRealTime = true
|
|
|
assetWriter?.add(videoWriterInput)
|