mirror of
https://github.com/libretro/RetroArch
synced 2025-03-25 16:44:01 +00:00
Get rid of 64-bit formatting warnings
This commit is contained in:
parent
3d6b29e97b
commit
83e0164c93
@ -179,6 +179,13 @@ bool video_monitor_fps_statistics(double *refresh_rate,
|
|||||||
* otherwise false.
|
* otherwise false.
|
||||||
*
|
*
|
||||||
**/
|
**/
|
||||||
|
|
||||||
|
#ifdef _WIN32
|
||||||
|
#define U64_SIGN "%I64u"
|
||||||
|
#else
|
||||||
|
#define U64_SIGN "%llu"
|
||||||
|
#endif
|
||||||
|
|
||||||
bool video_monitor_get_fps(char *buf, size_t size,
|
bool video_monitor_get_fps(char *buf, size_t size,
|
||||||
char *buf_fps, size_t size_fps)
|
char *buf_fps, size_t size_fps)
|
||||||
{
|
{
|
||||||
@ -209,14 +216,14 @@ bool video_monitor_get_fps(char *buf, size_t size,
|
|||||||
last_fps = TIME_TO_FPS(curr_time, new_time, FPS_UPDATE_INTERVAL);
|
last_fps = TIME_TO_FPS(curr_time, new_time, FPS_UPDATE_INTERVAL);
|
||||||
curr_time = new_time;
|
curr_time = new_time;
|
||||||
|
|
||||||
snprintf(buf, size, "%s || FPS: %6.1f || Frames: %lu",
|
snprintf(buf, size, "%s || FPS: %6.1f || Frames: " U64_SIGN,
|
||||||
global->title_buf, last_fps, frame_count);
|
global->title_buf, last_fps, (unsigned long long)frame_count);
|
||||||
ret = true;
|
ret = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (buf_fps)
|
if (buf_fps)
|
||||||
snprintf(buf_fps, size_fps, "FPS: %6.1f || Frames: %lu",
|
snprintf(buf_fps, size_fps, "FPS: %6.1f || Frames: " U64_SIGN,
|
||||||
last_fps, frame_count);
|
last_fps, (unsigned long long)frame_count);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user