Re: [PyOpenGL-Users] No valid context
Brought to you by:
mcfletch
From: physkets <phy...@tu...> - 2020-04-22 17:43:46
|
Okay, so with a lot of help from Florian Rhiem of pyGLFW, I was able to figure out that the issue was because of the wrong 'platform' being chosen. Wayland requires that the EGL platform be used, while the GLX platform was being used. So using the environment variable: `PYOPENGL_PLATFORM=egl` fixed this problem. To see the full discussion that lead to this, refer to: https://github.com/FlorianRhiem/pyGLFW/issues/49 I also found someone else who had a issue due to the same reason, and was equally stumped due to the error not pointing them in the right direction: https://stackoverflow.com/questions/42185728/why-is-glgenvertexarrays-undefined-in-pyopengl-when-using-gtkglarea Can the appropriate platform be used by detecting the environment appropriately? Possibly from the 'XDG_SESSION_TYPE' environment variable obtainable from `os.environ`? |