From eefe3e8d4fec6ec464c233b3a719c5dd8ffd320b Mon Sep 17 00:00:00 2001 From: Gregory Hainaut Date: Fri, 8 Jul 2016 09:42:01 +0200 Subject: [PATCH] gsdx ogl: reserve 200MB of the VRAM for various gl buffers (IBO/VBO/PBO/UBO) --- plugins/GSdx/GSDeviceOGL.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/plugins/GSdx/GSDeviceOGL.cpp b/plugins/GSdx/GSDeviceOGL.cpp index 68fe102a1e..8b837e0a03 100644 --- a/plugins/GSdx/GSDeviceOGL.cpp +++ b/plugins/GSdx/GSDeviceOGL.cpp @@ -493,15 +493,13 @@ bool GSDeviceOGL::Create(GSWnd* wnd) if (GLLoader::found_GL_NVX_gpu_memory_info && !GLLoader::fglrx_buggy_driver) { glGetIntegerv(GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, vram); } else if (GLLoader::found_GL_ATI_meminfo) { - // Why openGL is always that complicated ! - //glGetIntegerv(GL_RENDERBUFFER_FREE_MEMORY_ATI, vram); glGetIntegerv(GL_TEXTURE_FREE_MEMORY_ATI, vram); } else { fprintf(stdout, "No extenstion supported to get available memory. Use default value !\n"); } - if (vram[0] > 0) - GLState::available_vram = (uint64)vram[0] * 1024ul; + if (vram[0] > 200000) + GLState::available_vram = (uint64)(vram[0] - 200000) * 1024ul; fprintf(stdout, "Available VRAM:%lluMB\n", GLState::available_vram >> 20u);