Bug 744888 - Work around a NVIDIA driver bug - r=jgilbert

This commit is contained in:
Benoit Jacob 2012-04-16 15:56:12 -04:00
parent 7697afac6d
commit 2d7e3b4fef

View File

@ -72,6 +72,8 @@ typedef char realGLboolean;
#include "GLContextSymbols.h"
#include "mozilla/mozalloc.h"
namespace mozilla {
namespace layers {
class LayerManagerOGL;
@ -2028,6 +2030,16 @@ public:
void fBufferData(GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage) {
BEFORE_GL_CALL;
mSymbols.fBufferData(target, size, data, usage);
// bug 744888
if (WorkAroundDriverBugs() &&
!data &&
Vendor() == VendorNVIDIA)
{
char c = 0;
mSymbols.fBufferSubData(target, size-1, 1, &c);
}
AFTER_GL_CALL;
}