-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Reversed cue display order for identical time ranges #848
Comments
As mentioned in comments to #821 I verified that we are parsing the "tts:origin" attribute and constructing the VttCues correctly, so it's likely to be a browser bug. |
So the browser is actually doing what the spec says: https://w3c.github.io/webvtt/#webvtt-cue-line-automatic If all lines are "auto", the first cue will be given the line -1, the second -2, and so on. This leads to the captions appearing reversed. I've checked dash.js and it has the same issue. |
If the browser behavior is to-spec, then we should reverse the order of the cues before sending them to the browser. |
Since the browser displays identical ranges from bottom up, we must reverse the order before feeding them to the browser. This way, the first one parsed shows up on top. Issue #848 Change-Id: Id2e6582e610808f7061bd0f8281c0705ecf1d6dc
We've pushed a fix to |
I'm unable to reproduce any issue in Chrome's support of line=. I've tested line=-1, -2, -3 with snapToLines=true and line=10, 20, 30 with snapToLines=false. In all cases, in any insertion order, the display is correct. If you see any further issue with this, please let us know and we can reopen. |
Since the browser displays identical ranges from bottom up, we must reverse the order before feeding them to the browser. This way, the first one parsed shows up on top. Issue #848 Backported to v2.1.x
Fix backported to v2.1.6. |
IE/Edge don't accept cues that are out of time order. So when we reverse the order of cues for #848, the cues would be rejected. Now we sort the cues and only reverse the order of cues with equal times. Change-Id: I860e1ea9694eb95ff2e74d9545c92373eb371686
IE/Edge don't accept cues that are out of time order. So when we reverse the order of cues for #848, the cues would be rejected. Now we sort the cues and only reverse the order of cues with equal times. Backported to v2.1.x Change-Id: I860e1ea9694eb95ff2e74d9545c92373eb371686
Split from #821 filed by @ewosleger:
The text was updated successfully, but these errors were encountered: