fix xoverlay
This commit is contained in:
parent
89edbf8abf
commit
fbd16fb08e
@ -49,7 +49,9 @@ DEFINE_HOOKED_METHOD(SDL_GL_SwapWindow, void, SDL_Window *window)
|
||||
}
|
||||
{
|
||||
PROF_SECTION(SWAPWINDOW_tf2);
|
||||
//SDL_GL_MakeCurrent(window, tf2_sdl);
|
||||
#if EXTERNAL_DRAWING
|
||||
SDL_GL_MakeCurrent(window, tf2_sdl);
|
||||
#endif
|
||||
original::SDL_GL_SwapWindow(window);
|
||||
// glXMakeContextCurrent(wminfo.info.x11.display,
|
||||
// wminfo.info.x11.window,
|
||||
|
@ -77,8 +77,8 @@ void initialize()
|
||||
logging::Info("Xoverlay initialized");
|
||||
}
|
||||
xoverlay_show();
|
||||
context = SDL_GL_CreateContext(sdl_hooks::window);
|
||||
#else
|
||||
//context = SDL_GL_CreateContext(sdl_hooks::window);
|
||||
glClearColor(1.0, 0.0, 0.0, 0.5);
|
||||
glewExperimental = GL_TRUE;
|
||||
glewInit();
|
||||
@ -159,10 +159,9 @@ void draw_begin()
|
||||
PROF_SECTION(DRAWEX_draw_begin);
|
||||
#if EXTERNAL_DRAWING
|
||||
xoverlay_draw_begin();
|
||||
#else
|
||||
{
|
||||
PROF_SECTION(draw_begin__SDL_GL_MakeCurrent);
|
||||
//SDL_GL_MakeCurrent(sdl_hooks::window, context);
|
||||
// SDL_GL_MakeCurrent(sdl_hooks::window, context);
|
||||
}
|
||||
#endif
|
||||
{
|
||||
@ -179,12 +178,12 @@ void draw_end()
|
||||
PROF_SECTION(draw_end__glez_end);
|
||||
glez_end();
|
||||
}
|
||||
{
|
||||
PROF_SECTION(draw_end__SDL_GL_MakeCurrent);
|
||||
//SDL_GL_MakeCurrent(sdl_hooks::window, nullptr);
|
||||
}
|
||||
#if EXTERNAL_DRAWING
|
||||
xoverlay_draw_end();
|
||||
{
|
||||
PROF_SECTION(draw_end__SDL_GL_MakeCurrent);
|
||||
SDL_GL_MakeCurrent(sdl_hooks::window, nullptr);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user