-
Notifications
You must be signed in to change notification settings - Fork 213
fix: skip DTG1 packets in parseSei #330
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
Conversation
Atypical streams containing 2+ SEI NAL payloads of type 0x04 (CEA-708 caption content) in the sei_rbsp, specifically a DTG1 payload preceding a GA94 payload, fail to display captions as mux.js returns prematurely with the DTG1 payload. By checking for the user ID within this function, mux.js can continue iterating over the sei_rbsp for the GA94.
Shaka Player is also interested in this PR. |
@gesinger, could you look at this PR when you have time? This is another fix we'd like to have in our next release of Shaka Player, if possible. |
Looking at the netlify build, I can see that 608 captions continue to work in bipbop but I don't quite understand what's happening. |
looking at the spec and re-reading the description and code again, I guess what's happening is that we're only accounting for sei packets in the AFD format and exit early but it's possible that in ATSC streams, there's more data that we should parse through and then exit on the GA94 payload? At the same time, we don't want to accumulate the extra payloads because they won't be caption data. Am I understanding it correctly? |
I don't believe mux.js would accumulate extra payloads with this change (the returned payload wouldn't contain non-caption data). Spec-wise I don't see any issues, but this PR stemmed from an internal report where streams didn't display captions, and after running it through a media analyzer, they all contained both an AFD and ATSC sei packet. With the PR, captions were displayed properly. |
Thanks! It does seem like it's correct, I was asking about the specs mostly because I have very little knowledge on this subject matter. |
Atypical streams containing 2+ SEI NAL payloads of type 0x04 (CEA-708 caption content) in the sei_rbsp, specifically a DTG1 payload preceding a GA94 payload, fail to display captions as mux.js returns prematurely with the DTG1 payload. By checking for the user ID within this function, mux.js can continue iterating over the sei_rbsp for the GA94.
Sorry, please refer to #333 instead. |
This gets us a fix for a closed caption parsing issue described in videojs/mux.js#330 and fixed in videojs/mux.js#333: > Atypical streams containing 2+ SEI NAL payloads of type 0x04 > (CEA-708 caption content) in the sei_rbsp (specifically a DTG1 > payload preceding a GA94 payload) fail to display captions in this > scenario, as the current logic results in parseSei() prematurely > returning with the DTG1 payload. > > By checking for the user ID within parseSei, mux.js can continue > iterating through the sei_rbsp for the GA94 payload. Change-Id: I9d90419643279a1273187e0354b5e991cd609ba2
This gets us a fix for a closed caption parsing issue described in videojs/mux.js#330 and fixed in videojs/mux.js#333: > Atypical streams containing 2+ SEI NAL payloads of type 0x04 > (CEA-708 caption content) in the sei_rbsp (specifically a DTG1 > payload preceding a GA94 payload) fail to display captions in this > scenario, as the current logic results in parseSei() prematurely > returning with the DTG1 payload. > > By checking for the user ID within parseSei, mux.js can continue > iterating through the sei_rbsp for the GA94 payload. Backported to v2.5.x Change-Id: I9d90419643279a1273187e0354b5e991cd609ba2
Atypical streams containing 2+ SEI NAL payloads of type 0x04 (CEA-708 caption content) in the sei_rbsp (specifically a DTG1 payload preceding a GA94 payload) fail to display captions in this scenario, as the current logic results in parseSei() prematurely returning with the DTG1 payload.
By checking for the user ID within parseSei, mux.js can continue iterating through the sei_rbsp for the GA94 payload.