ogl: fix single core crash

osx is missing, sorry but I'm too stupid for objective-c
This commit is contained in:
degasus
2013-04-11 03:32:07 +02:00
parent 6af14bd4ce
commit 3c87512180
8 changed files with 24 additions and 2 deletions

View File

@ -141,12 +141,17 @@ bool cInterfaceGLX::MakeCurrent()
#endif
return glXMakeCurrent(GLWin.dpy, GLWin.win, GLWin.ctx);
}
bool cInterfaceGLX::ClearCurrent()
{
return glXMakeCurrent(GLWin.dpy, None, NULL);
}
// Close backend
void cInterfaceGLX::Shutdown()
{
XWindow.DestroyXWindow();
if (GLWin.ctx && !glXMakeCurrent(GLWin.dpy, None, NULL))
NOTICE_LOG(VIDEO, "Could not release drawing context.");
if (GLWin.ctx)
{
glXDestroyContext(GLWin.dpy, GLWin.ctx);