Merge pull request #972 from Sonicadvance1/fix-intel-windows
Work around Intel's failings with buffer_storage
This commit is contained in:
commit
0576046fdd
|
@ -315,17 +315,22 @@ static void InitDriverInfo()
|
|||
version = 100*major + 10*minor + release;
|
||||
}
|
||||
break;
|
||||
case DriverDetails::VENDOR_INTEL: // Happens in OS X
|
||||
case DriverDetails::VENDOR_INTEL: // Happens in OS X/Windows
|
||||
{
|
||||
sscanf(g_ogl_config.gl_renderer, "Intel HD Graphics %d", &family);
|
||||
/*
|
||||
#ifdef _WIN32
|
||||
int glmajor = 0;
|
||||
int glminor = 0;
|
||||
int major = 0;
|
||||
int minor = 0;
|
||||
int release = 0;
|
||||
sscanf(g_ogl_config.gl_version, "%d.%d INTEL-%d.%d.%d", &glmajor, &glminor, &major, &minor, &release);
|
||||
version = 10000*major + 1000*minor + release;
|
||||
*/
|
||||
int revision = 0;
|
||||
// Example version string: '4.3.0 - Build 10.18.10.3907'
|
||||
sscanf(g_ogl_config.gl_version, "%d.%d.0 - Build %d.%d.%d.%d", &glmajor, &glminor, &major, &minor, &release, &revision);
|
||||
version = 100000000 * major + 1000000 * minor + 10000 * release + revision;
|
||||
version /= 10000;
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
case DriverDetails::VENDOR_NVIDIA:
|
||||
{
|
||||
|
|
|
@ -378,7 +378,8 @@ StreamBuffer* StreamBuffer::Create(u32 type, u32 size)
|
|||
|
||||
// buffer storage works well in most situations
|
||||
if (g_ogl_config.bSupportsGLBufferStorage &&
|
||||
!(DriverDetails::HasBug(DriverDetails::BUG_BROKENBUFFERSTORAGE) && type == GL_ARRAY_BUFFER))
|
||||
!(DriverDetails::HasBug(DriverDetails::BUG_BROKENBUFFERSTORAGE) && type == GL_ARRAY_BUFFER) &&
|
||||
!(DriverDetails::HasBug(DriverDetails::BUG_INTELBROKENBUFFERSTORAGE) && type == GL_ELEMENT_ARRAY_BUFFER))
|
||||
return new BufferStorage(type, size);
|
||||
|
||||
// don't fall back to MapAnd* for nvidia drivers
|
||||
|
|
|
@ -57,6 +57,7 @@ namespace DriverDetails
|
|||
{OS_OSX, VENDOR_INTEL, DRIVER_INTEL, 3000, BUG_PRIMITIVERESTART, -1.0, -1.0, true},
|
||||
{OS_WINDOWS,VENDOR_NVIDIA, DRIVER_NVIDIA, -1, BUG_BROKENUNSYNCMAPPING, -1.0, -1.0, true},
|
||||
{OS_LINUX, VENDOR_NVIDIA, DRIVER_NVIDIA, -1, BUG_BROKENUNSYNCMAPPING, -1.0, -1.0, true},
|
||||
{OS_WINDOWS,VENDOR_INTEL, DRIVER_INTEL, -1, BUG_INTELBROKENBUFFERSTORAGE, 101810.3907, -1.0, true},
|
||||
};
|
||||
|
||||
static std::map<Bug, BugInfo> m_bugs;
|
||||
|
|
|
@ -174,6 +174,14 @@ namespace DriverDetails
|
|||
// Qualcomm in their infinite wisdom thought it was a good idea to rotate the framebuffer 180 degrees on glBlit
|
||||
// This bug allows us to work around that rotation by rotating it the right way around again.
|
||||
BUG_ROTATEDFRAMEBUFFER,
|
||||
// Bug: Intel's Window driver broke buffer_storage with GL_ELEMENT_ARRAY_BUFFER
|
||||
// Affected devices: Intel (Windows)
|
||||
// Started Version: 15.36.3.64.3907 (10.18.10.3907)
|
||||
// Ended Version: -1
|
||||
// Intel implemented buffer_storage in their GL 4.3 driver.
|
||||
// It works for all the buffer types we use except GL_ELEMENT_ARRAY_BUFFER.
|
||||
// Causes complete blackscreen issues.
|
||||
BUG_INTELBROKENBUFFERSTORAGE,
|
||||
};
|
||||
|
||||
// Initializes our internal vendor, device family, and driver version
|
||||
|
|
Loading…
Reference in New Issue