mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
Headless: Take the timeout screenshot before ending the draw frame
On Vulkan, reading back the display framebuffer after EndDrawFrame hit the insideFrame_ assert in CopyFramebufferToMemory, so any run that timed out with --screenshot-save crashed in debug builds. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
1 parent
c9c26ce0fd
commit
f6e70b88ad
1 file changed
+7
-6
@@ -515,6 +515,13 @@ static bool RunAutoTest(GraphicsContext *graphicsContext, CoreParameter &corePar
|
|||||||
gpu->EndHostFrame();
|
gpu->EndHostFrame();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Before EndDrawFrame: Vulkan can only read back a framebuffer inside a frame.
|
||||||
|
if (!g_screenshotSavePath.empty() && !g_screenshotSaved) {
|
||||||
|
// SendDebugScreenshot ignores the descriptor and reads the display framebuffer from the GPU
|
||||||
|
// itself, so there's nothing to fill in here.
|
||||||
|
SendDebugScreenshot(DebugScreenshotDesc{});
|
||||||
|
}
|
||||||
|
|
||||||
if (draw) {
|
if (draw) {
|
||||||
// Vulkan may get angry if we don't do a final present.
|
// Vulkan may get angry if we don't do a final present.
|
||||||
if (gpu) {
|
if (gpu) {
|
||||||
@@ -527,12 +534,6 @@ static bool RunAutoTest(GraphicsContext *graphicsContext, CoreParameter &corePar
|
|||||||
EndDrawFrame(draw);
|
EndDrawFrame(draw);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!g_screenshotSavePath.empty() && !g_screenshotSaved) {
|
|
||||||
// SendDebugScreenshot ignores the descriptor and reads the display framebuffer from the GPU
|
|
||||||
// itself, so there's nothing to fill in here.
|
|
||||||
SendDebugScreenshot(DebugScreenshotDesc{});
|
|
||||||
}
|
|
||||||
|
|
||||||
PSP_Shutdown(true);
|
PSP_Shutdown(true);
|
||||||
|
|
||||||
if (!opt.bench) {
|
if (!opt.bench) {
|
||||||
|
|||||||
Reference in new issue
Block a user