0

I am trying to play a HLS live stream using videogular2. The video is playing fine however, it does not show the right time. I am guessing videogular2 should parse the .m3u8 manifest file and use the "EXT-X-PROGRAM-DATE-TIME" header as an offset to the current time. It does not seem to be working that way.

Is there any way I can parse the file? Would really appreciate some help.

  • Thank you for your question, could you provide a bit more detail to help this get answered. What have you already tried? Do you have some code you can share. See https://stackoverflow.com/help/how-to-ask for tips about how to write a good question – Peter Campbell Jan 31 '19 at 11:11

1 Answers1

0

uses hls.js which does support EXT-X-PROGRAM-DATE-TIME. Fragments have the programDateTime and rawProgramDateTime attributes. These are not used in the native video controls, you most likely need to implement your own custom controls. See the hls.js demo (bottom).

aergistal
  • 29,947
  • 5
  • 70
  • 92
  • Thanks for the reply, I obtained the programDateTime by parsing it directly using hls.js. I was wondering if there is any way to get it from videogular2 itself. Also, I noticed a difference of around 18-20 seconds from the parsed value I obtained and the value I see in the response of the GET call. – Kshitij Agrawal Feb 01 '19 at 07:03
  • @KshitijAgrawal did you check the program date time of the first fragment or a later one? – aergistal Feb 01 '19 at 09:03
  • yes, it's the first fragment. I got it from here : data.levels[0].details.fragments[0].programDateTime – Kshitij Agrawal Feb 01 '19 at 10:14