mirror of
https://github.com/libretro/RetroArch
synced 2025-02-28 22:13:51 +00:00
Start isolating usage of driver->netplay_data to netplay.c
This commit is contained in:
parent
d4d07f674f
commit
67e8647acb
@ -1805,6 +1805,12 @@ bool netplay_driver_ctl(enum rarch_netplay_ctl_state state, void *data)
|
|||||||
|
|
||||||
switch (state)
|
switch (state)
|
||||||
{
|
{
|
||||||
|
case RARCH_NETPLAY_CTL_POST_FRAME:
|
||||||
|
netplay_post_frame((netplay_t*)driver->netplay_data);
|
||||||
|
break;
|
||||||
|
case RARCH_NETPLAY_CTL_PRE_FRAME:
|
||||||
|
netplay_pre_frame((netplay_t*)driver->netplay_data);
|
||||||
|
break;
|
||||||
case RARCH_NETPLAY_CTL_FLIP_PLAYERS:
|
case RARCH_NETPLAY_CTL_FLIP_PLAYERS:
|
||||||
{
|
{
|
||||||
bool *state = (bool*)data;
|
bool *state = (bool*)data;
|
||||||
|
@ -32,7 +32,9 @@ enum rarch_netplay_ctl_state
|
|||||||
{
|
{
|
||||||
RARCH_NETPLAY_CTL_NONE = 0,
|
RARCH_NETPLAY_CTL_NONE = 0,
|
||||||
RARCH_NETPLAY_CTL_FLIP_PLAYERS,
|
RARCH_NETPLAY_CTL_FLIP_PLAYERS,
|
||||||
RARCH_NETPLAY_CTL_FULLSCREEN_TOGGLE
|
RARCH_NETPLAY_CTL_FULLSCREEN_TOGGLE,
|
||||||
|
RARCH_NETPLAY_CTL_POST_FRAME,
|
||||||
|
RARCH_NETPLAY_CTL_PRE_FRAME
|
||||||
};
|
};
|
||||||
|
|
||||||
/* TODO: most of this, actually */
|
/* TODO: most of this, actually */
|
||||||
|
@ -1167,8 +1167,7 @@ int rarch_main_iterate(unsigned *sleep_ms)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_NETPLAY
|
#ifdef HAVE_NETPLAY
|
||||||
if (driver->netplay_data)
|
netplay_driver_ctl(RARCH_NETPLAY_CTL_PRE_FRAME, NULL);
|
||||||
netplay_pre_frame((netplay_t*)driver->netplay_data);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (bsv_movie_ctl(BSV_MOVIE_CTL_IS_INITED, NULL))
|
if (bsv_movie_ctl(BSV_MOVIE_CTL_IS_INITED, NULL))
|
||||||
@ -1214,8 +1213,7 @@ int rarch_main_iterate(unsigned *sleep_ms)
|
|||||||
bsv_movie_ctl(BSV_MOVIE_CTL_SET_FRAME_END, NULL);
|
bsv_movie_ctl(BSV_MOVIE_CTL_SET_FRAME_END, NULL);
|
||||||
|
|
||||||
#ifdef HAVE_NETPLAY
|
#ifdef HAVE_NETPLAY
|
||||||
if (driver->netplay_data)
|
netplay_driver_ctl(RARCH_NETPLAY_CTL_POST_FRAME, NULL);
|
||||||
netplay_post_frame((netplay_t*)driver->netplay_data);
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(HAVE_THREADS)
|
#if defined(HAVE_THREADS)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user