Bug in HLS SUPPLEMENTAL-CODECS support #6586
Labels
component: HLS
The issue involves Apple's HLS manifest format
priority: P1
Big impact or workaround impractical; resolve before feature release
status: archived
Archived and locked; will not be updated
type: bug
Something isn't working correctly
Milestone
Have you read the FAQ and checked for duplicate open issues?
Yes
If the problem is related to FairPlay, have you read the tutorial?
Not related
What version of Shaka Player are you using?
4.8.3
Can you reproduce the issue with our latest release version?
Yes
Can you reproduce the issue with the latest code from
main
?Yes
Are you using the demo app or your own custom app?
Both, demo app and custom app.
If custom app, can you reproduce the issue using our demo app?
Yes
What browser and OS are you using?
LG WebOS 23, Web Engine is Chromium 94.
For embedded devices (smart TVs, etc.), what model and firmware version are you using?
LG C2 TV
What are the manifest and license server URIs?
Using a basic clear HLS manifest with SUPPLEMENTAL-CODECS attribute.
What configuration are you using? What is the output of
player.getConfiguration()
?Default config
What did you do?
Tried playing a HLS stream which includes SUPPLEMENTAL-CODECS attribute (DolbyVision Profile8.1 video) on a LG TV. Even though this LG-TV supports Dolby Vision Profile8.1, shaka player playback fails with the following error: MEDIA.VIDEO_ERROR (4,,CHUNK_DEMUXER_ERROR_APPEND_FAILED:Video stream codec dolbyvision doesn't match SourceBuffer codecs.)
What did you expect to happen?
I expect Dolby Vision codec is prioritised for playback and the video is played as Dolby Vision on the TV. This feature was added recently (#6155), but it did not work on my end.
What actually happened?
Playback fails with the following error: MEDIA.VIDEO_ERROR (4,,CHUNK_DEMUXER_ERROR_APPEND_FAILED:Video stream codec dolbyvision doesn't match SourceBuffer codecs.)
I did some debugging and found that chooseBetterCodecs_ (/lib/media/segment_utils.js) never prioritizes DolbyVision codec-id even that is supported by the device. This is because an incorrect "const type" value is sent to mediacapability query in "chooseBetterCodecs_". That causes mediacapability query to return always false and chooseBetterCodecs_ to prioritize incorrect codec-id.
Are you planning send a PR to fix it?
I believe there is a typo in setting the value of "const type" that is used for mediacapability query. I tried with below fix and it worked. I can send a PR. Please let me know if this is needed.
Original Code (/main/lib/media/segment_utils.js, line473):
const type =
video/mp4; codecs="${dolbyVision}"'
;Fixed Code (/main/lib/media/segment_utils.js, line473):
const type =
video/mp4; codecs="${dolbyVision}"
;The text was updated successfully, but these errors were encountered: