feat(libSceNgs2): support default listener calculation #4598
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/4598"
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 Lorkydey on 2026-10-12T16:31:20Z.
What
Dead Cells (PPSA15552) reaches
sceNgs2GeomCalcListener not implementedafter its custom sampler rack is supported, as reported in #4334.Implement only the default listener case: position
(0, 0, 0), front(0, 0, 1), up(0, 1, 0)and flags0. Write the identity matrix, preserve finite velocity and positive finite sound speed, and initialize the complete work structure. Any other position, orientation (including non-unit vectors) or flags throws before touching the output. Nonfinite inputs and nonpositive sound speed also throw; a null output returns the existing NGS2 invalid-address error.This adopts the restricted option requested in review. The previous normalization, handedness and translation calculations have been removed. The default result follows KytyPS5's implementation and PS5PCEM's model for this case; neither is claimed as a PS5 measurement. The broken investigation link has been replaced by the actual source, and the unsupported cases and remaining uncertainties are recorded in
docs/dev/debt/libSceNgs2.native.md.sceNgs2GeomApplystill throws. Source attenuation, panning, Doppler and custom-rack support are outside this change. Dead Cells' listener arguments have not been captured here, and the narrowed implementation has not been run on the title: the linked report establishes the call is reached, not that this restricted case is sufficient for the game.Tested
Validated head
dadc23a8c19b0d42b15e6f593257d8a0c2da612e, rebased onto main7940cacd834f06012e2678189316cc9dee85b6fd:BUILD_TESTING=ON: all runtime libraries (libs) and the 10 NGS2 targets built; allngs2_*tests passed three times (30 successful executions, 2.31 s total).Geom.cpp,Voice.cppandUnimplemented.cppfail at the unimplemented call; the previous PR'sGeom.cppatdd087ce36fails the new rejection test. Both failures were verified on Linux and Windows, then the updated sources were restored and all tests passed.git diff --checkpass.This is focused NGS2 validation, not a full test-suite or title run. The validation workflow is on a separate fork CI branch.
The upstream eligibility job failed before building with
API rate limit exceeded for installation. The focused Linux/Windows validation linked above and the upstream conventions check passed. Rerunning the failed upstream job requires repository permissions this fork account does not have.Overlap coordination
Coordination with #4254 and #4788: pairwise simulations conflict only in
docs/dev/debt/libSceNgs2.native.md. The proposal is this PR first after review, followed by rebases preserving the default-listener limits, custom-sampler entry and voice-index entry. Agreement is pending; if either other PR lands first, this PR will instead be rebased and the checklist updated for that order. The stale claim that listener calculation is wholly unimplemented must be removed while preserving thesceNgs2GeomApplylimitation. The checklist currently declares no prerequisite; no combined runtime validation is claimed.Checklist
main; no other open PR implements the same functions.mdfiles or images added to the repositoryImported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-12T16:48:57Z.
Progress report (
2fabe44→ dd087ce)📈 System libraries: 87.43% (+0.03%, +1 implemented functions)
✅ 1 implemented
sceNgs2GeomCalcListenerImported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-12T21:06:18Z.
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.
main)docs/dev/debt/libSceNgs2.native.mdL25docs/dev/debt/libSceNgs2.native.mdL25Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-12T21:06:21Z.
Review: DISMISSED
Thanks, the code is clean and the test fails without the change (checked:
ngs2_geompasses on the PR, fails with the sources reverted to main).One blocker, per the exact-or-throw rule:
-dot(axis, position), flag 1 = right-handed,crossorder) rests only on PS5PCEM's own model. Thedocs/development/dead-cells-ngs2-2026-10-11.mdlink in the body and indocs/dev/debt/libSceNgs2.native.md:26returns 404 at the pinned commit (onlysrc/hle/ngs2_geom.zigexists there, which is another emulator's implementation, not a measurement). The other references disagree: KytyPS5Ngs2GeomCalcListenerwrites an identity matrix, prosper zeroes the 0x60-byte work. They only agree on the default listener (identity).What would fix it, either:
sceNgs2GeomApply, or a PS5 measurement) and fix the link.Also, the new TechnicalDebt entry ends with a period, unlike its neighbours (
docs/dev/debt/libSceNgs2.native.md:26).Imported from boykopovar/AnyPS5. Originally posted by Lorkydey on 2026-10-12T21:31:36Z.
@adriadam10 Thanks for the review! Updated in
dadc23a8c: only the default listener at the origin with flags 0 is accepted now. Other orientations, translations and flags throw without modifying the output. I also fixed the reference link and updated TechnicalDebt.All 10 NGS2 tests pass three times on both Windows and Linux, and the new rejection tests fail against the previous implementation.
The upstream eligibility check hit GitHub’s API rate limit; details are in the PR description. Ready for another look when you have time :)
Imported from boykopovar/AnyPS5. Originally posted by Lorkydey on 2026-10-12T23:48:03Z.
@MarcZX100 @PrintOrb Coordinating the debt-file overlap with #4254 and #4788.
Pairwise merge simulations of #4598 (
dadc23a8c) with #4254 (b0524d092) and #4788 (a9fe4ac4e) conflict only indocs/dev/debt/libSceNgs2.native.md. The implementations cover different functions.The resolution should retain the restricted default-listener entry from this PR and both the custom-sampler and voice-index entries from yours, with a single
Functionalheading. The reset-parameter paragraph must no longer callsceNgs2GeomCalcListenerwholly unimplemented; its supported case and limitations belong in the separate listener entry.sceNgs2GeomApplyremains unimplemented.I propose #4598 first once its pending review is cleared, followed by rebases of the debt entries in your PRs. Would that work? If either of yours is ready first, I can rebase this one instead and record the agreed order in
Depends on. No runtime dependency or combined runtime validation is implied by this documentation conflict.AI-assisted: yes (Codex).