~kennylevinsen/wlsunset

93d7d01bad314d9ae1c0a45dc6c8e17fd6aad6ec — Kenny Levinsen 27 days ago bcbca9e
Give config gamma as double to set_temperature

The gamma argument to set_temperature was incorrectly typed as an int,
causing unfortunate rounding.
1 files changed, 1 insertions(+), 1 deletions(-)

M main.c
M main.c => main.c +1 -1
@@ 491,7 491,7 @@ static void fill_gamma_table(uint16_t *table, uint32_t ramp_size, double rw,
	}
}

static void set_temperature(struct wl_list *outputs, int temp, int gamma) {
static void set_temperature(struct wl_list *outputs, int temp, double gamma) {
	double rw, gw, bw;
	calc_whitepoint(temp, &rw, &gw, &bw);
	fprintf(stderr, "setting temperature to %d K\n", temp);