Open atenpas opened 4 years ago
Same issue here. I'm on Ubuntu 18.04, Python 3.6.12, and nvidia 435.21.
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/pyrender/offscreen.py", line 31, in __init__
self._create()
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/pyrender/offscreen.py", line 149, in _create
self._platform.init_context()
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/pyrender/platforms/egl.py", line 192, in init_context
self.make_current()
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/pyrender/platforms/egl.py", line 198, in make_current
self._egl_context
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/OpenGL/platform/baseplatform.py", line 402, in __call__
return self( *args, **named )
File "/home/huy/anaconda3/envs/softgym/lib/python3.6/site-packages/OpenGL/error.py", line 232, in glCheckError
baseOperation = baseOperation,
OpenGL.error.GLError: GLError(
err = 12290,
baseOperation = eglMakeCurrent,
cArguments = (
<OpenGL._opaque.EGLDisplay_pointer object at 0x7efdffc1ed90>,
<OpenGL._opaque.EGLSurface_pointer object at 0x7efdffbf18c8>,
<OpenGL._opaque.EGLSurface_pointer object at 0x7efdffbf18c8>,
<OpenGL._opaque.EGLContext_pointer object at 0x7efdffbb7d90>,
),
result = 0
)
In my case, my problem was creating the offscreen renderer within every loop (i.e., calling render = pyrender.OffscreenRenderer
). It works okay 'osmesa' as the pyopengl platform. But, for 'egl', it seems to have a problem with automatically get rid of opengl related things. So I just put renderer.delete()
that will call the self.delete()
of the OffscreenRenderer
inside the loop. Hope it helps.
@SuwoongHeo I don't understand what you saying. I got same rror:
/OpenGL/error.py", line 228, in glCheckError
raise GLError(
OpenGL.error.GLError: GLError(
err = 12290,
baseOperation = eglMakeCurrent,
cArguments = (
<OpenGL._opaque.EGLDisplay_pointer object at 0x7ff528e2ccc0>,
<OpenGL._opaque.EGLSurface_pointer object at 0x7ff528e2c2c0>,
<OpenGL._opaque.EGLSurface_pointer object at 0x7ff528e2c2c0>,
<OpenGL._opaque.EGLContext_pointer object at 0x7ff528e52bc0>,
),
result = 0
)
@SuwoongHeo I don't understand what you saying. I got same rror:
/OpenGL/error.py", line 228, in glCheckError raise GLError( OpenGL.error.GLError: GLError( err = 12290, baseOperation = eglMakeCurrent, cArguments = ( <OpenGL._opaque.EGLDisplay_pointer object at 0x7ff528e2ccc0>, <OpenGL._opaque.EGLSurface_pointer object at 0x7ff528e2c2c0>, <OpenGL._opaque.EGLSurface_pointer object at 0x7ff528e2c2c0>, <OpenGL._opaque.EGLContext_pointer object at 0x7ff528e52bc0>, ), result = 0 )
@jinfagang Just add renderer.delete()
at the next line of rgb, depth = renderer.render(scene, flags=pyrender.RenderFlags.RGBA)
as @SuwoongHeo said, that works for me.
I have the same issue (calling renderer.delete()
doesn't help).
It crashes the first time I instantiate OffscreenRenderer
.
After running offscreen rendering a few times, I get the following error.
I'm using EGL, i.e.,
PYOPENGL_PLATFORM=egl
, Python 3.7.5, nvidia-450 and Ubuntu 16.04.