Commit Graph
56 Commits
Author SHA1 Message Date
Dean 31334d2233 Merge pull request #12870 from legendary-cookie/test/font-writing-metrics
test(libSceFont): cover sceFontWritingGetRenderMetrics and sceFontWritingSetMaskInvisible
2026-11-03 05:14:54 +13:00
Dean 1c4c0d766c Merge pull request #12869 from legendary-cookie/test/font-text-character
test(libSceFont): cover sceFontCharacterGetTextFontCode and sceFontCharacterGetTextOrder
2026-11-03 05:14:48 +13:00
Dean 9cb31b4401 Merge pull request #12757 from legendary-cookie/test/font-library-lookups
test(libSceFont): cover sceFontGetLibrary and sceFontSetFontsOpenMode
2026-11-03 02:39:44 +13:00
Dean c723bc74fc Merge pull request #12201 from MarcZX10/fix/font-external-fonts-context-size-overflow
fix(libSceFont): reject an external font count whose context size overflows 32 bits
2026-11-03 01:29:44 +13:00
legendary cookieandClaude Opus 5.5 e584de3602 test(libSceFont): cover sceFontGetLibrary and sceFontSetFontsOpenMode
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-30 21:28:23 +08:00
legendary cookieandClaude Opus 5.5 0c87377db3 test(libSceFont): cover sceFontWritingGetRenderMetrics and sceFontWritingSetMaskInvisible
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-29 20:29:35 +08:00
legendary cookieandClaude Opus 5.5 28d058cad1 test(libSceFont): cover sceFontCharacterGetTextFontCode and sceFontCharacterGetTextOrder
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-29 20:29:34 +08:00
legendary cookieandClaude Opus 5.5 b2f3eabbb3 test(libSceFont): cover the renderer outline buffer size, reset and policy
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-28 19:18:20 +01:00
Dean 871517aaee Merge pull request #11521 from Lindamea1/fix/font-writing-non-owning
fix(libSceFont): stop a font writing from owning its string's characters
2026-10-28 22:02:06 +13:00
Adrià 7fe69e276f Merge pull request #11707 from milescoviello/test/font-terminate-code
test(libSceFont): cover the terminate code and position a font string records
2026-10-28 05:04:26 +01:00
MarcZX10 858eb3080e test(libSceFont): support external fonts with a count that wraps the context size
0x04000000 and 0xffffffff have to be rejected as invalid parameters, and the
supported count of 4 still succeeds afterwards.
2026-10-28 03:06:53 +00:00
Lindamea1andClaude Opus 5.5 ac682a4064 fix(libSceFont): stop a font writing from owning its string's characters
sceFontWritingInit took a reference on the string's host character
storage and kept it in the caller's SceFontWriting bytes. Only a later
sceFontWritingInit on the same, unchanged bytes dropped it, so every
string drawn with a fresh, zeroed or overwritten writing leaked its
characters, and re-initialising both copies of a copied writing dropped
its one reference twice. A SceFontWriting has no teardown export, so it
is plain caller memory and cannot own anything.

sceFontCreateString now allocates the characters through the string's
FontMemory, as it already did the string, so no character pointer the
guest receives points into host memory. sceFontDestroyString clears
the string's magic and frees both, and a failed create clears it before
freeing the string. A writing keeps only a pointer to its string and
checks the magic on every step, so after the destroy its steps return
null unless that memory holds the magic again, as when a new string is
allocated there. An init that fails after resetting the writing still
leaves it stepping nothing.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-27 09:00:33 +00:00
milescovielloandClaude Opus 5.5 a265527c4d test(libSceFont): cover the terminate code and position a font string records
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-27 04:19:46 +00:00
milescovielloandClaude Opus 5.5 106048ef94 test(libSceFont): cover the render effect slant and weight setters against their getters
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-26 22:59:16 +00:00
AZLisme 0afde4ec7c fix(libSceFont): exhaust characters within a writing step 2026-10-25 18:13:22 +08:00
klosixgaming-arch 0e46a0c497 fix(libSceFont): resolve a default string direction at creation
A string created from a text source in the default horizontal form (0x10)
reported 0x10. TEKKEN: DARK RESURRECTION (PPSA31371) passes the reported form
to sceFontCreateWritingLine, which only accepts 0x11 and 0x12, so the call
failed and the layout width was 0.

