Author Topic: How to play both local and net media pls, m3u playlists?  (Read 154 times)

DeepDigger

  • Posts: 8
I can see that XMPlay plays both local and net media m3u playlists.
But BASS plays only net media playlists, and BASSHLS helps to play only hls playlists.
What a trick I don't know?

Ian @ un4seen

  • Administrator
  • Posts: 23311
BASS's playlist support (BASS_CONFIG_NET_PLAYLIST option) extends BASS_StreamCreateURL/File, which creates a single stream. That means it can only play one entry (the first playable one) from a playlist, so it's only really suitable for internet streams, where each stream has its own playlist.

More general playlist support needs to be implemented by the app, ie. parse the playlist file and then pass each entry to BASS_StreamCreateFile/URL when you want to play them. Fortunately, the M3U format is pretty simple: any line that doesn't start with # is a file/URL. The only slightly complicated part may be converting relative paths to full ones (using the playlist file's path).

DeepDigger

  • Posts: 8
Thank you, Sir.