diff --git a/Core/HLE/sceGe.h b/Core/HLE/sceGe.h index b37508a672..855f5a7a87 100644 --- a/Core/HLE/sceGe.h +++ b/Core/HLE/sceGe.h @@ -44,5 +44,9 @@ void __GeShutdown(); // Export functions for use by Util/PPGe u32 sceGeRestoreContext(u32 ctxAddr); u32 sceGeSaveContext(u32 ctxAddr); +int sceGeBreak(u32 mode); +int sceGeContinue(); +int sceGeListSync(u32 displayListID, u32 mode); u32 sceGeListEnQueue(u32 listAddress, u32 stallAddress, int callbackId, u32 optParamAddr); +u32 sceGeListEnQueueHead(u32 listAddress, u32 stallAddress, int callbackId, u32 optParamAddr); diff --git a/Core/Util/PPGeDraw.cpp b/Core/Util/PPGeDraw.cpp index d18fda45f1..980a7e014e 100644 --- a/Core/Util/PPGeDraw.cpp +++ b/Core/Util/PPGeDraw.cpp @@ -229,15 +229,15 @@ void PPGeEnd() WriteCmd(GE_CMD_END, 0); if (dataWritePtr > dataPtr) { + sceGeBreak(0); sceGeSaveContext(savedContextPtr); gpu->EnableInterrupts(false); // We actually drew something - u32 list = sceGeListEnQueue(dlPtr, dlWritePtr, 0, 0); + u32 list = sceGeListEnQueueHead(dlPtr, dlWritePtr, -1, 0); DEBUG_LOG(HLE, "PPGe enqueued display list %i", list); - // TODO: Might need to call some internal trickery function when this is actually synchronous. - // sceGeListSync(u32 displayListID, 1); //0 : wait for completion 1:check and return gpu->EnableInterrupts(true); + sceGeContinue(); sceGeRestoreContext(savedContextPtr); } }