Small cleanup.
This commit is contained in:
parent
870ef37258
commit
46c214f964
8
gfx/gl.c
8
gfx/gl.c
|
@ -1415,8 +1415,8 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
|
||||||
else
|
else
|
||||||
glBindTexture(GL_TEXTURE_2D, gl->texture[gl->tex_index]);
|
glBindTexture(GL_TEXTURE_2D, gl->texture[gl->tex_index]);
|
||||||
|
|
||||||
|
// Have to reset rendering state which libretro core could easily have overridden.
|
||||||
#ifdef HAVE_FBO
|
#ifdef HAVE_FBO
|
||||||
// Data is already on GPU :) Have to reset some state however incase core changed it.
|
|
||||||
if (gl->hw_render_fbo_init)
|
if (gl->hw_render_fbo_init)
|
||||||
{
|
{
|
||||||
gl_update_input_size(gl, width, height, pitch, false);
|
gl_update_input_size(gl, width, height, pitch, false);
|
||||||
|
@ -1425,13 +1425,7 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
|
||||||
gl_bind_backbuffer();
|
gl_bind_backbuffer();
|
||||||
gl_set_viewport(gl, gl->win_width, gl->win_height, false, true);
|
gl_set_viewport(gl, gl->win_width, gl->win_height, false, true);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Have to reset rendering state which libretro core could easily have overridden.
|
|
||||||
#ifdef HAVE_FBO
|
|
||||||
if (gl->hw_render_fbo_init)
|
|
||||||
{
|
|
||||||
#ifndef HAVE_OPENGLES
|
#ifndef HAVE_OPENGLES
|
||||||
if (!gl->core_context)
|
if (!gl->core_context)
|
||||||
glEnable(GL_TEXTURE_2D);
|
glEnable(GL_TEXTURE_2D);
|
||||||
|
|
Loading…
Reference in New Issue