Merge pull request #1538 from heuripedes/gl-perf

(GLUI,XMB) Fix OSD
This commit is contained in:
Twinaphex 2015-03-25 17:43:42 +01:00
commit e0a0e25eb1
3 changed files with 13 additions and 13 deletions

View File

@ -354,7 +354,7 @@ static const struct font_glyph *gl_raster_font_get_glyph(
static void gl_flush_block(void *data)
{
gl_raster_t *font = (gl_raster_t*)data;
gl_raster_t *font = (gl_raster_t*)data;
gl_font_raster_block_t *block = font->block;
if (block->carr.coords.vertices)

View File

@ -359,6 +359,9 @@ static void glui_frame(void)
glui_render_background(settings, gl, glui, false);
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &glui->raster_block);
if (!menu_display_update_pending())
goto draw_text;
@ -480,7 +483,10 @@ static void glui_frame(void)
draw_text:
if (gl->font_driver->flush)
{
gl->font_driver->flush(gl->font_handle);
gl->font_driver->bind_block(gl->font_handle, NULL);
}
gl_set_viewport(gl, gl->win_width, gl->win_height, false, true);
}
@ -511,9 +517,6 @@ static void *glui_init(void)
glui = (glui_handle_t*)menu->userdata;
glui->textures.bg.id = 0;
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &glui->raster_block);
return menu;
error:
if (menu)
@ -621,9 +624,6 @@ static void glui_context_reset(void)
texture_image_free(&ti);
}
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &glui->raster_block);
}
static void glui_navigation_clear(bool pending_push)

View File

@ -1266,6 +1266,9 @@ static void xmb_frame(void)
if (!gl)
return;
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &xmb->raster_block);
xmb_frame_background(settings, gl, xmb, false);
xmb_draw_text(gl, xmb,
@ -1381,7 +1384,10 @@ static void xmb_frame(void)
}
if (gl->font_driver->flush)
{
gl->font_driver->flush(gl->font_handle);
gl->font_driver->bind_block(gl->font_handle, NULL);
}
if (settings->menu.mouse.enable)
xmb_draw_cursor(gl, xmb, menu->mouse.x, menu->mouse.y);
@ -1488,9 +1494,6 @@ static void *xmb_init(void)
if (global->core_info)
menu->categories.size = global->core_info->count + 1;
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &xmb->raster_block);
return menu;
error:
@ -1785,9 +1788,6 @@ static void xmb_context_reset(void)
else if (xmb->depth <= 1)
node->alpha = xmb->categories.passive.alpha;
}
if (gl->font_driver->bind_block)
gl->font_driver->bind_block(gl->font_handle, &xmb->raster_block);
}
static void xmb_navigation_clear(bool pending_push)