feat(libcairo): implement path geometry and operator state #18381
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/18381"
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 bipinkrish on 2026-11-11T13:03:25Z.
What
Bring the missing Cairo path geometry from #15430 and #15675 onto current main.
cairo_rectangleadds a closed path in quantized device coordinates, andcairo_path_extentsbounds line segments and cubic extrema in user coordinates. It writes each requested coordinate independently.cairo_set_operatorandcairo_get_operatorpreserve the operator across nested save and restore.#15324 already supplies the path storage and is merged. This PR preserves the five original commits from hyvvs and Dean Galvin, including the rectangle closure, cubic rounding, closed-point and nullable-output corrections. It updates the debt file for the four exports. PS5 firmware behavior remains unmeasured.
Tested
Ubuntu 24.04.4, x86-64, GCC 13.3, Release. Tested head
4d309832c35f385a79fe2e33b2f14bb4362ebdc5.ctest --test-dir build -R '^(guest_cairo_.*|public_headers)$' --output-on-failurepassed 11 of 11 tests.cairo_get_operatorandcairo_path_extents.git diff --checkandtools/check_conventions.py --base upstream/mainpassed. The requiredorigin/maincheck reported the same four pre-existing commit-subject errors as the unmodified upstream baseline because the fork's main is behind.tools/pr_overlap.py --branch codex/cairo-path-geometryagainst 1,982 open PRs on upstream main1e8dfd69d55. The branch merged cleanly with that base. The checker flagged shared debt edits in #15208, #16895 and #16954 and a CMake test registration in #16954. It returned 2 because #14212 already conflicts with main, so I reviewed its Cairo debt diff directly. Its only shared edit removes the stale callable count. I reviewed all four branch diffs and found no shared export implementation.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)Imported from boykopovar/AnyPS5. Originally posted by PrivacyOnion on 2026-11-11T16:08:44Z.
Review: APPROVED
Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against
4d309832c3:tools/check_conventions.pypassed;git diff --checkclean.guest_cairo_geometry_tests,guest_cairo_path_extents_testsbuilt cleanly.guest_cairo_geometry,guest_cairo_path_extents):core/libs/prx/libcairo/Context.cpp,core/libs/prx/libcairo/Export.cpp,core/libs/prx/libcairo/include/Context.hpp,core/libs/prx/libcairo/include/InventoryExports.hpp,core/libs/prx/libcairo/include/Path.hppreverted tomain, the new tests do not build/link without the change; restoring it makes them build and pass.Looks Good To Me