Commit df4cb63a authored by sstucker's avatar sstucker
Browse files

InitAxesSDG loads colors from csv file on disk so user can set their own palette, max number

parent ad471a6d
Loading
Loading
Loading
Loading
+5 −21
Original line number Diff line number Diff line
function axesSDG = InitAxesSDG(handles)

p = [getAppDir(), 'SDGcolors.csv'];
rgb01 = csvread(p) / 255;
fprintf(['Loaded ', num2str(size(rgb01, 1)), ' colors from SDGcolors.csv.\n' ])

axesSDG = struct(...
                 'handles', struct(...
                                   'axes', handles.axesSDG, ...
@@ -8,26 +12,6 @@ axesSDG = struct(...
                                  ), ...
                 'iCh', [], ...
                 'iSrcDet', [], ...
                 'linecolor', [...
                               0.2  0.6  0.1;
                               1.0  0.5  0.0;
                               1.0  0.0  1.0;
                               0.5  0.5  1.0;
                               0.0  1.0  1.0;
                               1.0  0.0  0.0;
                               0.2  0.3  0.1;
                               0.8  0.6  0.6;
                               0.5  1.0  0.5;
                               0.5  1.0  1.0;
                               0.0  0.0  0.0;
                               0.2  0.2  0.2;
                               0.4  0.4  0.4;
                               0.6  0.6  0.6;
                               0.8  0.8  0.8 ...
                              ] ...
                 'linecolor', rgb01...
               );

% additional_colors = rand_seeded(345,10,3);
% axesSDG.linecolor(end+1:end+size(additional_colors,1),:) = additional_colors;

SDGcolors.csv

0 → 100644
+77 −0
Original line number Diff line number Diff line
51,153,25
255,127,0
255,0,255
127,127,255
0,255,255
255,0,0
51,76,25
204,153,153
127,255,127
127,255,255
0,0,0
51,51,51
102,102,102
153,153,153
204,204,204
152,109,92
131,46,208
80,199,65
64,64,209
155,187,55
214,73,222
87,161,67
144,95,232
205,170,60
76,40,154
225,135,47
76,107,224
222,72,42
67,187,206
225,55,90
86,193,144
159,52,171
56,97,33
221,59,164
66,131,86
220,120,217
140,133,45
42,29,107
156,181,114
115,45,131
210,168,123
82,80,164
160,96,42
88,136,220
152,49,35
120,174,221
193,57,107
135,180,172
144,40,106
67,119,111
161,115,217
102,85,31
164,149,218
38,61,38
229,125,177
16,35,39
228,138,103
41,33,74
215,105,106
30,52,70
205,155,161
76,27,85
147,146,112
163,94,162
64,46,28
185,151,189
55,23,28
92,132,160
106,41,36
67,88,144
98,92,68
92,26,59
,,
,,
,,
,,
,,