Jump to content
Eternal Lands Official Forums
Roja

EL Gamma

Recommended Posts

Whenever I log into EL(after restarting my computer), the EL gamma totally takes over and changes my screen colors for everything. If I log out of EL the gamma stays-but I don't want it to. I don't want it to change my system gamma at all but there doesn't seem to be away to disable it. The only way for me to get my screen colors back is to restart my computer.

 

So would someone be able to look over/fix the EL gamma code so it can do the following?

 

1. Make a button to totally disable EL gamma

2. After you close EL the EL gamma should quit and revert back to your normal system gamma

 

 

Learner helped me adjust the code so that if the value for gamma=0 then it would be disabled, and that seemed to work ok. But I think we need a "disable gamma" button in the interface to make it more intuitive. He also said that the code was kinda messy so perhaps someone can also clean it up--talk to him for more info on that :pickaxe:

Share this post


Link to post
Share on other sites

I posted about this behavior a year or two ago in the bugs section (can't find it now). I didn't notice the behavior after exiting EL (people actually exit EL ??!!??). But I notice the screen brightness change as I put the focus in EL or other applications. After a while it just stops, but I've never figured out why the brightness stops changing.

Share this post


Link to post
Share on other sites
I posted about this behavior a year or two ago in the bugs section (can't find it now). I didn't notice the behavior after exiting EL (people actually exit EL ??!!??). But I notice the screen brightness change as I put the focus in EL or other applications. After a while it just stops, but I've never figured out why the brightness stops changing.

I have witnessed the same behavior on boognish's screen when I visit him, but I don't have the problem myself. It may be connected to whatever X windows server he is using on his Linux box. Not sure.

 

Does anyone know what operating systems this affects?

Share this post


Link to post
Share on other sites

afaik gamma can't be done with certain windows alone. Which is why what Nathan said happens.

 

As for fixing Roja's problem, a visit into control panel (if windows) or using xrandr in nix Should solve the issue without reboot.

 

CP -> Display settings -> Dig around there until you find a gamma setting?

 

Well not sure how to use xrandr and change the gamma settings. (tbh all I know is how to change the resolution with it) Though the --help and man page seems to indicate that it is possible.

Share this post


Link to post
Share on other sites

I'm using windows

 

Raytray: no you can't just keep changing the system gamma to correct EL's taking over of it. That doesn't solve anything. Besides the system gamma doesn't show it as having been changed even.

Share this post


Link to post
Share on other sites

This is curious. The gamma setting appears to do nothing at all on my Linux (nvidia) desktop. The only machine I have window xp available is an ancient thinkpad laptop with a Radeon card. On this, under windows the default gamma of 1.0 leaves the gamma unchanged after starting the client. If I change the gamma value to something other than 1, all the desktop including the client gets effected. However, even if I leave the gamma value set not to 1, the desktop is restored to its proper gamma when I exit the client.

Share this post


Link to post
Share on other sites

Can't say I know a ton about this, but I think there are different layers of gamma in windows (desktop, application, and fullscreen application.) I suspect the client is affecting the wrong one, some how.... I too have had this issue and agree there's probably a way to clean it up in the code as other programs/games don't leave a permenant change after closing them... Wish I knew more about it =\

 

On an odd note, when I had to reinstall vista recently I got version 191.07 of nvidia's driver and this problem seems to have vanished (this driver was from MS, not downloaded from nvidia's site.) The other odd part is, with all previous versions of the driver there were "runndll" processes in task manager, these seem to be not needed as they're not present with this driver and yet I still get the nvidia control panel and all seems to be working (if not better than before....) This driver also seems to have eliminated the random crashes I used to have with previous nvidia drivers.

 

So, I suppose it's possible there's a driver issue included in this. It might be worth investigating the driver above (assuming you're using nvidia...) I would also suggest looking on nvidia's sight for a driver removal tool, to be sure the old driver is completely removed before installing the new one. I can't say for sure that this will help, but it might be worth trying :)

 

DB

Share this post


Link to post
Share on other sites

Ok, well at the very least would it be possible to add a "Disable EL gamma" button in the options so people who have problems can just use that?

Share this post


Link to post
Share on other sites
Ok, well at the very least would it be possible to add a "Disable EL gamma" button in the options so people who have problems can just use that?

Yes, that should be easy enough. Just to confirm. If your in-game gamma is set to 1.0, does it still change you desktop gamma setting?

Share this post


Link to post
Share on other sites

Yes it does. I always have it set to 1.0. So my desktop gamma = 1, and in EL = 1 too. Then when I log into EL everything gets lighter on my screen.

Share this post


Link to post
Share on other sites
Yes it does. I always have it set to 1.0. So my desktop gamma = 1, and in EL = 1 too. Then when I log into EL everything gets lighter on my screen.

Ah. I have just found a gamma setting on the XP desktop; you may have one too. Right-click the desktop and open the properties window. Select the "Settings" tab and click the "Advanced" button. I have a "Color" tab which includes a "Gamma" setting. For me this is currently set to 1.0; the same value as the EL setting. If I darken the screen by setting it to say 0.5 then start EL, the desktop is brightened - presumably because the client is setting gamma to 1.0. On exit from the client, it leaves the setting at 1.0. I can go back to the xp desktop setting and restore the values of 0.5 but I should not have too.

 

I'll add an option to disable gamma completely as you requested. However, I will also investigate why the client does not correctly restore gamma on exit.

Edited by bluap

Share this post


Link to post
Share on other sites

Thanks for looking into this bluap :)

 

I go into the Settings and I have a "color management" tab, which only contains a color profile that I can change to another one/remove/set as default. The only way I seem to be able to change the gamma is via nvidia's control panel.

Share this post


Link to post
Share on other sites
I go into the Settings and I have a "color management" tab, which only contains a color profile that I can change to another one/remove/set as default. The only way I seem to be able to change the gamma is via nvidia's control panel.

I've added a new option "Disable gamma adjustment" which simply turns off all gamma adjustment. The change is committed to CVS. I had a look at reading the current gamma value(s) during start-up with a view to restoring them on exit. However, the required command SDL_GetGamma() does not appear to be supported fully even though it is documented. There may be other ways to achieve the same function but I guess the disable option is the important change for now.

Share this post


Link to post
Share on other sites

Thank you! The button seems to work :rolleyes:

 

 

I think I found the system problem however... I always used Adobe Gamma to make a color profile. Well I tried using the nvidia color profile maker, it made a new profile and I deleted the old one there. After I did that/restarted/and logged into EL the gamma didn't change anymore! So it seems like it was a color profile issue for me.

Regardless it's good to have that button if you don't want to mess around with your color profiles.

Share this post


Link to post
Share on other sites
So.......is this an SDL bug that some of us get to put up with then?

From what I've heard, the new client won't even use SDL, which I consider a sort of boat anchor anyways. Most of the .net programming languages (afaik) already have the bit conversion functions built in (and many of the graphics functions) so SDL isn't really needed any more (I've had this conversation with the person writing the new code and he concurred.)

 