On firmware 13.42 sceFontCreateString decides the direction for a default-form
source and sceFontStringGetWritingForm returns the stored form. The string
gets 0x12 when its first strong character is left to right, 0x11 when it is
right to left, and 0x12 when it has none. Left-to-right and right-to-left marks
count as strong, embeddings and overrides do not, and text between an isolate
initiator and its PDI is skipped. Explicit 0x11 and 0x12 sources keep their
form.

The test follows the table reported on the pull request. Which characters are
strong is decided by Unicode block ranges here, not by the full bidi class
tables.
2026-10-24 19:21:23 -05:00
boykopovar f38d29fd08 refactor(sdk): add canonical headers for remaining libraries 2026-10-24 23:17:42 +03:00
Dean ca6fbf762c Merge pull request #8633 from vittoriosalvadore/codex/fix-font-point-dpi-scales
fix(libSceFont): use current style for glyph and kerning scales
2026-10-24 09:13:36 +13:00
Dean 560e0c4a55 Merge pull request #9428 from MarcZX10/feat/fontft-truetype-gx-probe
feat(libSceFontFt): report TrueType GX support
2026-10-23 12:58:59 +13:00
Dean a661d12e30 Merge pull request #8375 from orezraey/fix/font-system-fonts-wide-env
fix(libSceFont): open fonts and the system font directory under non-ASCII paths on Windows
2026-10-23 08:54:15 +13:00
MarcZX10 173603428d feat(libSceFontFt): report TrueType GX support 2026-10-21 21:44:31 +00:00
boykopovar 350c6eb323 fix(font): restore typography validation and reject unsupported shaping 2026-10-21 21:56:03 +03:00
boykopovar 34123d4e29 fix(font): restore encoded glyph identifiers and validation 2026-10-21 21:54:23 +03:00
boykopovar 512ae7f80f fix(font): use 32-bit resolution in driver callbacks 2026-10-21 21:54:22 +03:00
boykopovar 5f980378c4 fix(font): restore device cache ownership and detach outputs 2026-10-21 21:54:22 +03:00
boykopovar 10829db69f fix(font): validate script and language selection 2026-10-21 21:51:25 +03:00
boykopovar 86c1daddde fix(font): match pixel resolution validation and locking 2026-10-21 21:50:05 +03:00
boykopovar cfbff67da6 fix(font): implement glyph attribute transitions and output 2026-10-21 21:50:05 +03:00
boykopovar 41e386a495 fix(fontft): restore library arguments and validate format queries 2026-10-21 21:49:59 +03:00
orezraeyandClaude Opus 5.5 c909d51447 test(libSceFont): open the external font through a guest path alias
sceFontOpenFontFile resolves guest paths, so a host-absolute temporary
path resolved beneath the run directory on Linux.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-21 06:55:03 -03:00
maximaxi01 f956527f67 fix(libSceFont): use current style for glyph and kerning scales 2026-10-20 15:16:58 -04:00
Dean 52f7807a55 Merge pull request #6581 from Thomas73737/feat/libscefont-words
feat(libSceFont): implement handle and glyph attributes
2026-10-21 02:43:40 +13:00
orezraeyandClaude Opus 5.5 2d1a3e5187 fix(libSceFontFt): map font files through CreateFileW as FreeType's Windows stream does
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-20 09:22:14 -03:00
orezraeyandClaude Opus 5.5 162a705447 fix(libSceFont): open fonts and the system font directory under non-ASCII paths on Windows
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-20 08:42:54 -03:00
Adrià 456f8513bc Merge pull request #6400 from Capmare/feat/fontft-support-formats
feat(libSceFontFt): implement the font format support exports
2026-10-19 01:57:51 +02:00
Adrià 0bc3003f89 Merge pull request #6282 from Ondra97/codex/fix-font-face-lifetime
fix(font): serialize shared FreeType face lifetime
2026-10-18 23:27:19 +02:00
Thomas Abdelmalak 8aea41b5cc test(libSceFont): assert attributes are isolated per handle and per glyph 2026-10-18 14:25:29 +03:00
Thomas Abdelmalak ce4a1dc054 feat(libSceFont): implement handle and glyph attributes 2026-10-18 13:23:28 +03:00
capmare 2be7b0769a feat(libSceFontFt): implement the font format support exports 2026-10-15 16:30:32 +02:00
Ondra97 7cdb99763d fix(font): serialize shared FreeType face lifetime 2026-10-15 10:46:49 +02:00
KernelPanicNTandClaude Opus 5.5 cf762829d1 feat(libSceFont): implement sceFontCharactersRefersTextCodes and text code stepping
sceFontCharactersRefersTextCodes fills a 64-byte FontTextCodes with the
order and code of a text character and keeps the current, start and
term characters at +0x28, +0x30 and +0x38. The traversal follows the
PS4 11.00 libSceFont.sprx disassembly posted in the review of #4050,
which implemented the same rules: Refers never compares the character
with the term and returns null for a clustered or synthetic character,
sceFontTextCodesStepNext returns null at the term after visiting it,
sceFontTextCodesStepBack returns null at the start character, and both
steps skip synthetic characters. Null from StepNext at the end of the
chain and from StepBack at the head of the chain is assumed and not
covered by the report.

