RenderHeads / UnityPlugin-AVProVideo

AVPro Video is a multi-platform Unity plugin for advanced video playback
https://www.renderheads.com/products/avpro-video/
232 stars 28 forks source link

local .m3u8 files fail to load/play #1400

Closed drew-512 closed 1 year ago

drew-512 commented 1 year ago

Describe the issue A local m3u8 file fed to MediaPlayer via MediaPath results in an error.

Your Setup (please complete the following information):

To Reproduce

  1. use any .m3u8 file (get one here here > Tune-in > iTunes)
  2. Option: edit extension from .m3u to .m3u8 (both result in this error)
  3. Load and play this file item via MediaPlayer via Path
  4. [AVProVideo] Error: Loading failed. File not found, codec not supported, video resolution too high or insufficient system resources.
MorrisRH commented 1 year ago

Playback of a local m3u8 file is not supported by Apple, and therefore we're unable to support it. You will need to host your files on a web server, this can be running locally though (we use nginx here for testing purposes).

drew-512 commented 1 year ago

So a GET of a m3u8 file is supported but a local read of a file isn't, correct? For my own knowledge, this is just a matter of feeding a m3u8 (and mimetype) via http GET to AVPro, correct? Not getting how it's related to Apple.

On a related note -- I did have a question around IRandomAccessStream support since it unfortunately is Windows-specific (which would also trivially address this issue):

https://github.com/RenderHeads/UnityPlugin-AVProVideo/issues/1408

Thanks for your consideration, Drew

MorrisRH commented 1 year ago

The Apple part is because AVFoundation does not support loading of local m3u8 files. For HLS playback, the m3u8 and associated files have to come from an HTTP server.

drew-512 commented 1 year ago

Thanks mate, ttya before long...