forked from edrosten/threeB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
spot_viewer.cfg
310 lines (251 loc) · 7.32 KB
/
spot_viewer.cfg
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
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
preprocess.skip=1
video_number=-1
dynamic_zoom.zoom=1
dynamic_zoom.min_sigma=1
function create_defaults
. ((f)).max_brightness=1
. ((f)).use_brightness=0
. ((f)).use_max_intensity=0
. ((f)).xoff=0
. ((f)).yoff=0
. ((f)).glow_scale=1
. ((f)).glow_sigma=.1
. ((f)).glow_power=1
. ((f)).glow_transparency=1
. ((f)).glow.ohot.gutter=.1
. ((f)).glow_map=hot
. ((f)).dynamic_zoom.use_fixed_scale=0
. ((f)).dynamic_zoom.fixed_scale=10
. ((f)).dynamic_zoom.scale_by_number=0
. ((f)).density_scale=1
. ((f)).density_scale.width=.4
. ((f)).density_scale.height=.05
. ((f)).density_scale.x=.1
. ((f)).linescan.normalize=1
. ((f)).density_scale.border.width=5
. ((f)).density_scale.border.color=[128 128 255 255]
endfunction
spots1.density_scale.y=.95
spots2.density_scale.y=.85
f=spots1
create_defaults
f=spots2
create_defaults
one=1
//() only strips one var per line. Hence the if hax
function create_widgets
. if_equal one 1
. . ((w)).AddToggleButton "Use Brightness" (f).use_brightness
. . ((w)).AddToggleButton "Use max intensity" (f).use_max_intensity
. . ((w)).AddMonitor "Maximum brightness" (f).max_brightness
. . ((w)).AddSlider (f).max_brightness 0 10
. . ((w)).AddMonitor "Maximum opacity" (f).glow_transparency
. . ((w)).AddSlider (f).glow_transparency 0 1
. . ((w)).AddToggleButton "Fixed scale" (f).dynamic_zoom.use_fixed_scale
. . ((w)).AddMonitor "Fixed scale" (f).dynamic_zoom.fixed_scale
. . ((w)).AddSlider (f).dynamic_zoom.fixed_scale 0 50
. . ((w)).AddMonitor "Glow range" (f).glow_scale
. . ((w)).AddSlider (f).glow_scale 1 20
. . ((w)).AddPushButton "Sigma=.4" (f).glow_sigma=.4
. . ((w)).AddMonitor "Pixelization" (f).pixelate.size
. . ((w)).AddSlider (f).pixelate.size 1 20
. . ((w)).AddPushButton "Hot" "(f).glow_map=hot"
. . ((w)).AddPushButton "Overlay hot" "(f).glow_map=ohot"
. . ((w)).AddPushButton "Grey" "(f).glow_map=grey"
. . ((w)).AddPushButton "Green" "(f).glow_map=green"
. . ((w)).AddPushButton "Red" "(f).glow_map=red"
. . ((w)).AddSlider (f).xoff -10 10
. . ((w)).AddSlider (f).yoff -10 10
. . watch ((f)).use_brightness motion
. . watch ((f)).use_max_intensity motion
. . watch ((f)).max_brightness motion
. . watch ((f)).glow_transparency motion
. . watch ((f)).dynamic_zoom.use_fixed_scale motion
. . watch ((f)).dynamic_zoom.fixed_scale motion
. . watch ((f)).glow_scale motion
. . watch ((f)).glow_sigma motion
. . watch ((f)).glow_map motion
. . watch ((f)).pixelate.size motion
. . watch ((f)).xoff motion
. . watch ((f)).yoff motion
. . watch ((f)).xoff linescan
. . watch ((f)).yoff linescan
. endif
endfunction
function s1_widgets
. w=spots1
. f=spots1
. GUI.AddWindow ((w)) "Spots 1 Controls"
. create_widgets
endfunction
function s2_widgets
. w=spots2
. f=spots2
. GUI.AddWindow ((w)) "Spots 2 Controls"
. create_widgets
endfunction
GUI.InitXInterface
GUI.AddWindow c Controls
//c.AddMonitor cross_size cross_size
//c.AddSlider cross_size 0 5
//c.AddMonitor linewidth linewidth
//c.AddSlider linewidth 0 5
//c.AddMonitor xoff xoff
//c.AddSlider xoff -10 10
//c.AddMonitor yoff yoff
//c.AddSlider yoff -10 10
//c.AddMonitor Zoom zoom_level
//c.AddSlider zoom_level -10 10
c.AddMonitor show show
c.AddSlider show 0 1
c.AddToggleButton "Play" play
c.AddPushButton "Rewind" show=0
c.AddPushButton "Nudge" next
c.AddPushButton "Prev" prev
c.AddPushButton "Save video" dump_a_video=1
c.AddToggleButton "Save widefield panel" dump.separate_widefield
c.AddMonitor "Image brightness" image_brightness
c.AddSlider image_brightness 1 10
//
// max_brightness=10
// c.AddToggleButton "Use Brightness" use_brightness
// c.AddToggleButton "Use max intensity" use_max_intensity
// c.AddMonitor "Maximum brightness" max_brightness
// c.AddSlider max_brightness 0 10
// //c.AddMonitor "Opacity" weighting
// //c.AddSlider weighting 0 1
//
//
// c.AddToggleButton "Glow scale" dynamic_zoom
// c.AddToggleButton "Transparent glow" hot_transparent
// c.AddMonitor "Maximum opacity" glow_transparency
// c.AddSlider glow_transparency 0 1
// c.AddToggleButton "Fixed scale" dynamic_zoom.use_fixed_scale
// c.AddMonitor "Fixed scale" dynamic_zoom.fixed_scale
// c.AddSlider dynamic_zoom.fixed_scale 0 10
// c.AddMonitor "Glow range" glow_scale
// c.AddSlider glow_scale 1 20
//
c.AddToggleButton "Glow scale" dynamic_zoom
c.AddToggleButton "Transparent glow" hot_transparent
c.AddPushButton "Dump density map" dump_density=1
c.AddPushButton "Linescan" line_mode=linescan
c.AddPushButton "Line normal data" "line_mode=normal points"
c.AddMonitor "Mode:" line_mode
normal_std=none
c.AddMonitor "STD:" normal_std
c.AddMonitor "Normal Width" normal_width
c.AddSlider normal_width 0 20
c.AddPushButton "Save linescan" save_linescan=1
linescan_length=none
c.AddMonitor "Number" save_linescan_num
c.AddMonitor "Linescan length" linescan_length
c.AddMonitor "FWHM" fwhm
fwhm.find=1
c.AddPushButton "Spots 1..." s1_widgets
c.AddPushButton "Spots 2..." s2_widgets
watch max_brightness
watch use_max_intensity
watch weighting
watch use_brightness
watch cross_size
watch xoff
watch yoff
watch show
watch linewidth
watch color
watch hot
watch glow_scale
watch glow_sigma
watch glow_zoom
watch glow_power
watch show_simulation
watch simulations.color
watch simulations.linewidth
watch simulations.cross_size
watch dynamic_zoom
watch dynamic_zoom.zoom
watch dynamic_zoom.min_sigma
watch dynamic_zoom.use_fixed_scale
watch dynamic_zoom.fixed_scale
watch dynamic_zoom.scale_by_number
watch zoom_level motion
watch hot_transparent motion
watch glow_transparency motion
watch normal_width motion
watch line_mode motion
watch line_mode motion
watch use_mean motion
watch mask.show motion
watch mask.color motion
watch mask.color mask_update
mask.color=[0 0 1 .5]
c.AddToggleButton "Sim" show_simulation
c.AddPushButton "Quit" keep_running=0
xoff=.5
yoff=.5
cross_size=.01
preprocess.lpf=5
glow_power=1
scalebar=1
scalebar.scale=200
scalebar.width=6
scalebar.color=[1 1 1]
scalebar.pos=[0.1 0.9]
watch scalebar.pos motion
watch scalebar.scale motion
watch scalebar motion
watch pixel_size_in_nm motion
watch pixel_size_in_nm linescan
simulations.color=[0 0 1 .5]
simulations.linewidth=2
simulations.cross_size=1
dynamic_zoom.zoom=1
dynamic_zoom.min_sigma=1
dynamic_zoom.use_fixed_scale=0
dynamic_zoom.fixed_scale=1
linescan.cross.color=[0 1 1]
linescan.cross.size=5
linescan.cross.width=1
linescan.line.color=[1 1 0]
linescan.normalarea.color=[0 0 1 .5]
linescan.line.width=1
linescan.points=1000
mask.color=[0 0 255 255]
watch linescan.points linescan
watch glow_scale linescan
watch glow_sigma linescan
watch glow_zoom linescan
watch glow_power linescan
watch normal_width linescan
watch line_mode linescan
watch save_linescan linescan
watch dynamic_zoom linescan
watch dynamic_zoom.zoom linescan
watch dynamic_zoom.min_sigma linescan
watch update_linescan linescan
watch show linescan
watch linescan.1 linescan
watch linescan.2 linescan
watch spots1.use_brightness linescan
watch spots1.use_max_intensity linescan
watch spots1.max_brightness linescan
watch spots2.use_brightness linescan
watch spots2.use_max_intensity linescan
watch spots2.max_brightness linescan
watch show image_to_show
watch use_mean image_to_show
watch image_brightness image_to_show
video_stub=/tmp/k000l2/vid-%02i-%03i.jpg
pixel_size_in_nm=10000000
watch pixel_size_in_nm motio
function rewind
. show=0
endfunction
// c.AddSlider xoff -3 3
// .AddSlider yoff -3 3
line_mode="newlinescan"
spots2.glow_power=0.5
spots2.glow_map=grey
s1_widgets
s2_widgets