2020-09-13 01:22:18 +00:00
|
|
|
#ifndef _COLOR_MATH_H
|
|
|
|
#define _COLOR_MATH_H
|
|
|
|
|
2020-10-14 15:57:34 +00:00
|
|
|
#include "time.h"
|
|
|
|
|
|
|
|
struct sun {
|
|
|
|
time_t dawn;
|
|
|
|
time_t sunrise;
|
|
|
|
time_t sunset;
|
|
|
|
time_t dusk;
|
|
|
|
};
|
|
|
|
|
|
|
|
void calc_sun(struct tm *tm, double longitude, double latitude, struct sun *sun);
|
2020-09-13 01:22:18 +00:00
|
|
|
double clamp(double value);
|
|
|
|
void calc_whitepoint(int temp, double *rw, double *gw, double *bw);
|
|
|
|
|
|
|
|
#endif
|