Open OmarPedraza opened 3 years ago
Embedded doesn't support the track-selection callback. In general, the configure method can only accept strings and numbers, not functions. And passing some selector won't work since the value is just forwarded to JavaScript. We could add this callback to the ShakaPlayerStorageClient object like the progress callback.
Thanks @TheModMaker, that would be awesome!
Any ETA about when it would be available?
Hello, Following the documentation for JavaScript, I'm trying to select for download the desired track depending on its bandwidth.
I've tried with the following code:
player?.configure("offline.trackSelectionCallback", with: "selectTrack")
But
ShakaPlayer
object returns the following error:Due to that, I tried with several changes in the configuration:
player?.configure("offline.trackSelectionCallback", with: "selectTrack()")
player?.configure("offline.trackSelectionCallback", with: "selectTrack(_:)")
player?.configure("offline.trackSelectionCallback", with: "selectTrack(:)")
Am I doing anything wrong? Is track selection not yet available for iOS?