c4valli / kodi-fcast-receiver

FCast receiver add-on for Kodi
GNU General Public License v2.0
10 stars 1 forks source link

HLS support #6

Closed xlash123 closed 10 months ago

xlash123 commented 11 months ago

This PR primarily adds HLS support. I wanted to implement this to support YouTube playback with Piped, which offers an HLS url in their API. I'm not certain it supports all HLS streams, but I was able to play some examples from Apple and a few YouTube videos.

The FCastPlayer now tracks all connected FCastSessions. This means multiple clients can connect and receive PlayBackUpdateMessages reliably. I've noticed thought that the protocol lacks the ability for new clients to receive metadata about the currently playing media. Maybe that is something we can propose for an FCast protocol update.

This also hopefully addresses #4. I've also had it happen where pausing will only very briefly pause the playback. It's intermittent, so I am not 100% certain I've fixed it, but assuming it is a race condition, this may resolve it.

xlash123 commented 11 months ago

I didn't expect to solve it so fast, but I had an idea to encode the MPEG-Dash manifest as a data URL to get around using an HTTP server. It works, and it solves #5

sguerrini97 commented 10 months ago

I didn't expect to solve it so fast, but I had an idea to encode the MPEG-Dash manifest as a data URL to get around using an HTTP server. It works, and it solves #5

Great approach! However this doesn't seem to work for me, I've opened #8 if you want to discuss about this