Skip to content
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

fix: Fix green screen issue on Edge with mixed content #6719

Merged
merged 15 commits into from
Jun 7, 2024

Conversation

tykus160
Copy link
Member

On Edge, to properly play mixed content, we need to insert init segment twice for clear part - once as encrypted, and immediately again as clear. Otherwise we may encounter green screen and errors from video decoder.

@avelad avelad added type: bug Something isn't working correctly priority: P2 Smaller impact or easy workaround platform: Windows Issues affecting Windows browser: Edge Issues affecting Microsoft Edge (any version) labels May 31, 2024
@avelad avelad added this to the v4.10 milestone May 31, 2024
@avelad avelad requested a review from joeyparrish May 31, 2024 09:21
@shaka-bot
Copy link
Collaborator

shaka-bot commented May 31, 2024

Incremental code coverage: 95.16%

@joeyparrish
Copy link
Member

On Edge, to properly play mixed content, we need to insert init segment twice for clear part - once as encrypted, and immediately again as clear. Otherwise we may encounter green screen and errors from video decoder.

The latest Edge (for several years) is based on Chromium, so this shouldn't be an issue on desktops. Is there a particular platform that has a legacy version of Edge that has this problem? This is the case on our Xbox, for example.

@tykus160
Copy link
Member Author

tykus160 commented Jun 3, 2024

@joeyparrish unfortunately is is the issue even on current Edge Chromium when using PlayReady.

@avelad
Copy link
Member

avelad commented Jun 3, 2024

@joeyparrish unfortunately is is the issue even on current Edge Chromium when using PlayReady.

If Widevine is used, it doesn't happen?

@tykus160
Copy link
Member Author

tykus160 commented Jun 3, 2024

@avelad yes, it seems we don't need this workaround when Widevine is used.

@avelad
Copy link
Member

avelad commented Jun 3, 2024

@avelad yes, it seems we don't need this workaround when Widevine is used.

So, this should be taken into account in the code, because right now it applies to ClearKey, PlayReady and Widevine.

tykus160 and others added 13 commits June 3, 2024 11:27
This makes it more feasible to debug and fix transmuxer bugs or other segment append failures.

Closes shaka-project#6712
For some reason on PS4, the check `val.buffer.constructor == ArrayBuffer` returns `false` when it should be `true` which causes the object cloning to return `null` instead of the array buffer.

Modifying this to `val.buffer instanceof ArrayBuffer` now returns true which fixes the issue. This should work across devices.
Original author: @nick-michael

Co-authored-by: Nick Michael <nick-michael@users.noreply.github.com>
MockAdManager did not define setVolume() in this one test, causing the
test to throw an exception. This exception got swallowed and did not
fail the test, but was noticed in the JS console during a Karma debug
run.
@avelad
Copy link
Member

avelad commented Jun 6, 2024

@joeyparrish can you review it again? Thanks!

@joeyparrish joeyparrish merged commit d5b1863 into shaka-project:main Jun 7, 2024
14 of 15 checks passed
avelad added a commit that referenced this pull request Jun 11, 2024
On Edge, to properly play mixed content, we need to insert init segment twice for clear part - once as encrypted, and immediately again as clear. Otherwise we may encounter green screen and errors from video decoder.

Co-authored-by: Joey Parrish <joeyparrish@users.noreply.github.com>
Co-authored-by: Nick Michael <nick-michael@users.noreply.github.com>
Co-authored-by: Álvaro Velad Galván <ladvan91@hotmail.com>
Co-authored-by: Casey Occhialini <1508707+littlespex@users.noreply.github.com>
@tykus160 tykus160 deleted the wt-edge-mixed branch June 11, 2024 13:32
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Aug 6, 2024
@shaka-project shaka-project locked as resolved and limited conversation to collaborators Aug 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
browser: Edge Issues affecting Microsoft Edge (any version) platform: Windows Issues affecting Windows priority: P2 Smaller impact or easy workaround status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants