feat: add feature-flag to insert fake encryption in init segments on broken platforms #5561
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When controlling the content we're playing from one end to another, we don't need to do the extra check for working around broken platforms (parsing mp4 boxes to find encryption, insert one if there isn't if the content is encrypted).
On a Tizen 5.0, the check without having to append the fake encryption takes between 5 to 10ms to complete. Time that is added to the launch time, or the time needed to seek if there is a downgrade for seeking.
That's not much, but when having a start time of 1000ms, that's still at best 1% we can shave off 😅
Tests
I did the tests by adding a bit of code, taking care to remove any logs in MP4Parser that are taking a huge time (with logs, we're more on a 100~200ms scale).