shaka-project / shaka-player

JavaScript player library / DASH & HLS client / MSE-EME player
Apache License 2.0
7.05k stars 1.33k forks source link

Time syncing issue in external texttracks (WebVtt) when there are ad markers in manifest files (HLS, DASH) #7088

Closed pankaj4may closed 1 month ago

pankaj4may commented 1 month ago

Have you read the Tutorials? Not thoroughly

Have you read the FAQ and checked for duplicate open issues? YES

If the question is related to FairPlay, have you read the tutorial?

NO

What version of Shaka Player are you using? 4.10

What browser and OS are you using? Chrome, Windows 10

Please ask your question When I load a player with manifest having Ad markers and external webvtt file(s), It is not time synced. I believe there must exists a configuration which do auto syncing of the external vtt files.

avelad commented 1 month ago

We can't help you with the information you provide...

Do subtitles take ads into account? What type of ads do you use? IMA, MediaTailor?

pankaj4may commented 1 month ago

Hi Avelad, Subtitles don't take ad into account. Ad markers are coming in as VMAP response to AWS MediaTailor service. For the same video on demand content I can have ad markers at different times based on 2 AWS EMT configurations. EMT EndPoint 1 --- Ad markers at say 1 & 3 minutes for 30 seconds EMT EndPoint 2 --- Ad markers at say 2 & 4 minutes for 30 seconds External WebVTT file has subtitles for the VOD content only (lets say 5 minute video)

I hope the above info gives enough information to suggest the possible solutions

avelad commented 1 month ago

Are you using our Ad Manager to manage AWS MediaTailor?

pankaj4may commented 1 month ago

Are you using our Ad Manager to manage AWS MediaTailor? Yes

avelad commented 1 month ago

I don't see anything obvious about what's wrong, because the code takes ads into account (see https://github.com/shaka-project/shaka-player/blob/main/lib/player.js#L5702) please fill out the bug template and so we can have more details to know what is happening.

pankaj4may commented 1 month ago

Thanks for the prompt reply. I'll check and revert. I am calling addTextTrackAsync after player.load(), I believe need to add TextTracks in - adManager.addEventListener(shaka.ads.Utils.ADS_LOADED,(e) => { console.log('ADS_LOADED'); });

shaka-bot commented 1 month ago

Closing due to inactivity. If this is still an issue for you or if you have further questions, the OP can ask shaka-bot to reopen it by including @shaka-bot reopen in a comment.