mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Work-around crash in sceMpeg with bad ringbuffer address.
Add reminder on first run to access the ingame menu with ESC on windows.
This commit is contained in:
parent
062979d8d9
commit
e115ed4187
2 changed files with 14 additions and 2 deletions
|
@ -610,8 +610,13 @@ u32 sceMpegAvcDecode(u32 mpeg, u32 auAddr, u32 frameWidth, u32 bufferAddr, u32 i
|
|||
SceMpegAu avcAu;
|
||||
avcAu.read(auAddr);
|
||||
|
||||
SceMpegRingBuffer ringbuffer;
|
||||
Memory::ReadStruct(ctx->mpegRingbufferAddr, &ringbuffer);
|
||||
SceMpegRingBuffer ringbuffer = {0};
|
||||
if (Memory::IsValidAddress(ctx->mpegRingbufferAddr)) {
|
||||
Memory::ReadStruct(ctx->mpegRingbufferAddr, &ringbuffer);
|
||||
} else {
|
||||
ERROR_LOG(HLE, "Bogus mpegringbufferaddr");
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (ringbuffer.packetsRead == 0 || ctx->mediaengine->IsVideoEnd()) {
|
||||
WARN_LOG(HLE, "sceMpegAvcDecode(%08x, %08x, %d, %08x, %08x): mpeg buffer empty", mpeg, auAddr, frameWidth, bufferAddr, initAddr);
|
||||
|
|
|
@ -96,6 +96,13 @@ EmuScreen::EmuScreen(const std::string &filename) : invalid_(true) {
|
|||
g_gameInfoCache.FlushBGs();
|
||||
|
||||
NOTICE_LOG(BOOT, "Loading %s...", fileToStart.c_str());
|
||||
I18NCategory *s = GetI18NCategory("Screen");
|
||||
|
||||
#ifdef _WIN32
|
||||
if (g_Config.bFirstRun) {
|
||||
osm.Show(s->T("PressESC", "Press ESC to open the pause menu"), 3.0f);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
EmuScreen::~EmuScreen() {
|
||||
|
|
Loading…
Add table
Reference in a new issue