fix(prx): implement sceFontSupportGlyphs and the Ft glyph-selection record #16640
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/16640"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by akkadbakkad89 on 2026-11-07T11:54:12Z.
What
Implements two decoded contracts across
libSceFontandlibSceFontFt, verified against the PS5 4.03 module disassembly (ps5_prx_dump_403):sceFontSelectGlyphsFt— returns the static 8-byte record0x0F1F, 0xF200, 0x0F03, 0xF8F0(u16s) for selector 0, null otherwise. The record bytes are taken verbatim from the module's data segment.sceFontSupportGlyphs— u16 tag checks (0x0F1Fat 0 →INVALID_PARAMETER,0x0F03at 4 →FATAL), then under a global lock stores the table in the first free of two slots and counts it. Both slots holding other tables returns 0; a table already registered returns 0 without releasing the lock (the firmware bug is replicated — the next call spins).This PR previously also implemented
sceFontSupportSystemUpdationandsceFontOutlineVertexesInterfaceInit; upstream landed equivalent implementations of both ina6b15fb1(PS4 10.71 decode confirmed on PS5 13.42 by BunnyFl, #14879), so they were dropped on rebase.sceFontFtSupportSystemFontswas already landed upstream (identical{"cff", "truetype"}module list — the PS5 body is the same code assceFontFtSupportOpenType), so this PR only adds the debt-note verification for it.Not implemented (still throws, debt updated):
sceFontFtSupportFontFormats— its PS5 4.03 body is fully decoded (mask builder + importedFTA_Support_Modules@oM0zMNCfXKMinlibSceFreeTypeOt), but what each mask bit selects inside that callee was not read.sceFontGetCharVariationGlyphCode— lookup internals unread and absent from the 4.03 module.Tested
guest_font_supporttest exe against the built.prxfiles: SelectGlyphsFt selector/table tags, SupportGlyphs tag errors + two-slot registry + full + duplicate-quirk ordering. The SupportSystemUpdation/OutlineVertexesInterfaceInit cases previously in this test are covered by upstream'sguest_font_interface_contractsand were removed. Neighboring suites (guest_font,guest_font_interface_contracts,font_render_surface,guest_font_ft_*) still pass. Windows 11, MinGW build; all checks pass.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)