Merge pull request #2271 from Monroe88/patch-1

(wgl_ctx) Also account for swap interval when setting fullscreen refresh rate
This commit is contained in:
Twinaphex 2015-10-22 02:59:55 +02:00
commit 260f2f713c

View File

@ -489,9 +489,9 @@ static bool gfx_ctx_wgl_set_video_mode(void *data,
/* Windows only reports the refresh rates for modelines as
* an integer, so video.refresh_rate needs to be rounded. Also, account
* for black frame insertion using video.refresh_rate set to half
* of the display refresh rate. */
* of the display refresh rate, as well as higher vsync swap intervals. */
refresh_mod = settings->video.black_frame_insertion ? 2.0f : 1.0f;
refresh = round(settings->video.refresh_rate * refresh_mod);
refresh = round(settings->video.refresh_rate * refresh_mod * settings->video.swap_interval);
windowed_full = settings->video.windowed_fullscreen;