aboutsummaryrefslogtreecommitdiffstats
path: root/radharc.1
blob: dba26239ba8cd4e946d2f1cba435b5a162664aa1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
.TH RADHARC 1 radharc
.SH NAME
radharc \- Adjust display colour temperature after the Sun

.SH SYNOPSIS
.B radharc
[-M
.IR method ]
[-S
.IR site ]
[-c
.IR crtc "] ..."\,
[-R
.IR rule ]
[-p
.IR priority ]
[-f
.IR fade-in ]
[-F
.IR fade-out ]
[-h
.RI [ high-temp ][\fB@\fP high-elev ]]
[-l
.RI [ low-temp ][\fB@\fP low-elev ]]
[-W
.IR options "] ..."\,
(-L
.IR latitude : longitude
| -t
.I temperature
[-d] | -x)

.SH DESCRIPTION
.B radharc
adjusts the colour temperature of your monitor according
the the elevation of the Sun. This is intended to reduce
eye strain and reduce deplayed sleep phase syndrome.
.PP
.B radharc
is inspired by
.BR redshift (1)
but uses
.BR libcoopgamma (7)
to allow it to be used alongside other programs that also
modify the monitors colour output, as long as the also use
.RB libcoopgamma (7).

.SH OPTIONS
The following options are supported:
.TP
.BR -c \ \fIcrtc\fP
Apply the filter to the CRTC with the monitor whose EDID is crtc.
By default, the filter is applied to all monitors.

If
.I crtc
is
.RB ' ? ',
all available CRTC's are listed.
.TP
.B -d
Keep the process alive and remove the filter on death.
.TP
.BR -f \ \fIfade-in\fP
Set effect fade-in time (gradual application when the program
starts). The value is interpreted a real number of seconds.
.TP
.BR -F \ \fIfade-out\fP
Set effect fade-out time (gradual restoration when the program
stops). The value is interpreted a real number of seconds.
.TP
.BR -h \ [\fIhigh-temp\fP][ @ \fIhigh-evel\fP]
Selects that the colour temperature shall be
.I high-temp
Kelvins when the Sun's elevation is
.I high-evel
degrees or higher above the horizon.

This option only has effect when combined with the
.B -L
option.
.TP
.BR -l \ [\fIlow-temp\fP][ @ \fIlow-evel\fP]
Selects that the colour temperature shall be
.I low-temp
Kelvins when the Sun's elevation is
.I low-evel
degrees or lower above the horizon.

This option only has effect when combined with the
.B -L
option.
.TP
.BR -L \ \fIlatitude\fP : \fIlongitude\fP
Selects the location the Sun's elevation shall be calculated
for. The program will run until it is manually terminated and
continually readjust the colour temperature according the
the Sun's elevation. The latitude and longitude shall be
specified in decimal format. Positive numbers shall be used
GPS coordinates north of the equator and GPS coordinates
east of the prime meridian. Negative number shall be used
for GPS coordinates south of the equator and GPS coordinates
west of the prime meridian.
.TP
.BR -M \ \fImethod\fP
Adjustment method name or number. Recognised names include:
.TS
tab(:);
l l.
\fBdummy\fP:Dummy method
\fBrandr\fP:X RAndR
\fBvidmode\fP:X VidMode
\fBdrm\fP:Linux DRM
\fBgdi\fP:Windows GDI
\fBquartz\fP:Quartz Core Graphics
.TE

The adjustment methods are supported via
.BR libgamma (7).
Only methods that were enabled when
.B libgamma
was compiled will be supported.

If
.I method
is
.RB ' ? ',
all available adjustment methods are printed.
.TP
.BR -p \ \fIpriority\fP
Set the priority of the filter. Filters with higher priority
are applied before filters with lower priority. The value must
be a signed 64-bit integer (between -9223372036854775807 and
9223372036854775807).
.BR radharc 's
default priority is -2305843009213693952.

If
.I priority
is
.RB ' ? ',
the utility's default priority is printed.
.TP
.BR -R \ \fIrule\fP
Set the rule of the filter to
.IR rule .
This is the last part of the filter's identifier
(class). The default rule is
.BR standard .
.TP
.BR -S \ \fIsite\fP
Select the site to which to connect. For example
.RB ' :0 ',
for local display 0 when using X.
.TP
.BR -t \ \fItemperature\fP
Colour temperature, in Kelvins, to apply.

If
.I temperature
is
.RB ' ? '
or
.RB ' get ',
the utility will print the currently applied temperature.
.TP
.BR -W \ \fIoptions\fP
Comma-separated list of implementation-specific options.

Supported options are:

.RS
.TP
.BI linear= value
If
.I value
is
.RB ' yes ',
the effect will be surrounded by an effect equivalent
to that of
.BR cg-linear (1).
The two effects will be applied as one.

If
.I  value
is
.RB ' no ',
the above will not be done.
.TP
.BI socket= name
Select name (abstract address) of the socket created
for IPC functionality.

If
.I name
is
.RB ' - ',
the standard input will be used, and must be a bound
.BR unix (7)
datagam socket.

If not specified, and no-socket has not been
specified, a default string will be used, being
defined by the pattern
.RS
.nf
\fB\(dq/proc/%u/%s\(dq,\fP <\fIPID\fP>\fB,\fP <\fIclass\fP>
.fi
.RE

Any comma
.RB ( , )
will be interpeted as part of
.IR name .
.TP
.B no-socket
Do not create a socket for IPC functionality.
.RE
.TP
.B -x
Remove the currently applied filter.

.SH OPERANDS
No operands are supported.

.SH SIGNALS
The following signals have non-default meaning:
.TP
.B SIGINT
Gradually fade out the effect and terminate the process.

If the fade out time is 0 (default) or if the signal is
sent twice, the effect is removed immediately.
.TP
.B SIGHUP
Terminate the process after any current fade in or fade
out action, but leaf the effect in place.
.TP
.B SIGUSR1
Gradually fade out the effect but do not terminate the process.

If the fade out time is 0 (default) or if the signal is
sent twice, the effect is removed immediately.
.TP
.B SIGUSR2
Gradually fade the effect back in (from
.IR SIGUSR1 ).

If the fade in time is 0 (default) or if the signal is
sent twice, the effect is restored immediately.

If sent during the initial fade in, the fade in is cancelled
and the full effect is immediately applied.

.SH STDOUT
The standard output is normally not used, however if
.I temperature
has been specified with
.RB ' get '
or
.RB ' ? ',
the colour temperature that was set before when the
program started is printed to standard output on the
following format:
.P
.RS
.nf
\fB\(dq%uK\en\(dq, \fP<\fIpreapplied temperature\fP>
.fi
.RE
.P
where it is garanteed that
.I preapplied temperature
is within [1000, 40000].

.SH SEE ALSO
.BR radharc-ipc (1),
.BR coopgammad (1),
.BR cg-tools (7),
.BR redshift (1),
.BR blueshift (1)