Geforce gldrawarrays crash

Started by
1 comment, last by Wh0p 9 years, 10 months ago
Other people have tested my program on their computers and it crashes on geforce videocards.

Using the project files one person at least traced it down to glDrawArrays in one file. I thought this was a problem with not enabling vertex attrib arrays every time I used them, but it still doesn't work.

Could it be using attributes that don't exist in the shader (and are assigned the -1 equivalent on an unsigned int ID at least on my quadro card)? I'm not sure I do that in that particular file though?

Will glGetError help me track these problems down on my quadro card? What could be the problem?
Advertisement

Is this the problem?

For only nVidia PC drivers (not OS X), if you enable a vertex array that doesn't exist in the shader, it'll crash with a access violation when you attempt to draw on the shader. Other drivers ignore this, as it's really a no-op.

https://www.opengl.org/discussion_boards/showthread.php/180761-Shader-glDrawArrays-crash-only-on-nVidia-Win32?p=1246956&viewfull=1#post1246956

Waiting for my tester to try now.

It's been tried on two ATI cards and works. Three geforce computers and it fails. Works on my quadro card.

fYi, I once had a bug related to this, when drawing and binding a VAO, that had no index and vertex bindings. So the VAO existed but was not configured. You might look in to this as well.

glGetError will only help, if the function you call at least returns. When it results in an access violation or whatever glGetError won't even be called. But its a good thing to do when generating,updating or binding buffers/textures/... If you not already did this, write a little macro, that automatically checks errors after GL calls when compiling with __DEBUG or something.

Good luck.

This topic is closed to new replies.

Advertisement