Skip to content

Conversation

@maandree
Copy link
Contributor

@maandree maandree commented Apr 9, 2014

Sorry for making a huge monolithic patch, but it was required for my workflow.

This patch merges pull request #60, as it was needed for testing gamma-w32gdi.c
I also took the liberty of implementing issue #59.

As mentioned in #54 it should be possible to use multiple displays and multiple
adjustment methods. This patch allows for multiple displays concurrent, and
can easily (by my estimation) be rewritten to allow for multiple concurrent
adjustment methods. It also makes it easy for redshift-dbus (when it gets added)
to control the monitors individually. Additionally, it supports using lookup tables
both before and efter the standard adjustments have been applied. It does not
however yet provide any functions to ease this for redshift-dbus.

To allow the display to be selected from the command line I also change
the adjustment method option delimiter from : to ,, as : delimits the
host and the display index as well as appears in IPv6 addresses. For
consistency I also make this change for the provider method. And in my
opinion the arguments are now easier to read because of this.
I also put crtc before screen in the RandR method's help output, because
it is more probable that the user is intereseted in selection CRTC than screen.
Further, it is now possible to use crtc=all, screen=all and card=all.

It also reimplements pull request #49, and pull request #47 with the calibrations
being applyed absolutely last (after the lookup tables mentioned in the previous
paragraph.) Further it reimplements pull request #44.

It obsoletes pull request #29 by lettings the brightness limits be configurable at
compile time, with or without a maximum value. It also does this for gamma.
TRANSITION_LOW and TRANSITION_HIGH can also be configured at
compile time.

This patch also makes it easy for DBus client to implement the gamma adjustment
suggesting in issue #10, by having one addition gamma parameter in the adjustment
settings.

In addition to all this, only a select few warnings available in GCC will now
generate any warnings. And all adjustment method have been rewritten to
share a common base code.

maandree added 4 commits May 12, 2014 04:46
…iling C files) to .gitignore

Signed-off-by: Mattias Andrée <[email protected]>
…i method under X by (sloopyly) translating the calls to RandR calls

Signed-off-by: Mattias Andrée <[email protected]>
…ons when all monitors can have individual gamma corrections, remove it

Signed-off-by: Mattias Andrée <[email protected]>
… that it can be accessed from elsewhere, and make the compile-time configurable

Signed-off-by: Mattias Andrée <[email protected]>
@maandree
Copy link
Contributor Author

@jonls Lets move the discussion into its proper issue.
As it looks now, there are some small stuff that is done
first, but than colorramp is rewritten to use a new struct
will all settings but it is still accessed using the old
interface. Than gamma-common is implemented, this
step is difficult to split up but I will do my best. Then
redshift.c and gamma-dummy is updated to use gamma-common.
At this step it all other methods must be disabled when compiling
and than each method is rewritten in one commit each. These
rewrites are not too big. Then the old colorramp_fill is removed.
And then calibration perservation is implement, it is however
already implemented in colorramp and the struct with settings.

…, and make elevation constants compile-time configurable

Signed-off-by: Mattias Andrée <[email protected]>
@maandree maandree mentioned this pull request May 13, 2014
@maandree
Copy link
Contributor Author

@jonls I have split out 2 independent minor pull requests, and one pull request — #86 — with some commits that are mutually independent, parts of that pull request will be needed for this pull request.
When #86 is merged commit fde75ed can also be merged.
This commit resolves some warnings (I compile with as many warnings as possible), some of this warnings are not important but others have to do with correctness and reducing float-to-double promotion which slightly improves the performance. I am still working on subsequent commits.

@maandree
Copy link
Contributor Author

Lookup tables and the reimplementation of #47 have been split out to #87.

@maandree maandree closed this May 13, 2014
@maandree maandree reopened this May 13, 2014
@maandree
Copy link
Contributor Author

@jonls
I will be working on splitting up commit 01fa18a,
but the rest should be good now. However, be aware that GitHub orders the commits in
chronological order instead of the order they are linked to each other in the commit chain.

@maandree
Copy link
Contributor Author

@jonls I think this is ready now. Of course #86 should be updated for #83.

maandree added 11 commits May 16, 2014 06:51
…gamma-common.

When compiling, disable all other methods until they too have been rewritten to
use gamma-common.

Signed-off-by: Mattias Andrée <[email protected]>
Signed-off-by: Mattias Andrée <[email protected]>
Signed-off-by: Mattias Andrée <[email protected]>
Signed-off-by: Mattias Andrée <[email protected]>
@jonls
Copy link
Owner

jonls commented Dec 7, 2014

This pull request does too much at the same time so I'm closing this for now. I'll take a closer look at the pull requests that were split up.

@jonls jonls closed this Dec 7, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants