Search code examples
pyqtpyqt4pyopengl

pyopengl, glUseProgram, Access violation


I have made a program that draws some structures on a QtOpenGL.QGLWidget. It is working on all computers, that it has been tested on, except for a new windows machine with a NVidia Geforce 840m graphic card.

It fails on the command:

glUseProgram(0) 

with the error:

Traceback (most recent call last):
  ...
  File "C:\mmpe\programming\python\HAWC2Visualization\visualization_objects\visualization_object.py", line 116, in draw
  File "C:\WinPython-64bit-3.3.3.2\python-3.3.3.amd64\lib\site-packages\OpenGL\platform\baseplatform.py", line 379, in __call__
OSError
exception: access violation writing 0xFFFFFFFFDD0D6D50

glGetString(GL_VERSION) returns 4.3.0 on both working and non-working computers

Any idea on how to solve it or what to check


Solution

  • the PyQt4 version shipped with WinPython-64bit-3.3.3.2 may be a bit outdated. or your current graphic card and driver doesn't support a recent enough opengl version