diff --git a/HaishinKit/Sources/HKStream/HKStreamRecorder.swift b/HaishinKit/Sources/HKStream/HKStreamRecorder.swift index fe227a65c..f4aa72ac4 100644 --- a/HaishinKit/Sources/HKStream/HKStreamRecorder.swift +++ b/HaishinKit/Sources/HKStream/HKStreamRecorder.swift @@ -173,6 +173,9 @@ public actor HKStreamRecorder { } writer = try AVAssetWriter(outputURL: outputURL, fileType: fileType) + if let movieFragmentInterval { + writer?.movieFragmentInterval = CMTime(seconds: movieFragmentInterval, preferredTimescale: 1) + } videoPresentationTime = .zero audioPresentationTime = .zero self.settings = settings