mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-10-22 16:43:05 -05:00
Write the unattenuated linear gain 1.0f into *gain before checking the port handle in sceAudioInGetGain, and return 0 for open ports or SCE_AUDIO_IN_ERROR_INVALID_HANDLE (0x80260101) for closed or out-of-range handles in both sceAudioInGetGain and sceAudioInGetRerouteCount.
3.2 KiB
3.2 KiB
libSceAudioIn technical debt
Silent stubs
- sceAudioInInit (libSceAudioIn) - returns 0 without library-wide setup, as
sceAudioOutInitdoes; eachsceAudioInOpenopens its own SDL capture device
Unknown function info
- sceAudioInIsPadEmbeddedMic (libSceAudioIn) - name from its NID (
X+4jdIS75P0); signatureint32_t(int32_t handle)from the Ghost of Yotei (PPSA26344) call site in #2355; the result's meaning is unconfirmed, so it still throws rather than invent one
Functional
- sceAudioInHqOpen, sceAudioInAsyncOpen (libSceAudioIn) open the same port as
sceAudioInOpen, sosceAudioInInput,sceAudioInGetSilentStateandsceAudioInCloseaccept their handles. The signatures agree across shadPS4, SharpProspero and KytyPS5. HqOpen is limited to 128 samples at 48 kHz, as KytyPS5 and SharpProspero describe the higher-quality path: a longer grain returns the invalid-size error and a lower rate the invalid-frequency error. AsyncOpen also accepts the 384-sample grain, the largest SharpProspero documents for the low-latency path, and returns the invalid-size error for every other size; the console's shorter average return interval of an async port's blocks is not modelled, so like a synchronous portsceAudioInInputpaces one grain at a time. Param 0x10 opens a float mono port like 0x11, as KytyPS5 accepts both, while SharpProspero documents only 0x11. Host capture pacing and console behavior remain unverified. - sceAudioInGetGain, sceAudioInGetRerouteCount (libSceAudioIn) - signatures and semantics follow SharpProspero.
sceAudioInGetGainwrites the unattenuated linear gain1.0finto*gainbefore validatinghandle, returning0for an open port and0x80260101(SCE_AUDIO_IN_ERROR_INVALID_HANDLE) otherwise; a nullgainpointer throws because the console result is unverified, and host or system input attenuation is not modelled.sceAudioInGetRerouteCountreturns0for an open port and0x80260101otherwise, as each port opens its SDL capture device once and capture-device hot-swapping is not modelled.