|
@@ -1037,12 +1037,7 @@ class PQStuckPointEditerController: PQBaseViewController {
|
|
|
|
|
|
func settingPlayerView() {
|
|
func settingPlayerView() {
|
|
stuckPointCuttingView.resetDefaultsColor()
|
|
stuckPointCuttingView.resetDefaultsColor()
|
|
- synchroMarskView.removeFromSuperview()
|
|
|
|
- if synchroMarskView.superview == nil {
|
|
|
|
- UIApplication.shared.keyWindow?.addSubview(synchroMarskView)
|
|
|
|
- synchroMarskView.show()
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
|
|
+
|
|
// 1,设置播放器的显示区域 和画布大小
|
|
// 1,设置播放器的显示区域 和画布大小
|
|
// - 按第一个素材尺寸自适应
|
|
// - 按第一个素材尺寸自适应
|
|
playerView.pause()
|
|
playerView.pause()
|
|
@@ -1143,7 +1138,8 @@ class PQStuckPointEditerController: PQBaseViewController {
|
|
|
|
|
|
self.playerView.play(pauseFirstFrame: false, playeTimeRange: CMTimeRange(start: self.playeTimeRange.start, end: self.playeTimeRange.end))
|
|
self.playerView.play(pauseFirstFrame: false, playeTimeRange: CMTimeRange(start: self.playeTimeRange.start, end: self.playeTimeRange.end))
|
|
self.stuckPointCuttingView.updateProgress(progress: 0)
|
|
self.stuckPointCuttingView.updateProgress(progress: 0)
|
|
-
|
|
|
|
|
|
+ self.synchroMarskView.removeMarskView()
|
|
|
|
+
|
|
let end4: TimeInterval = Date().timeIntervalSince1970
|
|
let end4: TimeInterval = Date().timeIntervalSince1970
|
|
BFLog(message: " playerView.play tiskskskskme \(end4 - end3)")
|
|
BFLog(message: " playerView.play tiskskskskme \(end4 - end3)")
|
|
|
|
|
|
@@ -1164,7 +1160,6 @@ class PQStuckPointEditerController: PQBaseViewController {
|
|
|
|
|
|
self?.stuckPointCuttingView.updateProgress(progress: CGFloat(progress))
|
|
self?.stuckPointCuttingView.updateProgress(progress: CGFloat(progress))
|
|
|
|
|
|
- self?.synchroMarskView.removeMarskView()
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -1781,10 +1776,7 @@ extension PQStuckPointEditerController {
|
|
/// - Returns: <#description#>
|
|
/// - Returns: <#description#>
|
|
func synchroMusicInfoData(resetSelectIndex:Bool = true) {
|
|
func synchroMusicInfoData(resetSelectIndex:Bool = true) {
|
|
if (stuckPointMusicData?.rhythmSdata.count ?? 0) <= 0 {
|
|
if (stuckPointMusicData?.rhythmSdata.count ?? 0) <= 0 {
|
|
- if synchroMarskView.superview == nil {
|
|
|
|
- UIApplication.shared.keyWindow?.addSubview(synchroMarskView)
|
|
|
|
- synchroMarskView.show()
|
|
|
|
- }
|
|
|
|
|
|
+ synchroMarskView.show()
|
|
PQStuckPointViewModel.stuckPointMusicDetailData(musicId: stuckPointMusicData?.musicId ?? "", originType: stuckPointMusicData?.originType ?? 1) { [weak self] newMusicData, _ in
|
|
PQStuckPointViewModel.stuckPointMusicDetailData(musicId: stuckPointMusicData?.musicId ?? "", originType: stuckPointMusicData?.originType ?? 1) { [weak self] newMusicData, _ in
|
|
if newMusicData != nil, (newMusicData?.rhythmSdata.count ?? 0) > 0 {
|
|
if newMusicData != nil, (newMusicData?.rhythmSdata.count ?? 0) > 0 {
|
|
self?.isStuckPointDataSuccess = true
|
|
self?.isStuckPointDataSuccess = true
|
|
@@ -1819,11 +1811,10 @@ extension PQStuckPointEditerController {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} else if stuckPointMusicData?.localPath == nil || (stuckPointMusicData?.localPath?.count ?? 0) > 0 {
|
|
} else if stuckPointMusicData?.localPath == nil || (stuckPointMusicData?.localPath?.count ?? 0) > 0 {
|
|
- if synchroMarskView.superview == nil {
|
|
|
|
- UIApplication.shared.keyWindow?.addSubview(synchroMarskView)
|
|
|
|
- synchroMarskView.show()
|
|
|
|
- }
|
|
|
|
|
|
+
|
|
|
|
+ synchroMarskView.show()
|
|
isStuckPointDataSuccess = true
|
|
isStuckPointDataSuccess = true
|
|
|
|
+
|
|
PQDownloadManager.downLoadFile(url: stuckPointMusicData?.musicPath ?? "") { [weak self] filePath, error in
|
|
PQDownloadManager.downLoadFile(url: stuckPointMusicData?.musicPath ?? "") { [weak self] filePath, error in
|
|
if error == nil, filePath != nil {
|
|
if error == nil, filePath != nil {
|
|
self?.isSynchroMusicInfoSuccess = true
|
|
self?.isSynchroMusicInfoSuccess = true
|