The signatures follow Orbital's IDA type database and SharpProspero. A
null cursor or output returns null as in KytyPS5; a null text character
throws. guest_font_tests gets configure_windows_unwind so the expected
exception reaches the test on Windows.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-14 18:44:41 +00:00
Adrià 9ce99f8f4d Merge pull request #3697 from JAB-dev/fix/font-writing-letter-step
fix(libSceFont): return the letter step of sceFontWritingRefersRenderStepCharacter through a pointer
2026-10-11 23:52:50 +02:00
Adrià 6fa58ec0ac Merge pull request #3696 from JAB-dev/feat/font-syllable-string-state
feat(libSceFont): implement sceFontCharacterGetSyllableStringState
2026-10-11 23:52:45 +02:00
Santhosh Kumar 17827dd9ab fix(filesystem): reject invalid parent traversal on Windows 2026-10-12 01:25:02 +05:30
JAB-devandClaude Sonnet 5.5 e127a525d1 feat(libSceFont): implement sceFontCharacterGetSyllableStringState
The call was an unimplemented stub. It now writes syllable state 0 and
returns OK for every character outside the Thai block, where a PS4
firmware 11.00 libSceFont measures 1, 3 or 4; Thai characters throw as
not implemented. A null character or result returns
SCE_FONT_ERROR_INVALID_PARAMETER, and a null character writes 0 to a
non-null result, as measured. The signature follows SharpProspero.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-11 17:32:23 +02:00
JAB-devandClaude Sonnet 5.5 b576273225 fix(libSceFont): return the letter step of sceFontWritingRefersRenderStepCharacter through a pointer
The second argument is an out pointer to the writing's letter step, as
KytyPS5 and the SharpProspero bindings declare it. It was filled as a
letter step struct, which wrote 64 bytes over the caller's 8-byte
pointer. The letter step now lives in the writing and the call stores
its address, or null when there is no current step.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
2026-10-11 17:12:47 +02:00
Abdulrahman Elkordy 5ea89c7d4c feat(font): keep a handle's script languages and typographic features
sceFontSetScriptLanguage, sceFontGetScriptLanguage,
sceFontSetTypographicDesign and sceFontGetTypographicDesign threw. With
the signatures SharpProspero declares, a font handle now keeps the
language set for each script and the feature set for each typographic
design, under the handle's lock, and returns them, with 0 for one never
set. They do not change shaping or rendering yet; TechnicalDebt records
the assumptions.

Claude-Session: https://claude.ai/code/session_012SLQbhAiexxW6TtjYToW8a
(cherry picked from commit c4dcbe4403dc635fde2a823dec311a939816cefc)
2026-10-11 01:03:52 +02:00
Samuel Jean c62da4004e test(font): isolate guest_font system font lookup 2026-10-10 21:20:29 +13:00
camezaro-intc 327201519a feat(font): implement sceFontDettachDeviceCacheBuffer
Detach the device cache buffer attached by sceFontAttachDeviceCacheBuffer. The signature is taken from the IDA type database of Orbital: it takes the library, a pointer to receive the buffer and a pointer to receive its size. When no cache buffer is attached, it reports NOT_ATTACHED_CACHE_BUFFER. If the library allocated the buffer itself and no buffer pointer is passed, the memory is freed. The owned bit is cleared and device_cache_buf is reset to null.
2026-10-08 00:36:52 -06:00
Raihan Abdul MajidandClaude Opus 5.5 0a6a8a7b5c feat(font): accept sceFontGlyphDefineAttribute as a silent stub
PPSA01325 stops on sceFontGlyphDefineAttribute right after generating a character glyph: it sets attribute 0x11 to 0 on that glyph, deletes it without using it, and draws the character with sceFontRenderCharGlyphImageHorizontal. The meaning of the attributes is unknown, so the call checks the glyph and ignores the rest; TechnicalDebt lists it under silent stubs.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01UTjpbMX7BUFMZZaxJE98zV
2026-10-07 22:46:48 +07:00