From 0572423e2bbfca3cda0ba3be0a82197878ed246b Mon Sep 17 00:00:00 2001 From: sum2012 Date: Wed, 23 Dec 2020 06:22:30 +0800 Subject: [PATCH] Fix Grand Theft Auto - Vice City Stories --- Core/HLE/sceMpeg.cpp | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/Core/HLE/sceMpeg.cpp b/Core/HLE/sceMpeg.cpp index 5450b2615c..17140e345d 100644 --- a/Core/HLE/sceMpeg.cpp +++ b/Core/HLE/sceMpeg.cpp @@ -1097,12 +1097,6 @@ static u32 sceMpegAvcDecode(u32 mpeg, u32 auAddr, u32 frameWidth, u32 bufferAddr } } - if (ctx->mpegwarmUp < MPEG_WARMUP_FRAMES) { - DEBUG_LOG(ME, "sceMpegAvcDecode(%08x, %08x, %d, %08x, %08x):warming up", mpeg, auAddr, frameWidth, bufferAddr, initAddr); - ctx->mpegwarmUp++; - return ERROR_MPEG_NO_DATA; - } - SceMpegAu avcAu; avcAu.read(auAddr); @@ -1584,6 +1578,12 @@ static int sceMpegGetAvcAu(u32 mpeg, u32 streamId, u32 auAddr, u32 attrAddr) return -1; } + if (ctx->mpegwarmUp < MPEG_WARMUP_FRAMES) { + DEBUG_LOG(ME, "sceMpegGetAvcAu(%08x, %08x, %08x, %08x): warming uo", mpeg, streamId, auAddr, attrAddr); + ctx->mpegwarmUp++; + return ERROR_MPEG_NO_DATA; + } + SceMpegAu avcAu; avcAu.read(auAddr); @@ -1679,6 +1679,12 @@ static int sceMpegGetAtracAu(u32 mpeg, u32 streamId, u32 auAddr, u32 attrAddr) return -1; } + if (ctx->mpegwarmUp < MPEG_WARMUP_FRAMES) { + DEBUG_LOG(ME, "sceMpegGetAtracAu(%08x, %08x, %08x, %08x): warning up", mpeg, streamId, auAddr, attrAddr); + ctx->mpegwarmUp++; + return ERROR_MPEG_NO_DATA; + } + SceMpegAu atracAu; atracAu.read(auAddr); @@ -1941,11 +1947,6 @@ static u32 sceMpegAtracDecode(u32 mpeg, u32 auAddr, u32 bufferAddr, int init) return -1; } - if (ctx->mpegwarmUp < MPEG_WARMUP_FRAMES) { - DEBUG_LOG(ME, "sceMpegAtracDecode(%08x, %08x, %08x, %i):warming up", mpeg, auAddr, bufferAddr, init); - ctx->mpegwarmUp++; - return ERROR_MPEG_NO_DATA; - } DEBUG_LOG(ME, "sceMpegAtracDecode(%08x, %08x, %08x, %i)", mpeg, auAddr, bufferAddr, init); SceMpegAu atracAu;