mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-03-03 17:08:17 +00:00
(PS3) Move PS3-specific FPS printing code to ps3_ctx.c
This commit is contained in:
parent
7f238606c8
commit
53df912321
@ -24,6 +24,8 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "../gfx_common.h"
|
||||||
|
|
||||||
#ifndef __PSL1GHT__
|
#ifndef __PSL1GHT__
|
||||||
#include <sys/spu_initialize.h>
|
#include <sys/spu_initialize.h>
|
||||||
#endif
|
#endif
|
||||||
@ -186,8 +188,23 @@ static void gfx_ctx_set_resize(unsigned width, unsigned height) { }
|
|||||||
|
|
||||||
static void gfx_ctx_update_window_title(void)
|
static void gfx_ctx_update_window_title(void)
|
||||||
{
|
{
|
||||||
|
gl_t *gl = (gl_t*)driver.video_data;
|
||||||
char buf[128];
|
char buf[128];
|
||||||
|
|
||||||
gfx_get_fps(buf, sizeof(buf), false);
|
gfx_get_fps(buf, sizeof(buf), false);
|
||||||
|
|
||||||
|
if (g_extern.lifecycle_mode_state & (1ULL << MODE_FPS_DRAW) &&
|
||||||
|
gl->font_ctx)
|
||||||
|
{
|
||||||
|
#ifdef HAVE_LIBDBGFONT
|
||||||
|
font_params_t params = {0};
|
||||||
|
params.x = g_settings.video.msg_pos_x;
|
||||||
|
params.y = 0.56f;
|
||||||
|
params.scale = 1.04f;
|
||||||
|
params.color = WHITE;
|
||||||
|
gl->font_ctx->render_msg(gl, buf, ¶ms);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void gfx_ctx_get_video_size(unsigned *width, unsigned *height)
|
static void gfx_ctx_get_video_size(unsigned *width, unsigned *height)
|
||||||
|
23
gfx/gl.c
23
gfx/gl.c
@ -50,10 +50,6 @@
|
|||||||
|
|
||||||
#include "shader_common.h"
|
#include "shader_common.h"
|
||||||
|
|
||||||
#ifdef __CELLOS_LV2__
|
|
||||||
#define FPS_COUNTER
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef ANDROID
|
#ifdef ANDROID
|
||||||
#include "../frontend/frontend_android.h"
|
#include "../frontend/frontend_android.h"
|
||||||
#endif
|
#endif
|
||||||
@ -1493,25 +1489,6 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
|
|||||||
gl_draw_texture(gl);
|
gl_draw_texture(gl);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef FPS_COUNTER
|
|
||||||
if (lifecycle_mode_state & (1ULL << MODE_FPS_DRAW))
|
|
||||||
{
|
|
||||||
char fps_txt[128];
|
|
||||||
font_params_t params = {0};
|
|
||||||
|
|
||||||
gfx_get_fps(fps_txt, sizeof(fps_txt), true);
|
|
||||||
|
|
||||||
if (gl->font_ctx)
|
|
||||||
{
|
|
||||||
params.x = g_settings.video.msg_pos_x;
|
|
||||||
params.y = 0.56f;
|
|
||||||
params.scale = 1.04f;
|
|
||||||
params.color = WHITE;
|
|
||||||
gl->font_ctx->render_msg(gl, fps_txt, ¶ms);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (msg && gl->font_ctx)
|
if (msg && gl->font_ctx)
|
||||||
gl->font_ctx->render_msg(gl, msg, NULL);
|
gl->font_ctx->render_msg(gl, msg, NULL);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user