Repository navigation
feat(libSceFreeType): query exact outline curve bounds - #9802
oneandonlydean merged 10 commits into
Conversation
|
@Ondra97 This implements Proposed documentation order: #9802 first, then #9329 retains the curve-bounds entry when rebasing. There is no code/build dependency. If #9329 lands first, I will rebase this PR and place its debt entry alongside yours instead. Please let me know if another order works better. The final Windows full build and 4/4 focused checks passed, including the large-coordinate overflow regression and 8,192 generated curves. |
|
@santhoshkumar-dev I agree with #9802 first, then #9329. I compared both current diffs: the shared change is the insertion under Functional in docs/dev/debt/libSceFreeType.md; the transform and curve-bounds implementations and tests are separate. I have recorded #9802 on the Depends on line in #9329 as documentation merge order. After #9802 lands, I will rebase #9329 and retain both debt entries. AI-assisted: yes. |
|
Additional maintenance validation: this head was combined locally with the other pending FreeType/library contributions on main |
|
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.
|
MarcZX10
left a comment
There was a problem hiding this comment.
The wrapper keeps guest arrays in owned native storage, preserves caller inputs, and defers writing the output until FreeType reports success. The bounded-curve arithmetic guard is supported by the documented overflow probe, and the test set compares 8,192 generated curves with native FreeType plus independent extrema and error/canary cases. I reviewed the bundled FreeType 2.13.3 ftbbox.c arithmetic and did not find a defect in the stated coordinate guard. Current-main conventions and git diff --check pass. The reported full Windows build and focused 4/4 tests are contributor-run; hosted product jobs are skipped.
One contribution-rule item remains: this branch is based on b7d1d47a5f, while current upstream/main is 8499ea52e571b0edfc1feecfd3f6b9944012b359 (8 commits ahead). The merge tree is clean, but CONTRIBUTING requires branches to stay up to date. Please refresh the branch and rerun the focused FreeType tests on that head before merge. I found the #9329 debt-entry order agreement recorded in both PRs and no additional blocker.
ebb5766 to
991061e
Compare
|
Final follow-up |
MarcZX10
left a comment
There was a problem hiding this comment.
I rechecked the exact head 991061e6401f37882d3def52caa57c8ae26f9b8e against current main (11f976b27c16ed91633f00039dba5dfd97dd7cc1). The conventions check, git diff --check, and merge-tree check pass. The reported focused Windows tests and build are contributor-reported; I did not rerun them here because this VM has 432 MB free on / and no matching build artifacts, so a new build risks exhausting the filesystem. The hosted product build jobs are skipped. The earlier current-main request remains applicable: please rebase onto current main and rerun the focused FreeType tests on that head before merge.
|
@santhoshkumar-dev I prepared and validated the current-main update requested by @MarcZX10. The inputs were PR head Independent validation on Windows 11 Pro 10.0.26300, Ryzen 9 7900X, 31.66 GiB RAM, RTX 4070 Ti SUPER; supported WinLibs GCC 15.2.0 r7, Ninja Release, bundled dependencies, BUILD_TESTING=ON:
The validated local merge is Please merge the pinned upstream main into AI-assisted: yes (Codex ran the builds and tests above on my Windows host). |
|
I saw the follow-up validation on main |
|
@MarcZX10 Updated the existing branch to current main Fresh Windows 11 / supported GCC 15.2.0 r7 / Ninja Release validation on that final head: full default build passed, then 4/4 focused tests passed with zero skips (bounds, base FreeType, charmap and all 367 packaged libraries). The malformed-contour guard and 8,192 generated curves are included. Strict main-sync, conventions, whitespace and test registration pass. The description now records this actual submitted head. Thanks @Ondra97 for the independent earlier full build and 4/4 run on Ready for re-review of the current-main request; hosted product builds were not run here. |
|
Linux run (the description lists Linux as not tested). Docker on Windows: Ubuntu 26.04, GCC 15, glibc 2.43, WSL2 kernel 6.6, Release,
AI-assisted: yes |
|
Refreshed to Full default Windows build and 4/4 focused CTests pass. Local Ubuntu 24.04.1/WSL2, GCC 13.3/glibc 2.39: complete libs build and 4/4 focused tests, each repeated three times, including the 368-library loader, pass. The body now separates these fresh local results from the earlier independent Linux report. Newer main @Dom3005 previously reported five successful Linux repetitions on |
|
@santhoshkumar-dev I found two review blockers. FT_Outline_Get_BBox has a definition and a test-local extern declaration, but no declaration in the checked public FreeType headers. Please add the declaration once in a public header reachable from libSceFreeType.hpp, include it in the implementation/tests, and remove the local extern. The new tests also require the currently unsupported wide-coordinate paths to throw (the curved-coordinate loop and the narrow-native-FT_Pos branch). Please drop those unsupported-path throw assertions, keeping the production safety guards, debt, implemented extrema tests and argument-validation coverage. Please rerun public-header checks and guest_freetype_curve_bounds on the refreshed head. |
|
@oneandonlydean Declare the curve-box export once in the canonical public API and include it in the implementation and tests; remove the test-local declaration. Remove assertions that unsupported wide curved coordinates or narrow host FT_Pos values must throw. Retain supported extrema, LP64 linear coordinates where native FT_Pos permits them, and argument-validation coverage. Updated head: Overlap note: #10897 implements different validation exports; the remaining shared change is the OT debt paragraph. When combining the branches, retain the generic pending-helper description and both sets of identified names. There is no function or build dependency. |
|
Refreshed this branch onto main Local Windows/WinLibs GCC 15.2 and Ubuntu/WSL2/GCC 13.3 complete libs builds pass. Each platform passes 69/69 selected CTests, zero skips: public_headers, all 64 header compile batches and 4 runtime cases. Conventions and whitespace pass; the six maintained branches also merge cleanly in all 15 pairings. Applied the public-declaration clarification from #10897 to these named OT helpers too: The OT debt paragraph still overlaps #10897; the proposed documentation order is being coordinated on #10178. It is not an agreed dependency yet. |
What
Implement
FT_Outline_Get_BBoxfor guest outlines using bundled FreeType's quadratic/cubic extrema calculation. Guest 64-bit coordinates are copied into owned native vectors; native output is written to a local box and widened on success. Inputs stay unchanged, empty outlines do not inspect their arrays, and errors preserve the output.Signatures and calculations follow FreeType 2.13.3 ftbbox.c, with the name confirmed in the PS5 3.20 inventory. This computes curve extrema separately from the control-point box API in #9064.
Each implemented export is declared once in the canonical public API, included by the implementation and tests. The branch preserves the latest upstream PFR APIs and all merged FreeType features.
The named OT-provider import-resolution helpers also have one declaration each in the shared public API already reachable from the OT umbrella. Export.cpp includes that header. Their existing zero-argument placeholder signatures, explicit NID aliases and throwing behavior are unchanged; this does not establish the console prototypes.
The OT debt paragraph still overlaps #10897. Proposed documentation order: these helper-declaration updates first, then the validation PR retaining the generic pending-helper paragraph and its identified validation names. This order awaits the other author's confirmation; no code or build dependency is required.
The adapter belongs to physical
libSceFreeType. Same-NID inventory stubs in the distinct physicallibSceFreeTypeOlandlibSceFreeTypeOtproviders remain throwing helpers.Tested
Submitted and tested head
dc6395595c3a9589384786675c41e0ed185a3b7d, including upstream main48c160c58b589157ebd94ebd53736a182f8303bf.Windows 11 x64 / WinLibs GCC 15.2.0 r7 and local Ubuntu 24.04.1 x86-64 under WSL2 / GCC 13.3.0 / glibc 2.39: Ninja Release, bundled dependencies,
BUILD_TESTING=ON,ANYPS5_ENABLE_SPIRV_TOOLS=OFF. On each platform the completelibstarget and selected test executables build, and 69/69 CTests pass, zero skips: the public-header audit, all 64 public-header compilation batches and 4 focused runtime tests. The new upstream JPEG XR and updated SPIR-V dependencies use their pinned submodule commits. Focused runtime checks include this adapter, existing base/charmap APIs and the packaged-library loader.Final upstream recheck:
88795ed44801fa719eb2df990cbe1f11a1f9bd81merges cleanly; no FreeType/LibreSSL production, shared-header, test-registration or debt changes appeared after the tested base. Results remain pinned to the exact submitted head and its stated base.Conventions, whitespace and all 15 pairwise merge checks across the six maintained PRs pass. Open/closed/merged history was rechecked; no replacement implementation was found. No title or physical-console execution is claimed.
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)