Advertisement

getting the monitors refresh rate

Started by October 26, 2012 09:38 PM
0 comments, last by Saruman 12 years, 1 month ago
Is there any way to get the monitor's refresh rate in hz using SDL? I assumed it would be in SDL_GetVideoInfo() but it's unfortunately I was wrong. I'm using SDL 1.2.

Thanks in advance.
I'm not sure about 1.2 but in version 1.3 you can call:
[source lang="cpp"]SDL_DisplayMode mode;
SDL_GetDisplayMode(mode_index, &mode);
[/source]
Which will give you the SDL_DisplayMode struct containing format, width, height, refresh rate.

This topic is closed to new replies.

Advertisement