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 edge-case in main audio-only with track descriptions #2943
Fix edge-case in main audio-only with track descriptions #2943
Conversation
@@ -169,6 +169,7 @@ <h3> | |||
</p> | |||
<p> | |||
<span> | |||
<button type="button" class="btn btn-xs btn-default" onclick="$('#streamSelect')[0].selectedIndex++;$('#streamSelect').change()">Next video</button> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a big fan of inline html event handlers, but this is just personal opinion, and I see we do it all over.
Maybe add to the demo js file as util method?
Easier for linters and other tools to pick up on things.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just something quick and dirty for now to speed up running manual tests on all test streams in the demo page. The button should be next to the select menu, no inline html js, ditch jQuery... all the nice to haves.
'abr': false | ||
url: 'https://test-streams.mux.dev/bbbAES/playlists/sample_aes/index.m3u8', | ||
description: 'SAMPLE-AES encrypted', | ||
live: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Delete live?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that's the default. This streams no up anymore though, so this comment is more a reminder that we are missing a Sample-AES test stream.
'blacklist_ua': ['safari', 'internet explorer'] | ||
url: 'https://storage.googleapis.com/shaka-demo-assets/angel-one-hls/hls.m3u8', | ||
description: 'HLS fMP4 Angel-One multiple audio-tracks', | ||
abr: true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ABR was false before, did you mean to put true?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this stream has multiple variants. It was probably set to false to skip tests. If the smooth switch test fails on this stream, I want to know.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I added some (nitpicking) comments.
In general I think we should separate between general maintenance PRs for better maintainability.
Ok, I see that one of the functional tests is failing. Is this due to the change or it is a flaky one? |
@OrenMe. I'm re-running that job. I couldn't reproduce the issue locally. That is probably one of the streams that didn't have |
This PR will...
abr
propertiesWhy is this Pull Request needed?
When playing a stream with variants whose audio is described in MEDIA tracks (with no alt audio), the audio-stream-controller will trigger track change events on level switch. This has the unintended side-effect of making the stream-controller flush all audio in
onAudioTrackSwitching
. Unfortunately this flush command may prevent the init segment for the new audio variant from being appended. In the case where the audio sample rate changes between variants this can be very bad, since buffer appends of the new variant will be treated as if they used the old sample rate and audio will not be appended at the correct location with the expected duration.Are there any points in the code the reviewer needs to double check?
Are there any scenarios where we would still need to flush the audio buffer when switching from main to main audio on track switch?
Resolves issues:
#2837
Checklist