Skip to content

fix(player): render layered bilingual ASS subtitles - #57

Merged
ModerRAS merged 1 commit into
masterfrom
fix/bilingual-subtitle-rendering
Jul 31, 2026
Merged

fix(player): render layered bilingual ASS subtitles#57
ModerRAS merged 1 commit into
masterfrom
fix/bilingual-subtitle-rendering

Conversation

@ModerRAS

@ModerRAS ModerRAS commented Jul 31, 2026

Copy link
Copy Markdown
Owner

Summary

  • upgrade Media3 from 1.3.1 to 1.8.0 for ASS/SSA Layer and cue z-order support
  • use Media3 1.8 native effects renderer and remove obsolete PreviewingVideoGraph wiring
  • update the Media3 analytics callback signature

Verification

  • ./gradlew test lint
  • ./gradlew :app:assembleDebug
  • HK1 real-device playback with a stream-copy clip from Lv999 no Murabito - 01 [ASSx2].mkv
  • STANDARD_EXO selected 简日双语 and rendered simultaneous Chinese and Japanese dialogue cues

Version

Patch-level bug fix. Latest stable release is v2.4.623 and the local base is already 2.4.0, so baseAppVersionName is unchanged; CI will assign the next patch.

Summary by CodeRabbit

  • New Features

    • Updated the media playback engine to a newer version.
    • Improved compatibility with updated video playback callbacks.
    • Continued support for experimental video effects across playback modes.
  • Bug Fixes

    • Simplified video rendering behavior for more reliable playback.
    • Removed obsolete HDR/SDR preview processing that could affect video output.

@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 4cfd9fb3-eccb-4f2c-b75f-d6eed59c17ff

📥 Commits

Reviewing files that changed from the base of the PR and between 7e66bdd and 67daab3.

📒 Files selected for processing (6)
  • gradle/libs.versions.toml
  • player-core/src/main/kotlin/com/miruplay/tv/player/DiModule.kt
  • player-core/src/main/kotlin/com/miruplay/tv/player/ExoPlaybackController.kt
  • player-core/src/main/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactory.kt
  • player-core/src/main/kotlin/com/miruplay/tv/player/ExperimentalRenderersFactory.kt
  • player-core/src/test/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactoryTest.kt
💤 Files with no reviewable changes (2)
  • player-core/src/main/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactory.kt
  • player-core/src/test/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactoryTest.kt

📝 Walkthrough

Walkthrough

The update raises Media3 from 1.3.1 to 1.8.0, updates a callback signature, and removes previewing video graph creation. MEDIA3_EFFECTS mode now uses the default Media3 renderer.

Changes

Media3 video pipeline update

Layer / File(s) Summary
Media3 API compatibility
gradle/libs.versions.toml, player-core/src/main/kotlin/com/miruplay/tv/player/ExoPlaybackController.kt
The Media3 version changes to 1.8.0. onVideoInputFormatChanged accepts the nullable decoder reuse evaluation parameter.
Renderer pipeline simplification
player-core/src/main/kotlin/com/miruplay/tv/player/ExperimentalRenderersFactory.kt, player-core/src/main/kotlin/com/miruplay/tv/player/DiModule.kt, player-core/src/main/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactory.kt, player-core/src/test/kotlin/com/miruplay/tv/player/ExperimentalHdrSdrVideoGraphFactoryTest.kt
PreviewingVideoGraph and compositing sink dependencies are removed. MEDIA3_EFFECTS mode retains the default renderer. Other modes use the experimental HDR surface renderer. Obsolete HDR/SDR graph resolution code and tests are removed.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the main bug fix: rendering layered bilingual ASS subtitles.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/bilingual-subtitle-rendering

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@ModerRAS
ModerRAS merged commit 91dccbc into master Jul 31, 2026
7 checks passed
@ModerRAS
ModerRAS deleted the fix/bilingual-subtitle-rendering branch July 31, 2026 14:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant