mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
Headless: Run OpenGL offscreen on macOS, without a window
A CGL context with no drawable, rendering into a framebuffer object of its own that stands in for the backbuffer through g_defaultFBO. Core profile, as the SDL app uses on macOS. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
1 parent
c9cddb99e9
commit
ea101b714f
3 files changed
+151
No files matched your search
@@ -966,6 +966,11 @@ int main(int argc, const char* argv[]) {
|
||||
vulkanContext->SetOffscreen(480, 272);
|
||||
graphicsContext = vulkanContext;
|
||||
deviceSetting = &g_Config.sVulkanDevice;
|
||||
#if PPSSPP_PLATFORM(MAC) && defined(SDL)
|
||||
} else if (gpuCore == GPUCORE_GLES) {
|
||||
// So does OpenGL, into a framebuffer object of its own.
|
||||
graphicsContext = new CGLHeadlessGraphicsContext(480, 272);
|
||||
#endif
|
||||
} else {
|
||||
// TODO: Will we need a larger window for higher resolutions? Well, not if we use buffered rendering.
|
||||
window = CreateHiddenWindow(480, 272, cmdLineOptions.gpuBackend.value_or(GPUBackend::OPENGL), &windowDesc);
|
||||
|
||||
Reference in new issue
Block a user