Browse Source

图片音频导出

harry 3 years ago
parent
commit
bdb243c291
1 changed files with 14 additions and 0 deletions
  1. 14 0
      BFRecordScreenKit/Classes/BFRecordExport.swift

+ 14 - 0
BFRecordScreenKit/Classes/BFRecordExport.swift

@@ -97,6 +97,20 @@ public class BFRecordExport {
 //                        voice.voiceType = VOICETYPT.None.rawValue
                         voice.volumeGain = 100
                         voiceList.append(voice)
+                    }else{
+                        //
+                        for mod in itemModel.voiceStickers {
+                            let sticker = PQEditVisionTrackMaterialsModel()
+                            sticker.model_in = 0
+                            sticker.out = mod.endTime - mod.startTime
+                            sticker.timelineIn = totalDur + mod.startTime
+                            sticker.timelineOut = totalDur + mod.endTime
+                            sticker.aptDuration = sticker.out
+                            sticker.duration = sticker.out
+                            sticker.locationPath = mod.wavFilePath
+                            sticker.volumeGain = 100 // Float64(model.volume)
+                            voiceList.append(sticker)
+                        }
                     }
                     
                     let sticker = splitBaseMaterial(timelineIn: totalDur, model_in: 0, duration: duration)