mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-12 21:10:42 +00:00
Update window params before processing context activate. Closes #2890
This commit is contained in:
@@ -147,14 +147,14 @@ CGLError GL_EXPORT_NAME(CGLSetCurrentContext)(CGLContextObj ctx)
|
||||
CGL.CGSGetSurfaceBounds(conn, window, surface, &rect);
|
||||
}
|
||||
|
||||
cglhook.driver.ActivateContext(data);
|
||||
|
||||
if(data.ctx)
|
||||
{
|
||||
GLInitParams ¶ms = cglhook.driver.GetInitParams(data);
|
||||
params.width = (uint32_t)rect.size.width;
|
||||
params.height = (uint32_t)rect.size.height;
|
||||
}
|
||||
|
||||
cglhook.driver.ActivateContext(data);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
||||
@@ -517,9 +517,9 @@ HOOK_EXPORT EGLBoolean EGLAPIENTRY eglMakeCurrent_renderdoc_hooked(EGLDisplay di
|
||||
|
||||
eglhook.driver.SetDriverType(eglhook.activeAPI);
|
||||
|
||||
eglhook.driver.ActivateContext(data);
|
||||
|
||||
eglhook.RefreshWindowParameters(data);
|
||||
|
||||
eglhook.driver.ActivateContext(data);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
||||
@@ -415,10 +415,10 @@ HOOK_EXPORT Bool glXMakeCurrent_renderdoc_hooked(Display *dpy, GLXDrawable drawa
|
||||
data.cfg = NULL;
|
||||
}
|
||||
|
||||
glxhook.driver.ActivateContext(data);
|
||||
|
||||
glxhook.UpdateWindowSize(data, dpy, drawable);
|
||||
|
||||
glxhook.driver.ActivateContext(data);
|
||||
|
||||
if(config)
|
||||
XFree(config);
|
||||
if(data.cfg)
|
||||
@@ -494,10 +494,10 @@ HOOK_EXPORT Bool glXMakeContextCurrent_renderdoc_hooked(Display *dpy, GLXDrawabl
|
||||
data.cfg = NULL;
|
||||
}
|
||||
|
||||
glxhook.driver.ActivateContext(data);
|
||||
|
||||
glxhook.UpdateWindowSize(data, dpy, draw);
|
||||
|
||||
glxhook.driver.ActivateContext(data);
|
||||
|
||||
if(config)
|
||||
XFree(config);
|
||||
if(data.cfg)
|
||||
|
||||
Reference in New Issue
Block a user