Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GLInterface: Use EXT_swap_control or MESA_swap_control over SGI #6536

Merged
merged 1 commit into from Mar 26, 2018
Merged

GLInterface: Use EXT_swap_control or MESA_swap_control over SGI #6536

merged 1 commit into from Mar 26, 2018

Conversation

stenzek
Copy link
Contributor

@stenzek stenzek commented Mar 26, 2018

The SGI extension does not define calling SwapInterval with a parameter of zero as valid. It was just lucky that drivers interpreted this as vsync off. The EXT_swap_control extension defines zero as a valid value.

Mesa does not appear to support the EXT variant, so we fall back to MESA_swap_control here, which also supports zero.

Fixes the frame rate being capped at the screen refresh rate without using vblank_mode=0 in Mesa.

The SGI extension does not define calling SwapInterval with a parameter
of zero as valid. It was just lucky that drivers interpreted this as
vsync off. The EXT_swap_control extension defines zero as a valid value.

Mesa does not appear to support the EXT variant, so we fall back to
MESA_swap_control here, which also supports zero.
Copy link
Member

@linkmauve linkmauve left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

And tested on both i965 and freedreno.

@stenzek
Copy link
Contributor Author

stenzek commented Mar 26, 2018

Also tested on NVIDIA's binary driver and radeonsi. Only driver left is fglrx/radeongpu-pro, but does anyone use that with Dolphin? Either way, I don't have hardware which can run that driver.

@degasus degasus merged commit 12b9931 into dolphin-emu:master Mar 26, 2018
@stenzek stenzek deleted the glx-swap-interval branch February 11, 2019 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants