From 696aa0f9749210bf5e886e916c19f003427f90e3 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Mon, 28 Oct 2013 00:31:45 -0700 Subject: [PATCH] Initialize atrac context values per PSP tests. --- Core/HLE/sceAtrac.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Core/HLE/sceAtrac.cpp b/Core/HLE/sceAtrac.cpp index 9a7189b4fe..2ffbdff21b 100644 --- a/Core/HLE/sceAtrac.cpp +++ b/Core/HLE/sceAtrac.cpp @@ -103,9 +103,9 @@ struct AtracLoopInfo { }; struct Atrac { - Atrac() : atracID(-1), data_buf(0), decodePos(0), decodeEnd(0), atracChannels(2), atracOutputChannels(2), + Atrac() : atracID(-1), data_buf(0), decodePos(0), decodeEnd(0), atracChannels(0), atracOutputChannels(2), atracBitrate(64), atracBytesPerFrame(0), atracBufSize(0), - currentSample(0), endSample(-1), firstSampleoffset(0), loopinfoNum(0), loopNum(0), codecType(0), failedDecode(false) { + currentSample(0), endSample(0), firstSampleoffset(0), loopinfoNum(0), loopNum(0), codecType(0), failedDecode(false) { memset(&first, 0, sizeof(first)); memset(&second, 0, sizeof(second)); #ifdef USE_FFMPEG @@ -389,6 +389,7 @@ int Atrac::Analyze() { loopStartSample = -1; loopEndSample = -1; decodePos = 0; + atracChannels = 2; if (first.size < 0x100) { ERROR_LOG_REPORT(ME, "Atrac buffer very small: %d", first.size);