(GLX) Hook up preliminary onscreen FPS (enabled by setting "Debug

Info Messages" in RGUI to ON
This commit is contained in:
twinaphex 2013-10-07 17:11:48 +02:00
parent be514e803a
commit 80079e297b

View File

@ -165,9 +165,14 @@ static void gfx_ctx_set_resize(unsigned width, unsigned height)
static void gfx_ctx_update_window_title(void)
{
gl_t *gl = (gl_t*)driver.video_data;
char buf[128];
if (gfx_get_fps(buf, sizeof(buf), false))
if (gfx_get_fps(buf, sizeof(buf), true))
XStoreName(g_dpy, g_win, buf);
if ((g_extern.lifecycle_mode_state & (1ULL << MODE_FPS_DRAW)) &&
gl->font_ctx)
msg_queue_push(g_extern.msg_queue, buf, 1, 1);
}
static void gfx_ctx_get_video_size(unsigned *width, unsigned *height)