修复静音没有声音bug
(cherry picked from commit c6f05b73a1805f1566ca99f1e70b6fb873655f98)
This commit is contained in:
parent
c845ecb41d
commit
351d7d8262
@ -257,6 +257,16 @@ extension SPPlayer {
|
||||
self.delegate?.sp_playCompletion?(self)
|
||||
}
|
||||
}
|
||||
|
||||
player.playerReadyToPlay = { (asset, assetURL) in
|
||||
do {
|
||||
try AVAudioSession.sharedInstance().setCategory(.playback)
|
||||
try AVAudioSession.sharedInstance().setActive(true)
|
||||
} catch {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user