mirror of
https://github.com/libretro/RetroArch
synced 2025-03-30 16:20:27 +00:00
Create video_driver_get_frame_count
This commit is contained in:
parent
ae408a1d41
commit
5aeb906065
@ -263,6 +263,24 @@ uintptr_t video_driver_get_current_framebuffer(void)
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint64_t video_driver_get_frame_count(void)
|
||||
{
|
||||
static bool warn_once = true;
|
||||
driver_t *driver = driver_get_ptr();
|
||||
const video_poke_interface_t *poke = video_driver_get_poke_ptr();
|
||||
|
||||
if (!poke || !poke->get_frame_count)
|
||||
{
|
||||
if (warn_once)
|
||||
{
|
||||
RARCH_WARN("Frame count not implemented!\n");
|
||||
warn_once = false;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
return poke->get_frame_count(driver->video_data);
|
||||
}
|
||||
|
||||
retro_proc_address_t video_driver_get_proc_address(const char *sym)
|
||||
{
|
||||
driver_t *driver = driver_get_ptr();
|
||||
|
@ -340,6 +340,8 @@ const char *video_driver_get_ident(void);
|
||||
bool video_driver_set_viewport(unsigned width, unsigned height,
|
||||
bool force_fullscreen, bool allow_rotate);
|
||||
|
||||
uint64_t video_driver_get_frame_count(void);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user