Gamma issue on Mac

Hello,

I installed the latest build on my retina Macbook Pro (OS X 10.11.3) and am having an issue with gamma in fullscreen mode. About 2 seconds after the game starts or after a vid_restart, the gamma settings appear to change and the game becomes darker. If I set r_gamma to a different value and then back to my preferred value things go back to normal again. (Also, as I’ve verified with a custom build, calling GLimp_SetGamma with the current s_gammatable corrects the situation as well.) My q3config.cfg has the following lines.

seta r_mode "-1"
seta r_fullscreen "1"
seta r_customwidth "1280"
seta r_customheight “800”

If I happen to set my resolution to 1280x800 LOWDPI before running ioquake3 (which is only possible using a 3rd party app like QuickRes) then the problem does not occur.

The problem persists if I delete q3config.cfg.

The problem does not occur with the opengl2 renderer.

Please let me know if I should provide more details. I’m set up to build the source so I can test code changes if need be.

Cheers,
-Nima

Hello again,

I’ve been working on this issue since yesterday. I updated the SDL library to the latest release (2.0.4) and this didn’t resolve the problem. I’ve also verified (using SDL_GetWindowGammaRamp() and some debug output) that the gamma table for the display is actually not changing between the time it is set to the correct values in GLimp_SetGamma (via SDL_SetWindowGammaRamp() called after /vid_restart) to when the game becomes dark. Nevertheless, reseting the gamma table to the correct values using SDL_SetWindowGammaRamp() (with the same values spit out by SDL_GetWindowGammaRamp()) corrects the brightness. It’s quite puzzling.

Cheers,
-Nima