Merge pull request #2970 from t-paul/video-driver-init-fix

Ensure video_driver_frame_count is reset when the driver is (re-)initialized.
This commit is contained in:
Twinaphex 2016-05-08 19:01:12 +02:00
commit 1ced4bda11

View File

@ -426,9 +426,6 @@ static void init_video_input(const input_driver_t *tmp)
if (*input)
return;
/* Reset video frame count */
video_driver_frame_count = 0;
/* Video driver didn't provide an input driver,
* so we use configured one. */
RARCH_LOG("Graphics driver did not initialize an input driver. Attempting to pick a suitable driver.\n");
@ -689,6 +686,9 @@ static bool init_video(void)
video_driver_state.filter.out_rgb32 :
(video_driver_state.pix_fmt == RETRO_PIXEL_FORMAT_XRGB8888);
/* Reset video frame count */
video_driver_frame_count = 0;
tmp = input_get_ptr();
/* Need to grab the "real" video driver interface on a reinit. */
video_driver_find_driver();