Zandronum Chat @
Get the latest version: 3.0
Source Code

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0003770Zandronum[All Projects] Bugpublic2020-03-20 20:332020-03-20 20:33
Assigned To 
PlatformPCOSMicrosoft WindowsOS Version10
Product Version3.1 
Target VersionFixed in Version 
Summary0003770: SetDeviceGammaRamp() unreliable in multi-display setup
DescriptionThis issue is difficult to diagnose because so far 3 different systems have given me 3 different results. The problem is:

When there is more than one monitor connected to the system, SetDeviceGammaRamp() when called on a HDC obtained from GetDC() may fail and not set gamma at all. The observed problem is that the `gamma` CCMD doesn't work in OpenGL.

I can reproduce this problem with 100% repetition on my main Win 10 PC only if I connect a second monitor to my GPU. When I have just one monitor, there is no problem.

On my laptop (with Windows 7) I can reproduce a different problem with SetDeviceGammaRamp(): the function works as the gamma is set, but it returns FALSE as if it failed.

Pol M says that there is no problem at all on his computer.

I did some research in to this issue and it seems that SetDeviceGammaRamp() is more reliable if the HDC is not obtained from GetDC() but from CreateDC(). Using CreateDC() is also the way to control the monitors separately.

The problem is not present in the recent GZDoom versions. GZDoom doesn't call SetDeviceGammaRamp() anymore. It seems that they've converted to applying the gamma adjustments in the shaders.

There is also no problem in Zandronum's software mode at all.
Additional InformationHere's an app that has two examples:

1. Example 1 uses GetDC() (the same as Zandronum) and fails on my PC with more than one monitor
2. Example 2 uses CreateDC() and succeeds [^]

This problem may be the same problem that was reported in ticket 0002957.
Attached Files

- Relationships

-  Notes
There are no notes attached to this issue.

Issue Community Support
Only registered users can voice their support. Click here to register, or here to log in.
Supporters: No one explicitly supports this issue yet.
Opponents: No one explicitly opposes this issue yet.

- Issue History
Date Modified Username Field Change
2020-03-20 20:33 Zalewa New Issue

Questions or other issues? Contact Us.


Copyright © 2000 - 2020 MantisBT Team
Powered by Mantis Bugtracker