With any luck, this problem will be a non-issue with the new client ;)

 

DB

Share this post


Link to post
Share on other sites
From what I've heard......

You are entitled to your opinions no matter how distorted they sound to me.

So what will become of Linux and Mac support for the new client then?

 

Edit: connection issues cause a dupe...

Edited by bluap

Share this post


Link to post
Share on other sites
From what I've heard......

You are entitled to your opinions no matter how distorted they sound to me.

So what will become of Linux and Mac support for the new client then?

I'm also quite interested to hear the answer to this.

Share this post


Link to post
Share on other sites

I did some quick checking.

 

From what I see, the SDL functions referring to gamma talk about the screen and not a window or screen.

 

It could be that OpenGL does not have a window gamma function available.

 

Here is something for changing gamma without affecting other things on the screen. I don't know how well it applies to this situation. http://stackoverflow.com/questions/139012/...scene-in-opengl

 

The wikipedia page for OpenGL mentions Pixel Buffer Objects were added in 2006 and that there was another shading language version made in 2008. I don't know what all has been considered since the start of EL, so I mention these.

 

If the gamma functions in OpenGL and libSDL are for the entire screen, would it be possible to do gamma changes in the shader model or in the actual drawing of it or in the texture loading? If we reload and modify the textures when gamma is changed or something like that, would it work?

 

I hope this post isn't too useless. I can't claim to be an expert on rendering. I used to have an interest in it ages ago, but that is it. Hopefully, some of this blabbering will spark an idea in someone that does know the art of rendering.

Share this post


Link to post
Share on other sites
So.......is this an SDL bug that some of us get to put up with then?

From what I've heard, the new client won't even use SDL, which I consider a sort of boat anchor anyways. Most of the .net programming languages (afaik) already have the bit conversion functions built in (and many of the graphics functions) so SDL isn't really needed any more (I've had this conversation with the person writing the new code and he concurred.)

 

With any luck, this problem will be a non-issue with the new client :rolleyes:

 

DB

 

 

You heard wrong. The new client will still use SDL, and we are not touching .net

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

×