-
Notifications
You must be signed in to change notification settings - Fork 10
/
Defaults.js
241 lines (198 loc) · 4.93 KB
/
Defaults.js
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
/** @module Defaults */
export default {
/**
* Diameter of all particles
* @type {number}
*/
CircleDiameter: 5,
/**
* Initial cluster pattern, if none is provided through local Settings
* @type {string},
*/
InitialClusterType: 'Random',
/**
* Location of new walkers
* @type {string}
*/
WalkerSource: 'Random',
/**
* Number of walkers allowed in each iteration
* @type {number}
*/
MaxWalkers: 5000,
/**
* Distance to edges to spawn new walkers within when using 'Edges' for WalkerSource
* @type {number}
*/
EdgeMargin: 0,
//=====================================================================
// PRUNING BEHAVIORS
//=====================================================================
/**
* Remove walkers that have been wandering around too much
* @type {boolean}
*/
PruneOldWalkers: false,
/**
* Maximum walker age before it is removed, if `PruneOldWalkers` is `true`, in numbers of iterations
* @type {number}
*/
MaxAge: 30,
/**
* Spawn new walkers when old ones are converted into clustered particles or pruned
* @type {boolean}
*/
ReplenishWalkers: false,
/**
* Remove walkers that have strayed too far from their original positions
* @type {boolean}
*/
PruneDistantWalkers: false,
/**
* Maximum distance before a walker is removed, if `PruneDistantWalkers` is enabled
* @type {number}
*/
MaxWanderDistance: 20,
//=====================================================================
// VARIABLE DIAMETER EFFECTS
//=====================================================================
/**
* Vary diameters by distance to center
* @type {boolean}
*/
VaryDiameterByDistance: false,
/**
* Vary diameters randomly
* @type {boolean}
*/
VaryDiameterRandomly: false,
//=====================================================================
// VISIBILITY OF OBJECTS
//=====================================================================
/**
* Visibility of clustered particles
* @type {boolean}
*/
ShowClusters: true,
/**
* Visibility of walkers
* @type {boolean}
*/
ShowWalkers: true,
/**
* Visibility of imported shapes
* @type {boolean}
*/
ShowShapes: true,
//=====================================================================
// BIAS EFFECT
//=====================================================================
/**
* Direction to move all walkers each iteration. Can be Top, Bottom, Left, Right, Center, Edges, Equator, or Meridian. All other values, including nothing, disable bias
* @type {string}
*/
BiasTowards: '',
/**
* Magnitude of walker bias force. Higher values mean faster movement.
* @type {number}
*/
BiasForce: 1,
/**
* Enable each walker to have it's own bias towards a point
* @type {boolean}
*/
UsePerWalkerBias: true,
//=====================================================================
// FRAME
//=====================================================================
/**
* Constrain sketch to a box centered on the screen
* @type {boolean}
*/
UseFrame: true,
/**
* Size of frame. Can be a single number, or an array of two numbers for width and height
* @type {number}
*/
FrameSize: 900,
//=====================================================================
// RENDERING EFFECTS
//=====================================================================
/**
* Enable the generation of lines between newly-clustered particles. Required for "Lines" render mode. Can be disabled for performance if needed.
* @type {boolean}
*/
CaptureLines: true,
/**
* Drawing method. Can be `Shapes` or `Lines`.
* @type {string}
*/
RenderMode: 'Shapes',
/**
* Draw stroke around circles/polygons
* @type {boolean}
*/
UseStroke: false,
//=====================================================================
// COLORS
//=====================================================================
/**
* Apply the colors defined below. `false` means black and white only.
* @type {boolean}
*/
UseColors: false,
/**
* Canvas background color
* @type {object}
*/
BackgroundColor: {
h: 230,
s: 20,
b: 40
},
/**
* Color of randomly-moving particles (walkers), when visible
* @type {object}
*/
WalkerColor: {
h: 200,
s: 30,
b: 44
},
/**
* Color of clustered particles, when visible
* @type {object}
*/
ClusterColor: {
h: 30,
s: 70,
b: 80
},
/**
* Color of custom imported SVG shapes, when visible
* @type {object}
*/
ShapeColor: {
h: 100,
s: 50,
b: 80
},
/**
* Color of lines when RenderMode is set to 'Lines'
* @type {object}
*/
LineColor: {
h: 10,
s: 70,
b: 100
},
/**
* Color of bounding frame, when enabled
* @type {object}
*/
FrameColor: {
h: 0,
s: 100,
b: 100
}
};