proposals
proposals copied to clipboard
Video time in accordance to playbackrate
Introduction
We we have video which is 60 seconds long, when the playbackrate set to 2x the video length should be 30 seconds as of today the UI doesn't reflect in accordance to the playbackrate.
Use Cases
Users normally have to do the math to calculate the remaining time for a video based on the playbackrate, which shouldn't be the case?
Goals
- Video element to reflect the time in accordance to playbackrate
- Maybe we need an APIs to get the remaining time with an option to consider the playbackrate.
Non-goals (Optional)
TDB
Proposed Solution
Video's total time should be calculated considering the playbackrate
Examples
const video = document.createElement('video');
const curtime = video.duration; // maybe this should consider the playbackrate
const video = document.createElement('video');
const curtime = video.getDuration('playbackrate'); // or maybe getDurationWithPlayback, ah too big
Alternate Approaches
video.countdownvideo.remaining
+1 for the use case. I’d make it video.remainingTime, consistent with currentTime.
@tomayac What would be the next logical step here? We should present this idea in a TAG meeting?
Maybe open this as an issue on the WHATWG/HTML repo to get more feedback?
I agree with @tomayac, and also suggest opening an HTML spec issue, for the whatwg/media folks to respond to.
Done. Should we close this then?
I’d link the present issue from the new HTML issue so there’s a paper trail.