gsdx: dull driver

Hopefully futur low-end GPU will get 4GB of VRAM
This commit is contained in:
Gregory Hainaut 2016-07-08 21:53:42 +02:00
parent 3f03f7333c
commit 82d83ca579
2 changed files with 3 additions and 5 deletions

View File

@ -210,7 +210,6 @@ namespace GLLoader {
bool found_GL_ARB_viewport_array = false; // Intel IB. AMD/NVIDIA DX10 bool found_GL_ARB_viewport_array = false; // Intel IB. AMD/NVIDIA DX10
// Bonus to monitor the VRAM // Bonus to monitor the VRAM
bool found_GL_NVX_gpu_memory_info = false; bool found_GL_NVX_gpu_memory_info = false;
bool found_GL_ATI_meminfo = false;
// Mandatory // Mandatory
bool found_GL_ARB_buffer_storage = false; bool found_GL_ARB_buffer_storage = false;
@ -309,7 +308,6 @@ namespace GLLoader {
// Bonus // Bonus
if (ext.compare("GL_EXT_texture_filter_anisotropic") == 0) found_GL_EXT_texture_filter_anisotropic = true; if (ext.compare("GL_EXT_texture_filter_anisotropic") == 0) found_GL_EXT_texture_filter_anisotropic = true;
if (ext.compare("GL_NVX_gpu_memory_info") == 0) found_GL_NVX_gpu_memory_info = true; if (ext.compare("GL_NVX_gpu_memory_info") == 0) found_GL_NVX_gpu_memory_info = true;
if (ext.compare("GL_ATI_meminfo") == 0) found_GL_ATI_meminfo = true;
// GL4.0 // GL4.0
if (ext.compare("GL_ARB_gpu_shader5") == 0) found_GL_ARB_gpu_shader5 = true; if (ext.compare("GL_ARB_gpu_shader5") == 0) found_GL_ARB_gpu_shader5 = true;
if (ext.compare("GL_ARB_draw_buffers_blend") == 0) found_GL_ARB_draw_buffers_blend = true; if (ext.compare("GL_ARB_draw_buffers_blend") == 0) found_GL_ARB_draw_buffers_blend = true;

View File

@ -495,10 +495,10 @@ bool GSDeviceOGL::Create(GSWnd* wnd)
// Get Available Memory // Get Available Memory
// **************************************************************** // ****************************************************************
GLint vram[4] = {0}; GLint vram[4] = {0};
if (GLLoader::found_GL_NVX_gpu_memory_info && !GLLoader::fglrx_buggy_driver) { if (GLLoader::fglrx_buggy_driver) {
glGetIntegerv(GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, vram);
} else if (GLLoader::found_GL_ATI_meminfo) {
glGetIntegerv(GL_TEXTURE_FREE_MEMORY_ATI, vram); glGetIntegerv(GL_TEXTURE_FREE_MEMORY_ATI, vram);
} else if (GLLoader::found_GL_NVX_gpu_memory_info) {
glGetIntegerv(GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, vram);
} else { } else {
fprintf(stdout, "No extenstion supported to get available memory. Use default value !\n"); fprintf(stdout, "No extenstion supported to get available memory. Use default value !\n");
} }