Skip to content
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

Load only required fallback fonts for ASS subtitles, instead of preloading them all #5960

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

p0358
Copy link
Contributor

@p0358 p0358 commented Aug 25, 2024

!! Requires this PR to be merged: jellyfin/jellyfin#12511

Changes

Currently the way fallback fonts work is that they load all the fonts into browser before starting playback (up to the arbitrary 20 MB limit), which for obvious reasons sucks. Subtitle Octopus library has a feature where you can define a map of font family to URL to have it only load the required fonts used by particular .ASS file on-demand instead of preloading them all and then figuring out what's gonna be used, which is infinitely better.

Depicted below loading only the few required fonts instead of hundreds:
obraz

Issues

Copy link

@thornbill thornbill added enhancement Improve existing functionality or small fixes backend Requires work on the server to finish labels Aug 25, 2024
It used to be limited to 20 MB total previously. We cannot easily limit total size of fonts anymore, so the least we can do is to keep the size of a single font file in check.
Copy link

@jellyfin-bot
Copy link
Collaborator

Cloudflare Pages deployment

Latest commit d821ad3562a55c028fbe3342e821ee31cfc09f83
Status ✅ Deployed!
Preview URL https://e2b5d835.jellyfin-web.pages.dev
Type 🔀 Preview

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Requires work on the server to finish enhancement Improve existing functionality or small fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants