浏览代码

合成时的音量设置

harry 3 年之前
父节点
当前提交
94c5595eb7
共有 2 个文件被更改,包括 11 次插入2 次删除
  1. 3 0
      Introduce/Record/INIntroduceController.swift
  2. 8 2
      Introduce/Record/INVideoExportController.swift

+ 3 - 0
Introduce/Record/INIntroduceController.swift

@@ -106,6 +106,9 @@ class INIntroduceController: BFBaseViewController {
 
         let controller = INVideoExportController()
         controller.export.data = recordScreenVC.itemModels
+        controller.export.originSoundVolumn = recordScreenVC.noSpeakVolume
+        controller.export.originSoundInRecordVolumn = recordScreenVC.haveSpeakVolume
+
         navigationController?.pushViewController(controller, animated: true)
     }
 }

+ 8 - 2
Introduce/Record/INVideoExportController.swift

@@ -21,7 +21,13 @@ class INVideoExportController: BFBaseViewController {
     var hasSaveOnly = false
     var saveAllUlr = URL(fileURLWithPath: "aaa")
     var saveOnlyUlr = URL(fileURLWithPath: "aaa")
-    var isExporting = false
+    var isExporting = false {
+        didSet {
+            if isExporting {
+                avplayer.pause()
+            }
+        }
+    }
 
     // 预览播放进度
     lazy var progreddL: UILabel = {
@@ -288,12 +294,12 @@ class INVideoExportController: BFBaseViewController {
             cShowHUB(superView: nil, msg: "正在合成中。。。")
             return
         }
+        isExporting = true
         bottomView.isHidden = true
         progressView.isHidden = false
         progressL.isHidden = false
         progreddL.isHidden = true
         export.startExprot(synthesisAll: saveAllBtn.isSelected)
-        isExporting = true
         UIApplication.shared.isIdleTimerDisabled = true
     }