Skip to content

Add Format.selectionPriority and parse from HLS SCORE#3236

Merged
copybara-service[bot] merged 6 commits into
androidx:mainfrom
AndyWangLYN:heyuwang/hls-score-selection-priority
Jun 12, 2026
Merged

Add Format.selectionPriority and parse from HLS SCORE#3236
copybara-service[bot] merged 6 commits into
androidx:mainfrom
AndyWangLYN:heyuwang/hls-score-selection-priority

Conversation

@AndyWangLYN

@AndyWangLYN AndyWangLYN commented May 24, 2026

Copy link
Copy Markdown

Summary

Adds Format.selectionPriority and populates it from the HLS SCORE attribute on EXT-X-STREAM-INF /
EXT-X-I-FRAME-STREAM-INF.

Extraction-only — no selection behavior changes in this PR

Spec

draft-pantos-hls-rfc8216bis-22 §4.4.6.2
(SCORE on EXT-X-STREAM-INF), §4.4.6.3 (inherits to EXT-X-I-FRAME-STREAM-INF), §6.3.1 (client behavior).

Testing

  • ./gradlew :lib-common:test
  • ./gradlew :lib-exoplayer-hls:connectedAndroidTest
  • git diff -U0 main... | google-java-format-diff.py -p1 -i

@AndyWangLYN AndyWangLYN changed the title Common: add Format.selectionPriority and parse HLS SCORE Add Format.selectionPriority and parse HLS SCORE May 24, 2026
@AndyWangLYN AndyWangLYN marked this pull request as ready for review May 24, 2026 07:02
@AndyWangLYN AndyWangLYN changed the title Add Format.selectionPriority and parse HLS SCORE Add Format.selectionPriority and parse from HLS SCORE May 24, 2026

@tianyif tianyif left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution! The PR looks good to me. I just left one comment on the plan of same support for DASH, and you don't have to address it in this PR.

I'm going to send this for internal review now. You may see some more commits being added as I make changes in response to review feedback. Please refrain from pushing any more substantive changes as it will complicate the internal review.

* more preferred format, or {@link #NO_VALUE} if unset.
*
* <p>Populated from the HLS {@code SCORE} attribute on {@code EXT-X-STREAM-INF} and {@code
* EXT-X-I-FRAME-STREAM-INF}, and from the DASH {@code @selectionPriority} attribute on {@code

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you plan to have a similar PR for DASH as well?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for reviewing! Yes I do have a local draft PR for DASH support (hence the comment about dash in code as well), which I plan to raise later today since this PR looks good to you. Separated them for easy review. Will tag this PR when I raise the dash one. Thanks!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good. To keep the current PR clean for HLS, I will alter this javadoc a bit without mentioning DASH, you can add it back in the next PR for DASH.

@tianyif tianyif force-pushed the heyuwang/hls-score-selection-priority branch from 8946a7c to 08bedc8 Compare June 10, 2026 14:19
@tianyif tianyif force-pushed the heyuwang/hls-score-selection-priority branch 2 times, most recently from cbe44ce to a1937d9 Compare June 11, 2026 16:14
@tianyif tianyif force-pushed the heyuwang/hls-score-selection-priority branch from a1937d9 to a738942 Compare June 12, 2026 14:16
@copybara-service copybara-service Bot merged commit 7c28212 into androidx:main Jun 12, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants