示例#1
0
 def _platform_free(self):
     """Frees resources associated with this context."""
     if self._context and self._context == osmesa.OSMesaGetCurrentContext():
         osmesa.OSMesaMakeCurrent(None, None, GL.GL_FLOAT, 0, 0)
     osmesa.OSMesaDestroyContext(self._context)
     self._buffer = None
     self._context = None
示例#2
0
文件: rungl.py 项目: samhu1989/PON
 def doneglmesa():
     global ctx
     if not (ctx is None):
         osmesa.OSMesaDestroyContext(ctx)