mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-20 14:11:42 +00:00
Add back a lost-in-refactoring hack for the SasAudio/sceAtrac integration.
Fixes #19075
This commit is contained in:
parent
11112d4043
commit
917f5897bd
@ -216,6 +216,10 @@ public:
|
||||
int GetOutputChannels() const {
|
||||
return outputChannels_;
|
||||
}
|
||||
void SetOutputChannels(int channels) {
|
||||
// Only used for sceSas audio. To be refactored away in the future.
|
||||
outputChannels_ = channels;
|
||||
}
|
||||
|
||||
int atracID_ = -1;
|
||||
|
||||
|
@ -1007,6 +1007,11 @@ u32 AtracSasDecodeData(int atracID, u8* outbuf, u32 outbufPtr, u32 *SamplesNum,
|
||||
|
||||
int AtracSasGetIDByContext(u32 contextAddr) {
|
||||
int atracID = (int)Memory::Read_U32(contextAddr + 0xfc);
|
||||
// Restored old hack here that forces outputChannels_ to 1, since sceSas expects mono output, unlike normal usage.
|
||||
// This is for savestate compatibility.
|
||||
// I think it would be better to simply pass in a 1 as a parameter to atrac->DecodeData in AtracSasDecodeData above.
|
||||
AtracBase *atrac = getAtrac(atracID);
|
||||
atrac->SetOutputChannels(1);
|
||||
return atracID;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user