-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
API to get live stream position as Date, not relative to video timeline #356
Comments
You can use |
I could use the current seek value (for example, getting the HTML Video DOM element, and getting |
If you just need the playhead position then you should use |
Nope, I need the real time (UTC) of the playhead, like |
Ah, got it. We could add an API for that. You could also try var timeBehindLiveEdge = player.seekRange().end - video.currentTime;
var streamPosition = (Date.now() / 1000) - timeBehindLiveEdge; although, since |
It may work but it won't be precise. I'm thinking about accesing |
This works great:
|
Modifications to the manifest by the application could have many unintended consequences.
We could provide an equivalent API for this. |
Is it possible using Shaka to get the current live playback time, from a live streaming MPD, such as
.timeAsUTC()
of Dash.js?Thanks!
The text was updated successfully, but these errors were encountered: