SSA/ASS embedded fonts don’t work unless ass_set_fonts is called after they’re parsed #266
Comments
|
TBH I didn't realize embedded fonts were actually a thing anyone used. But this seems like it should be easy enough to fix, so w/e. |
|
Wanted to check the status on this since there hasn't been any updates posted in a while |
TheOneric
added a commit
to TheOneric/libass-regression-tests-tmp
that referenced
this issue
Oct 27, 2020
As compare can't yet deal with embedded font, this test is currently disabled. See: libass/libass#266 The sample image was produced with mpv and some image editing.
TheOneric
added a commit
to TheOneric/libass-regression-tests-tmp
that referenced
this issue
Oct 27, 2020
As compare can't yet deal with embedded font, this test is currently disabled. See: libass/libass#266 The sample image was produced with mpv and some image editing.
TheOneric
added a commit
to TheOneric/libass-regression-tests-tmp
that referenced
this issue
Mar 5, 2021
to transition to git-lfs and get rid of old binaries in git history.
Images and fonts are now sotred in LFS.
Previous master history is retained in new branch 'oldmaster'.
Regression Tests:
- Karaoke tests for libass/#216 and libass/#357
- Image draw regression test
- Test for regression reported at mpv/#7712
- Implicit positioning tests
- SBAS default test
- Zero Area Events
- Embedded font test (disabled,
due to libass/libass#266 )
Crash tests:
- Aegisub's format test
- Some thrown-toegether file which tires to cover many codepaths
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 26, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 26, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 26, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 27, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 27, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
TheOneric
added a commit
to TheOneric/libass
that referenced
this issue
Mar 27, 2021
Previously only both only worked when ass_set_fonts was called after all embedded and memory fonts were already added. Especially for embedded fonts this meant it won't work for most users, including our own utilities, even if extract_fonts was set, except for mpv who happened to have the "right" callorder. Now that it works, enable extract_fonts in our utilities. GitHub: fixes libass#266, fixes libass#98
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Embedded fonts are set aside during parsing and imported into fontselect later in
process_fontdata, called only fromass_embedded_fonts_add_provider, called only fromass_fontselect_init, called only fromass_set_fonts. So embedded fonts are unavailable untilass_set_fontsis called. But it’s usually called before embedded fonts are parsed, so embedded fonts don’t work!This breaks embedded fonts in external subtitle files in VLC and FFmpeg’s vf_subtitles (which use
ass_process_codec_privateto parse the whole file exceptDialoguelines: VLC, FFmpeg), Kodi, MPlayer, mplayer2 (which useass_read_memoryto read the whole file), FFmpeg’s vf_ass and ourtestutility (which useass_read_fileto read the whole file). (Note: MPlayer’s internal copy of libass, which is used if a system libass is not found or is too old, is a copy from 2013. I don’t know how it behaves.)Embedded fonts work in mpv, because it calls
ass_set_fontsafter callingass_process_codec_privateto parse the whole file exceptDialoguelines (as parsed by FFmpeg).The text was updated successfully, but these errors were encountered: