mirror of
https://github.com/gnif/LookingGlass.git
synced 2024-12-22 21:43:40 +00:00
[client/opengl] removed extra calls to make the context current
This commit is contained in:
parent
b5cb796b7c
commit
a6b253197f
@ -294,12 +294,6 @@ bool lgr_opengl_on_mouse_shape(void * opaque, const LG_RendererCursor cursor, co
|
||||
if (!this || !this->initialized)
|
||||
return false;
|
||||
|
||||
if (SDL_GL_MakeCurrent(this->params.window, this->glContext) != 0)
|
||||
{
|
||||
DEBUG_ERROR("Failed to make the GL context current");
|
||||
return false;
|
||||
}
|
||||
|
||||
this->mouseType = cursor;
|
||||
switch(cursor)
|
||||
{
|
||||
@ -440,12 +434,6 @@ bool lgr_opengl_on_frame_event(void * opaque, const uint8_t * data, bool resampl
|
||||
if (!this || !this->initialized)
|
||||
return false;
|
||||
|
||||
if (SDL_GL_MakeCurrent(this->params.window, this->glContext) != 0)
|
||||
{
|
||||
DEBUG_ERROR("Failed to make the GL context current");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (++this->texIndex == VBO_BUFFERS)
|
||||
this->texIndex = 0;
|
||||
|
||||
@ -593,12 +581,6 @@ bool lgr_opengl_render(void * opaque)
|
||||
if (!this || !this->initialized)
|
||||
return false;
|
||||
|
||||
if (SDL_GL_MakeCurrent(this->params.window, this->glContext) != 0)
|
||||
{
|
||||
DEBUG_ERROR("Failed to make the GL context current");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (this->resizeWindow)
|
||||
{
|
||||
// setup the projection matrix
|
||||
|
Loading…
Reference in New Issue
Block a user