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

Bugfix/hardware accelerated decoding apple silicon #4412

Conversation

lpommers
Copy link
Contributor

@lpommers lpommers commented Nov 4, 2021

This PR will...

stop removing the start delimiter bytes from the PES packet during demuxing if they overlap.

Why is this Pull Request needed?

This PR is needed because hardware accelerated decoding on Apple Silicon cannot properly decode the MPEG-TS stream when it has been manipulated in this manner.

Are there any points in the code the reviewer needs to double check?

  1. I looked into the original issue for the addition of this conditional statement and all the test streams from that issue are no longer valid. Streams created by Apple's mediafilesegmenter do not play #98. However, I did create several mediafilesegmenter streams to try and reproduce the original issue using an Intel Mac. I don't believe I was successful.
  2. I added the test stream from the original issue to be included here. However, because the issue was only impacting Apple Silicon, where the automated tests are executed from would impact if the tests fail before this change is introduced. Reviewers with M1/pro/max Apple chips can add back in the changes from tsdemuxer.ts and will see the specs fail. I've also tried to document that fact in the test stream description.

I spoke with @mangui about trying to see if this change would solve the issue which led to this conditional being added, but without access to those broken streams, I was unable to fully do so. There is a comment (#3834 (comment)) from my bug report showing my inability to find this conditional being useful today.

Resolves issues:

#3834

Checklist

  • changes have been done against master branch, and PR does not conflict
  • new unit / functional tests have been added (whenever applicable)
  • API or design changes are documented in API.md

@lpommers lpommers force-pushed the bugfix/hardware-accelerated-decoding-apple-silicon branch 2 times, most recently from 966af9a to 90df4bf Compare November 8, 2021 19:32
lpommers added a commit to wistia/hls.js that referenced this pull request Nov 10, 2021
…on chips.

See more at video-dev#4412, where this is going to be merged into the main project
src/demux/tsdemuxer.ts Outdated Show resolved Hide resolved
@lpommers lpommers force-pushed the bugfix/hardware-accelerated-decoding-apple-silicon branch from 4e5fd2b to 887bf2e Compare December 3, 2021 21:39
@robwalch robwalch merged commit b48fcc0 into video-dev:master Dec 3, 2021
@robwalch robwalch added this to the 1.1.2 milestone Dec 6, 2021
@robwalch robwalch added the Bug label Dec 6, 2021
littlespex pushed a commit to cbsinteractive/hls.js that referenced this pull request Dec 9, 2022
Without an explicit size, some platforms render bitmap-based cues as
0x0.  This effect was seen in Chrome on Mac in particular.  This
started with PR video-dev#4412, where we factored out regions into their own
element.

The TTML spec says that background images should fill their associated
region, so this fixes the issue by making the div explicitly the size
of its parent element (100% x 100%).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants