feat(nkwebkit): implement RoundedRect from LayoutRect #17912

Merged
alvaroelpob merged 6 commits from upstream-pr/17912 into main 2026-11-30 04:51:01 +00:00
alvaroelpob commented 2026-11-09 22:07:47 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by alvaroelpob on 2026-11-09T22:07:47Z.


What

Implement both C1 and C2 ABI constructors for WebCore::RoundedRect(LayoutRect, Radii), copying the rectangle and corner radii per the pinned WebKit source.
Source: WebKit RoundedRect.cpp.

Tested

Linux: suite.py feat/nkwebkit-roundedrect-from-layoutrect at 575b5667b2: CTest 6575/6575 passed; conventions passed.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

Summary by CodeRabbit

  • Bug Fixes
    • Improved compatibility for web content that uses rounded rectangles, including their corner radii. This may help pages render rounded shapes more consistently.
  • Tests
    • Added checks to verify that rounded-rectangle geometry and corner radii are preserved.
<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5231988874 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/17912). Originally posted by [alvaroelpob](https://github.com/alvaroelpob) on 2026-11-09T22:07:47Z. --- ### What Implement both C1 and C2 ABI constructors for WebCore::RoundedRect(LayoutRect, Radii), copying the rectangle and corner radii per the pinned WebKit source. Source: [WebKit RoundedRect.cpp](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/graphics/RoundedRect.cpp). ### Tested <!-- OS, title or homebrew, what was checked. "Not tested" is a valid answer. A performance change: the summary lines of main and of this PR from the same machine and scene, with the traces attached, captured as the Performance report issue form describes. --> Linux: `suite.py feat/nkwebkit-roundedrect-from-layoutrect` at 575b5667b2: CTest 6575/6575 passed; conventions passed. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: n/a - [x] AI-assisted: yes <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## Summary by CodeRabbit * **Bug Fixes** * Improved compatibility for web content that uses rounded rectangles, including their corner radii. This may help pages render rounded shapes more consistently. * **Tests** * Added checks to verify that rounded-rectangle geometry and corner radii are preserved. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
MarcZX10 commented 2026-11-20 14:29:04 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-20T14:29:04Z.

Review: COMMENTED


Reviewed — no blocking findings

Nothing in the inspected implementation blocks merging; the described constructors copy the rectangle and radii into the expected members.

What I ran

Reviewed head 3450f3dd43ca1bb19e0c8565c5dfec4847f8c763. No commands or tests were run.

Results

Check Result Note
Source review passed Constructor bodies and ABI declarations inspected
Tests not run Author reports earlier Linux results

Findings

Blocking

None.

Non-blocking

None.

Not verified

No repository build or test was run. Export.cpp and docs/dev/debt/libSceNKWebKit.md were excluded from the review bundle and not read. The author-reported Linux run was at an earlier commit, so it does not establish results at this head. LegacyExports.hpp was not read; its diff has no added lines. The reviewed changed lines in WebCoreExports.hpp, RoundedRect.cpp, WebCoreTypes.hpp, and tests/RoundedRect.cpp were read.

To get this to a good state

Nothing is required.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5994232768 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/17912#pullrequestreview-5994232768). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-20T14:29:04Z. **Review:** COMMENTED --- # Reviewed — no blocking findings Nothing in the inspected implementation blocks merging; the described constructors copy the rectangle and radii into the expected members. ## What I ran Reviewed head `3450f3dd43ca1bb19e0c8565c5dfec4847f8c763`. No commands or tests were run. ## Results | Check | Result | Note | |---|---|---| | Source review | passed | Constructor bodies and ABI declarations inspected | | Tests | not run | Author reports earlier Linux results | ## Findings ### Blocking None. ### Non-blocking None. ## Not verified No repository build or test was run. `Export.cpp` and `docs/dev/debt/libSceNKWebKit.md` were excluded from the review bundle and not read. The author-reported Linux run was at an earlier commit, so it does not establish results at this head. `LegacyExports.hpp` was not read; its diff has no added lines. The reviewed changed lines in `WebCoreExports.hpp`, `RoundedRect.cpp`, `WebCoreTypes.hpp`, and `tests/RoundedRect.cpp` were read. ## To get this to a good state Nothing is required.
MarcZX10 commented 2026-11-22 06:53:42 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-22T06:53:42Z.

Review: APPROVED


Reviewed — looks good

Nothing in the reviewed implementation or test indicates a blocking defect; the reported full suite was not run by me.

What I ran

Reviewed head 575b5667b2c82bf80442e07012718e37516555db. Read the prepared description, commits, manifest and diff, plus all included changed files except the oversized Export.cpp; read targeted ranges of Export.cpp and the library CMakeLists.txt, and checked the changed symbol and directory listing with the reader. No tests or build commands were run.

Results

Check Result Note
Diff and code review passed Constructor copies both members
Build and tests not run Linux suite result is author-reported
Build wiring passed Source and test use existing CMake globs

Findings

Blocking

None.

Non-blocking

None.

Not verified

I did not independently verify the reported suite.py feat/nkwebkit-roundedrect-from-layoutrect result or test console caller ABI behavior. Export.cpp was too large to include in the review folder; I read only the nearby ranges relevant to the removed stubs. The description, commits, manifest, diff, LegacyExports.hpp, WebCoreExports.hpp, RoundedRect.cpp, WebCoreTypes.hpp, tests/RoundedRect.cpp, debt fragment, targeted Export.cpp range and CMakeLists.txt were read. files.json was not available as a reader path.

To get this to a good state

Nothing is required.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6010882021 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/17912#pullrequestreview-6010882021). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-22T06:53:42Z. **Review:** APPROVED --- # Reviewed — looks good Nothing in the reviewed implementation or test indicates a blocking defect; the reported full suite was not run by me. ## What I ran Reviewed head `575b5667b2c82bf80442e07012718e37516555db`. Read the prepared description, commits, manifest and diff, plus all included changed files except the oversized `Export.cpp`; read targeted ranges of `Export.cpp` and the library `CMakeLists.txt`, and checked the changed symbol and directory listing with the reader. No tests or build commands were run. ## Results | Check | Result | Note | |---|---|---| | Diff and code review | passed | Constructor copies both members | | Build and tests | not run | Linux suite result is author-reported | | Build wiring | passed | Source and test use existing CMake globs | ## Findings ### Blocking None. ### Non-blocking None. ## Not verified I did not independently verify the reported `suite.py feat/nkwebkit-roundedrect-from-layoutrect` result or test console caller ABI behavior. `Export.cpp` was too large to include in the review folder; I read only the nearby ranges relevant to the removed stubs. The description, commits, manifest, diff, `LegacyExports.hpp`, `WebCoreExports.hpp`, `RoundedRect.cpp`, `WebCoreTypes.hpp`, `tests/RoundedRect.cpp`, debt fragment, targeted `Export.cpp` range and `CMakeLists.txt` were read. `files.json` was not available as a reader path. ## To get this to a good state Nothing is required.
MarcZX10 commented 2026-11-30 02:49:30 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-30T02:49:30Z.

Review: APPROVED


Reviewed — looks good

The reviewed change at head 332e85ef576856023d2d008fcfb5d325bcba9e77 implements both RoundedRect constructor variants by copying the rectangle and radii; no defect was verified in the inspected code.

What I ran

Read the prepared diff and changed files, and used the pinned reader for the excluded Export.cpp changed regions, build registration, and related declarations. No commands or tests were run. The description reports 6,575 CTest checks and conventions passed at an earlier commit; that is author-reported, not verified here.

Results

Check Result Note
Constructor implementation passed Both variants copy the fields
Build and test registration passed Existing source and test globs include the new files
Tests on reviewed head not run Earlier author-reported results are from another revision

Findings

Blocking

None.

Non-blocking

None.

Sources

  • core/libs/prx/libSceNKWebKit/src/RoundedRect.cpp:34-40 implements both variants.
  • core/libs/prx/libSceNKWebKit/src/WebCoreTypes.hpp:127-135 defines the aggregate fields; static assertions check their offsets.
  • core/libs/prx/libSceNKWebKit/CMakeLists.txt:20-21,52-59 includes source and test files through globs.
  • Pinned WebKit RoundedRect.cpp is cited by the change documentation.

Not verified

Did not run tests or validate behavior on console. Read all changed files except core/libs/prx/libSceNKWebKit/Export.cpp, which was excluded from the prepared bundle; inspected only its two changed regions through repo_read.py. Read the new implementation, declarations, type definitions, test, debt fragment, and relevant CMake file. No additional files were marked excluded by the bundle metadata.

To get this to a good state

Nothing is required.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:6106335327 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/17912#pullrequestreview-6106335327). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-11-30T02:49:30Z. **Review:** APPROVED --- # Reviewed — looks good The reviewed change at head `332e85ef576856023d2d008fcfb5d325bcba9e77` implements both RoundedRect constructor variants by copying the rectangle and radii; no defect was verified in the inspected code. ## What I ran Read the prepared diff and changed files, and used the pinned reader for the excluded `Export.cpp` changed regions, build registration, and related declarations. No commands or tests were run. The description reports 6,575 CTest checks and conventions passed at an earlier commit; that is author-reported, not verified here. ## Results | Check | Result | Note | |---|---|---| | Constructor implementation | passed | Both variants copy the fields | | Build and test registration | passed | Existing source and test globs include the new files | | Tests on reviewed head | not run | Earlier author-reported results are from another revision | ## Findings ### Blocking None. ### Non-blocking None. ## Sources - `core/libs/prx/libSceNKWebKit/src/RoundedRect.cpp:34-40` implements both variants. - `core/libs/prx/libSceNKWebKit/src/WebCoreTypes.hpp:127-135` defines the aggregate fields; static assertions check their offsets. - `core/libs/prx/libSceNKWebKit/CMakeLists.txt:20-21,52-59` includes source and test files through globs. - [Pinned WebKit RoundedRect.cpp](https://github.com/neonmodder123/PS5-WebKit-11.x/blob/80f77e94c63ee7202eec3d4b5b1a021dd89011ba/Source/WebCore/platform/graphics/RoundedRect.cpp#L145-L149) is cited by the change documentation. ## Not verified Did not run tests or validate behavior on console. Read all changed files except `core/libs/prx/libSceNKWebKit/Export.cpp`, which was excluded from the prepared bundle; inspected only its two changed regions through `repo_read.py`. Read the new implementation, declarations, type definitions, test, debt fragment, and relevant CMake file. No additional files were marked excluded by the bundle metadata. ## To get this to a good state Nothing is required.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!17912
No description provided.