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
[WIP] Add edit box support to offset PTS #553
Conversation
Hi @drichards tks for this PR refer to the spec, u need 4 bytes for segment duration and 4 bytes for media time
i did some preliminary tests some months ago on a local branch, with hardcoded offset for the audio track ... just to give it a try (before computing the offset as u did in mp4-remuxer) and using i could avoid glitches with Safari. |
@drichards I'm pretty sure you are doing it wrong. As far as I can tell, the duration should be 0, and the media time is the configurable part (which you set to -1 / 0xffffffff for some reason). |
Reading through the spec here http://l.web.umkc.edu/lizhu/teaching/2016sp.video-communication/ref/mp4.pdf
That seems to say that an offset should be specified by a duration (first 4 bytes after the number of entries bytes) with a media-time of -1 (next 4 bytes). In #9 @jernoble also discussed "empty edits" which are specified using a media-time of -1. I tried changing the offset to be in the media-time field and set the segment duration to 0. That seems to have avoided the stuttering poster image but doesn't fix the problem for two reasons
The second of those indicates to me that potentially the calculation for the offset is being done wrong, but it still doesn't seem to agree with how the spec presents edit box offsets. |
to be able to offset start position related to https://github.com/dailymotion/hls.js/issues/9 related to https://github.com/dailymotion/hls.js/pull/553
this should improve playback startup in Safari related to https://github.com/dailymotion/hls.js/issues/9 related to https://github.com/dailymotion/hls.js/pull/553
Hi @drichards , I slightly adjusted your logic on elst branch |
Looks good to me. Looks like there's a couple of console.logs in there that I imagine you'd want to clean up/replace with logger.log |
One more on line 513 of mp4-generator |
ok I am suspecting it might be related to https://github.com/dailymotion/hls.js/pull/559 |
should be fixed now |
Only the buck bunny video plays for me, the others load, but I can't convince the player to start - and with 'pipe dream' safari freezes and/or becomes unresponsive (beach ball etc.) |
Yes ... one step further... but how many steps left ? :-/ |
@mangui - considering that this is a blindfolded reverse-engineering/guessing process with an extremely loose (TS) spec it's good progress ;-) |
Closing this due to lack of activity |
Made an initial stab at of the edit box changes discussed in #9, however it doesn't seem to make much difference to stream startup in safari, so possibly I'm doing something wrong.
Thoughts I have about this: