call aglEnable(AGL_BUFFER_RECT) after setting the rect; fixes both drawing over all the other windows and missing redraw before first resize (patch 1758339)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47648 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -63,10 +63,6 @@ wxGLContext::wxGLContext(wxGLCanvas *win, const wxGLContext *other)
|
|||||||
other ? other->m_aglContext : NULL);
|
other ? other->m_aglContext : NULL);
|
||||||
if ( !m_aglContext )
|
if ( !m_aglContext )
|
||||||
wxLogAGLError("aglCreateContext");
|
wxLogAGLError("aglCreateContext");
|
||||||
|
|
||||||
return;
|
|
||||||
if ( !aglEnable(m_aglContext, AGL_BUFFER_RECT) )
|
|
||||||
wxLogAGLError("aglEnable(AGL_BUFFER_RECT)");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
wxGLContext::~wxGLContext()
|
wxGLContext::~wxGLContext()
|
||||||
@@ -365,6 +361,9 @@ void wxGLCanvas::SetViewport()
|
|||||||
if ( !aglSetInteger(context, AGL_BUFFER_RECT, parms) )
|
if ( !aglSetInteger(context, AGL_BUFFER_RECT, parms) )
|
||||||
wxLogAGLError("aglSetInteger(AGL_BUFFER_RECT)");
|
wxLogAGLError("aglSetInteger(AGL_BUFFER_RECT)");
|
||||||
|
|
||||||
|
if ( !aglEnable(context, AGL_BUFFER_RECT) )
|
||||||
|
wxLogAGLError("aglEnable(AGL_BUFFER_RECT)");
|
||||||
|
|
||||||
if ( !aglUpdateContext(context) )
|
if ( !aglUpdateContext(context) )
|
||||||
wxLogAGLError("aglUpdateContext");
|
wxLogAGLError("aglUpdateContext");
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user