Update:iOS HLS stream buffer set to 50s

This commit is contained in:
advplyr 2023-03-27 16:54:19 -05:00
parent 6584cd1522
commit ef1d8a8eb4

View file

@ -88,6 +88,9 @@ class AudioPlayer: NSObject {
for track in playbackSession.audioTracks {
if let playerAsset = createAsset(itemId: playbackSession.libraryItemId!, track: track) {
let playerItem = AVPlayerItem(asset: playerAsset)
if (playbackSession.playMethod == PlayMethod.transcode.rawValue) {
playerItem.preferredForwardBufferDuration = 50
}
self.allPlayerItems.append(playerItem)
}
}