From: Kasper Thofte [mailto:email@example.com]
Sent: Tuesday, April 26, 2011 10:34 AM
Subject: [PyMOL] openGL/GLEW problems when embedding a PyMOL instance in aPyQt4 widget
Dear pymol user and developer community
I am trying to embed a pymol2.PyMOL instance in a PyQt4 widget.
I am using the latest beta v1.4.1 (although it still says v1.4.0 in layer0/Version.h, I assume you just forgot to update?). I use ubuntu on a macbook.
I got it to display a black window inside a PyQt4 app, and I was even able to produce som ugly little white square H atoms one time, plus som menus only half visible. Yes, kind of strange.
The problem is openGL related. When typing pymol -v at the command line, it tells me that my openGL version is pre 2.0, which is not true.
(Well, actually I wasn't entirely sure what precisely to look for in the synaptic package manager, but libqt4-opengl is v4:4.7.0, python-opengl is v3.0.1, python-qt4-gl is v4.7.4, freeglut3-dev is v2.6.0, libglew1.5-dev is, well v1.5.2 glutg3-dev is 3.7-25)
Anyway, when I runt the following code (which may also contain the source of the problem, I don't know):
def __init__(self, parent=None):
self.pymolInstance = pymol2.PyMOL()
app = QtGui.QApplication(sys.argv)
pymolWidget = PymolQWidget()
I get the following error message:
ShaderMgrInit-Error: Could not initialize GLEW:Missing GL version
which means that GLEW_OK!=err at line 145 in layer0/ShaderMgr.c, which means the glew hasn't been initialized, which is as far as I was able to get.
Needless to say, help would be greatly appreaciated.
University of Copenhagent