Mercurial > repos > blastem
diff render.h @ 1967:bd70f1e15684
Make netplay remote sync to network rather than audio or video so it doesn't drift out of sync with the host
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Fri, 08 May 2020 00:22:54 -0700 |
parents | c3c62dbf1ceb |
children | a042e046f7f2 |
line wrap: on
line diff
--- a/render.h Mon May 04 23:58:37 2020 -0700 +++ b/render.h Fri May 08 00:22:54 2020 -0700 @@ -65,6 +65,7 @@ #define RENDER_DPAD_LEFT SDL_HAT_LEFT #define RENDER_DPAD_RIGHT SDL_HAT_RIGHT #define render_relative_mouse SDL_SetRelativeMouseMode +typedef SDL_Thread* render_thread; #endif #endif @@ -93,6 +94,7 @@ typedef void (*drop_handler)(const char *filename); typedef void (*window_close_handler)(uint8_t which); typedef void (*ui_render_fun)(void); +typedef int (*render_thread_fun)(void*); uint32_t render_map_color(uint8_t r, uint8_t g, uint8_t b); void render_save_screenshot(char *path); @@ -135,6 +137,8 @@ void render_set_ui_fb_resize_handler(ui_render_fun resize); void render_video_loop(void); uint8_t render_should_release_on_exit(void); +void render_set_external_sync(uint8_t ext_sync_on); +uint8_t render_create_thread(render_thread *thread, const char *name, render_thread_fun fun, void *data); #endif //RENDER_H_