Repository navigation
feat(libSceAudioOut): answer the legacy mastering calls without a mastering stage - #8525
Conversation
|
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.
|
|
I would take one of two routes. The first is to throw for bit 0 as well, as int APS5_VABI sceAudioOutMasteringInit(uint32_t flags) {
if (flags != 0) NotImplemented_nid_no_patch(__func__);
return 0;
}The second is to keep accepting bit 0 and replace "the sources document no error code" in the entry with what shadPS4 shows: 0x80260201 for any non-zero Init flags, plus 0x80260203 (not initialized) and 0x80260204 (invalid states id). Since a not-initialized code exists, GetState before Init could also be listed as unknown, next to SetParam before Init. One smaller point: the SharpProspero link in the entry and the PR text ( |
|
Independent Windows run of this PR (data only). Environment: Windows 10 Pro 10.0.19045, Ryzen 7 5800X3D, WinLibs GCC 15.2.0 r7 (MinGW-w64 UCRT), Release, BUILD_TESTING=ON. Merge-tree of the PR head against Results (3 runs each):
Not run: other platforms, the other tests in the same family, the full repository CTest, and any title or console run. AI-assisted (Claude Code). |
|
@nikowolf123 thanks, I took the first route in bef2578 (on top of current
GetState and SetParam before Init are listed as unknown too. All 41 @xXPBSXx thanks for the Windows run. |
|
Hi MarrasFederico — MarcZX10's review on my #9541 found that both PRs touch |
|
@xdCloudy agreed: #8525 lands first and #9541 rebases afterward. I compared the diffs, and the exports are distinct. In |
…ering # Conflicts: # docs/dev/debt/libSceAudioOut.md
…tering debt entry
…ering # Conflicts: # docs/dev/debt/libSceAudioOut.md
|
Checked the signatures, default ids (1) and meter offsets (32/128/240/272/304 in the 336-byte states struct) against SharpProspero at the cited commit; the static_asserts pin the offsets. The new test cases fail on |
What
The legacy mastering calls
sceAudioOutMasteringInit,SetParam,GetStateandTermthrewnot implemented, and their debt entries listed the signatures as unknown. SharpProsperoAudioOut.csdocuments them:Init(uint flags)withSwapEqCompressor(bit 0);SetParam(header*, uint flags)with the default params id 1;GetState(header*)with the default states id 1, which writes the compressor input RMS and gain reduction and the limiter input, output and gain peaks;Term().The two default header identifiers are documented separately in AudioOut.cs lines 243–247.
Its
AudioOutMasteringwrapper reads those meters at offsets 32, 128, 240, 272 and 304 of a 336-byte struct, which match the repo'sAudioOut2MasteringStates;static_asserts pin them.AnyPS5 has no mastering stage, so these calls follow their AudioOut2 counterparts, next to which they now live:
SwapEqCompressor, but shadPS4's PS4 stub rejects any non-zero Init flags with 0x80260201, so its effect is disputed.The four "unknown signature" entries are replaced by entries recording what is unverified: the disputed bit 0, repeated or unmatched Init/Term, SetParam or GetState before Init, the id 1 parameter layout, and whether a console reports zero meters for an idle chain.
Tested
Ubuntu 26.04.1, kernel 7.0.0-38, GCC 15.2.0, Release, full build with
BUILD_TESTING=ON. Windows was not compiled. No title was run.audio_out2_latency, new legacy-mastering cases:main, where the calls throw. Accepting Init flag bit 0, missing one meter array, or accepting another params or states id makes it fail.audio_outpass.tools/check_conventions.py --base origin/mainpasses.tools/pr_overlap.pyfinds no conflicting lines. It could not compare feat(aot): consolidate native ARM64 compiler, runtime and consumers #5021 and feat(libSceAudioOut): implement sceAudioOutGetSystemState #5965, which conflict withmain; neither touches the mastering calls.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)