Re: [PyOpenGL-Users] Using PyopenGL with GLArea
Brought to you by:
mcfletch
From: Matti K. <mat...@gm...> - 2017-02-12 20:20:06
|
I tried to have a look at your code, but I don't have the `gi' package on my machine, and `pip install gi' can't find it either. 1) Would you accept help in the form of a program that starts with `from OpenGL import GLUT' , or does your problem require gi? As for the error you posted, looking at https://mesamatrix.net/ I see that glGenVertexArrays is a part of OpenGL 3.0, extension GL_ARB_vertex_array_object which seems to have broad support. 2) Maybe your graphics device (or its driver) is ancient? Since your gist seems to indicate you are using GTK, I assume you are running this under Linux. You may want to look into running PyOpenGL under mesa, using one of their software renderers if for whatever reason you don't have OpenGL3.0 support. Using the mesa CPU renderer under Linux: http://www.mattikariluoma.com/blog/Headless%20Rendered%20OpenGL%20Scenes.html >From: Oliver Marks <oly@di...> - 2017-02-11 22:40:09 > >Thought i would have a stab at trying to make this work, I cant find any >existing working examples. > >I have linked a gist if any one want to try. > >currently I am getting this error. > >OpenGL.error.NullFunctionError: Attempt to call an undefined function >glGenVertexArrays, check for bool(glGenVertexArrays) before calling > >Which to me sounds like its not available to the context, GLArea is >supplying the context so i am unsure why this would be ? > >Any ideas or can anyone give me some pointers ? > >https://gist.github.com/olymk2/5b3e49ac83130e580bd9983f2e5d49c3 > |