@bitbybit-dev/base 0.19.8 → 0.19.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/babel.config.cjs +1 -0
- package/babel.config.d.cts +5 -0
- package/index.d.ts +1 -0
- package/{index.ts → index.js} +1 -2
- package/lib/api/index.js +1 -0
- package/lib/api/inputs/base-inputs.d.ts +35 -0
- package/lib/api/inputs/base-inputs.js +1 -0
- package/lib/api/inputs/{color-inputs.ts → color-inputs.d.ts} +26 -48
- package/lib/api/inputs/color-inputs.js +164 -0
- package/lib/api/inputs/index.js +9 -0
- package/lib/api/inputs/inputs.js +9 -0
- package/lib/api/inputs/{lists-inputs.ts → lists-inputs.d.ts} +91 -190
- package/lib/api/inputs/lists-inputs.js +576 -0
- package/lib/api/inputs/{logic-inputs.ts → logic-inputs.d.ts} +24 -46
- package/lib/api/inputs/logic-inputs.js +111 -0
- package/lib/api/inputs/{math-inputs.ts → math-inputs.d.ts} +53 -97
- package/lib/api/inputs/math-inputs.js +391 -0
- package/lib/api/inputs/{point-inputs.ts → point-inputs.d.ts} +77 -168
- package/lib/api/inputs/point-inputs.js +521 -0
- package/lib/api/inputs/text-inputs.d.ts +83 -0
- package/lib/api/inputs/text-inputs.js +120 -0
- package/lib/api/inputs/{transforms-inputs.ts → transforms-inputs.d.ts} +35 -64
- package/lib/api/inputs/transforms-inputs.js +200 -0
- package/lib/api/inputs/{vector-inputs.ts → vector-inputs.d.ts} +48 -104
- package/lib/api/inputs/vector-inputs.js +304 -0
- package/lib/api/services/color.d.ts +114 -0
- package/lib/api/services/{color.ts → color.js} +15 -34
- package/lib/api/services/geometry-helper.d.ts +15 -0
- package/lib/api/services/{geometry-helper.ts → geometry-helper.js} +31 -43
- package/lib/api/services/{index.ts → index.d.ts} +1 -1
- package/lib/api/services/index.js +9 -0
- package/lib/api/services/lists.d.ts +287 -0
- package/lib/api/services/{lists.ts → lists.js} +59 -83
- package/lib/api/services/logic.d.ts +99 -0
- package/lib/api/services/{logic.ts → logic.js} +24 -32
- package/lib/api/services/math.d.ts +349 -0
- package/lib/api/services/{math.ts → math.js} +71 -136
- package/lib/api/services/point.d.ts +222 -0
- package/lib/api/services/{point.ts → point.js} +32 -67
- package/lib/api/services/text.d.ts +69 -0
- package/lib/api/services/{text.ts → text.js} +7 -17
- package/lib/api/services/transforms.d.ts +122 -0
- package/lib/api/services/{transforms.ts → transforms.js} +37 -83
- package/lib/api/services/vector.d.ts +320 -0
- package/lib/api/services/{vector.ts → vector.js} +42 -80
- package/lib/{index.ts → index.d.ts} +0 -1
- package/lib/index.js +1 -0
- package/package.json +1 -1
- package/lib/api/inputs/base-inputs.ts +0 -18
- package/lib/api/inputs/text-inputs.ts +0 -108
- package/lib/api/services/color.test.ts +0 -86
- package/lib/api/services/lists.test.ts +0 -612
- package/lib/api/services/logic.test.ts +0 -187
- package/lib/api/services/math.test.ts +0 -622
- package/lib/api/services/text.test.ts +0 -55
- package/lib/api/services/vector.test.ts +0 -360
- package/tsconfig.bitbybit.json +0 -26
- package/tsconfig.json +0 -24
- /package/lib/api/{index.ts → index.d.ts} +0 -0
- /package/lib/api/inputs/{index.ts → index.d.ts} +0 -0
- /package/lib/api/inputs/{inputs.ts → inputs.d.ts} +0 -0
|
@@ -1,14 +1,8 @@
|
|
|
1
|
-
/* eslint-disable @typescript-eslint/no-namespace */
|
|
2
1
|
import { Base } from "./base-inputs";
|
|
3
2
|
import { Math } from "./inputs";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export class TwoVectorsDto {
|
|
8
|
-
constructor(first?: number[], second?: number[]) {
|
|
9
|
-
if (first !== undefined) { this.first = first; }
|
|
10
|
-
if (second !== undefined) { this.second = second; }
|
|
11
|
-
}
|
|
3
|
+
export declare namespace Vector {
|
|
4
|
+
class TwoVectorsDto {
|
|
5
|
+
constructor(first?: number[], second?: number[]);
|
|
12
6
|
/**
|
|
13
7
|
* First vector
|
|
14
8
|
* @default undefined
|
|
@@ -20,21 +14,16 @@ export namespace Vector {
|
|
|
20
14
|
*/
|
|
21
15
|
second: number[];
|
|
22
16
|
}
|
|
23
|
-
|
|
24
|
-
constructor(vector?: boolean[])
|
|
25
|
-
if (vector !== undefined) { this.vector = vector; }
|
|
26
|
-
}
|
|
17
|
+
class VectorBoolDto {
|
|
18
|
+
constructor(vector?: boolean[]);
|
|
27
19
|
/**
|
|
28
20
|
* Vector of booleans
|
|
29
21
|
* @default undefined
|
|
30
22
|
*/
|
|
31
23
|
vector: boolean[];
|
|
32
24
|
}
|
|
33
|
-
|
|
34
|
-
constructor(vectors?: number[][], tolerance?: number)
|
|
35
|
-
if (vectors !== undefined) { this.vectors = vectors; }
|
|
36
|
-
if (tolerance !== undefined) { this.tolerance = tolerance; }
|
|
37
|
-
}
|
|
25
|
+
class RemoveAllDuplicateVectorsDto {
|
|
26
|
+
constructor(vectors?: number[][], tolerance?: number);
|
|
38
27
|
/**
|
|
39
28
|
* Vectors array
|
|
40
29
|
* @default undefined
|
|
@@ -46,14 +35,10 @@ export namespace Vector {
|
|
|
46
35
|
* @minimum 0
|
|
47
36
|
* @maximum Infinity
|
|
48
37
|
*/
|
|
49
|
-
tolerance
|
|
38
|
+
tolerance: number;
|
|
50
39
|
}
|
|
51
|
-
|
|
52
|
-
constructor(vectors?: number[][], checkFirstAndLast?: boolean, tolerance?: number)
|
|
53
|
-
if (vectors !== undefined) { this.vectors = vectors; }
|
|
54
|
-
if (checkFirstAndLast !== undefined) { this.checkFirstAndLast = checkFirstAndLast; }
|
|
55
|
-
if (tolerance !== undefined) { this.tolerance = tolerance; }
|
|
56
|
-
}
|
|
40
|
+
class RemoveConsecutiveDuplicateVectorsDto {
|
|
41
|
+
constructor(vectors?: number[][], checkFirstAndLast?: boolean, tolerance?: number);
|
|
57
42
|
/**
|
|
58
43
|
* Vectors array
|
|
59
44
|
* @default undefined
|
|
@@ -63,29 +48,25 @@ export namespace Vector {
|
|
|
63
48
|
* Check first and last vectors
|
|
64
49
|
* @default false
|
|
65
50
|
*/
|
|
66
|
-
checkFirstAndLast
|
|
51
|
+
checkFirstAndLast: boolean;
|
|
67
52
|
/**
|
|
68
53
|
* Tolerance value
|
|
69
54
|
* @default 1e-7
|
|
70
55
|
* @minimum 0
|
|
71
56
|
* @maximum Infinity
|
|
72
57
|
*/
|
|
73
|
-
tolerance
|
|
58
|
+
tolerance: number;
|
|
74
59
|
}
|
|
75
|
-
|
|
76
|
-
constructor(vector?: number[])
|
|
77
|
-
if (vector !== undefined) { this.vector = vector; }
|
|
78
|
-
}
|
|
60
|
+
class VectorDto {
|
|
61
|
+
constructor(vector?: number[]);
|
|
79
62
|
/**
|
|
80
63
|
* Vector array of numbers
|
|
81
64
|
* @default undefined
|
|
82
65
|
*/
|
|
83
66
|
vector: number[];
|
|
84
67
|
}
|
|
85
|
-
|
|
86
|
-
constructor(max?: number)
|
|
87
|
-
if (max !== undefined) { this.max = max; }
|
|
88
|
-
}
|
|
68
|
+
class RangeMaxDto {
|
|
69
|
+
constructor(max?: number);
|
|
89
70
|
/**
|
|
90
71
|
* Maximum range boundary
|
|
91
72
|
* @default 10
|
|
@@ -95,12 +76,8 @@ export namespace Vector {
|
|
|
95
76
|
*/
|
|
96
77
|
max: number;
|
|
97
78
|
}
|
|
98
|
-
|
|
99
|
-
constructor(x?: number, y?: number, z?: number)
|
|
100
|
-
if (x !== undefined) { this.x = x; }
|
|
101
|
-
if (y !== undefined) { this.y = y; }
|
|
102
|
-
if (z !== undefined) { this.z = z; }
|
|
103
|
-
}
|
|
79
|
+
class VectorXYZDto {
|
|
80
|
+
constructor(x?: number, y?: number, z?: number);
|
|
104
81
|
/**
|
|
105
82
|
* X value of vector
|
|
106
83
|
* @default 0
|
|
@@ -126,11 +103,8 @@ export namespace Vector {
|
|
|
126
103
|
*/
|
|
127
104
|
z: number;
|
|
128
105
|
}
|
|
129
|
-
|
|
130
|
-
constructor(x?: number, y?: number)
|
|
131
|
-
if (x !== undefined) { this.x = x; }
|
|
132
|
-
if (y !== undefined) { this.y = y; }
|
|
133
|
-
}
|
|
106
|
+
class VectorXYDto {
|
|
107
|
+
constructor(x?: number, y?: number);
|
|
134
108
|
/**
|
|
135
109
|
* X value of vector
|
|
136
110
|
* @default 0
|
|
@@ -148,12 +122,8 @@ export namespace Vector {
|
|
|
148
122
|
*/
|
|
149
123
|
y: number;
|
|
150
124
|
}
|
|
151
|
-
|
|
152
|
-
constructor(step?: number, min?: number, max?: number)
|
|
153
|
-
if (step !== undefined) { this.step = step; }
|
|
154
|
-
if (min !== undefined) { this.min = min; }
|
|
155
|
-
if (max !== undefined) { this.max = max; }
|
|
156
|
-
}
|
|
125
|
+
class SpanDto {
|
|
126
|
+
constructor(step?: number, min?: number, max?: number);
|
|
157
127
|
/**
|
|
158
128
|
* Step of the span
|
|
159
129
|
* @default 0.1
|
|
@@ -161,7 +131,7 @@ export namespace Vector {
|
|
|
161
131
|
* @maximum Infinity
|
|
162
132
|
* @step 0.1
|
|
163
133
|
*/
|
|
164
|
-
step
|
|
134
|
+
step: number;
|
|
165
135
|
/**
|
|
166
136
|
* Min value of the span
|
|
167
137
|
* @default 0
|
|
@@ -169,7 +139,7 @@ export namespace Vector {
|
|
|
169
139
|
* @maximum Infinity
|
|
170
140
|
* @step 1
|
|
171
141
|
*/
|
|
172
|
-
min
|
|
142
|
+
min: number;
|
|
173
143
|
/**
|
|
174
144
|
* Max value of the span
|
|
175
145
|
* @default 1
|
|
@@ -177,15 +147,10 @@ export namespace Vector {
|
|
|
177
147
|
* @maximum Infinity
|
|
178
148
|
* @step 1
|
|
179
149
|
*/
|
|
180
|
-
max
|
|
150
|
+
max: number;
|
|
181
151
|
}
|
|
182
|
-
|
|
183
|
-
constructor(nrItems?: number, min?: number, max?: number, ease?: Math.easeEnum)
|
|
184
|
-
if (nrItems !== undefined) { this.nrItems = nrItems; }
|
|
185
|
-
if (min !== undefined) { this.min = min; }
|
|
186
|
-
if (max !== undefined) { this.max = max; }
|
|
187
|
-
if (ease !== undefined) { this.ease = ease; }
|
|
188
|
-
}
|
|
152
|
+
class SpanEaseItemsDto {
|
|
153
|
+
constructor(nrItems?: number, min?: number, max?: number, ease?: Math.easeEnum);
|
|
189
154
|
/**
|
|
190
155
|
* Nr of items in the span
|
|
191
156
|
* @default 100
|
|
@@ -193,7 +158,7 @@ export namespace Vector {
|
|
|
193
158
|
* @maximum Infinity
|
|
194
159
|
* @step 1
|
|
195
160
|
*/
|
|
196
|
-
nrItems
|
|
161
|
+
nrItems: number;
|
|
197
162
|
/**
|
|
198
163
|
* Min value of the span
|
|
199
164
|
* @default 0
|
|
@@ -201,7 +166,7 @@ export namespace Vector {
|
|
|
201
166
|
* @maximum Infinity
|
|
202
167
|
* @step 1
|
|
203
168
|
*/
|
|
204
|
-
min
|
|
169
|
+
min: number;
|
|
205
170
|
/**
|
|
206
171
|
* Max value of the span
|
|
207
172
|
* @default 1
|
|
@@ -209,24 +174,20 @@ export namespace Vector {
|
|
|
209
174
|
* @maximum Infinity
|
|
210
175
|
* @step 1
|
|
211
176
|
*/
|
|
212
|
-
max
|
|
177
|
+
max: number;
|
|
213
178
|
/**
|
|
214
179
|
* Ease type
|
|
215
180
|
* @default easeInSine
|
|
216
181
|
*/
|
|
217
|
-
ease: Math.easeEnum
|
|
182
|
+
ease: Math.easeEnum;
|
|
218
183
|
/**
|
|
219
184
|
* Indicates wether only intervals should be outputed. This will output step lengths between the values.
|
|
220
185
|
* @default false
|
|
221
186
|
*/
|
|
222
|
-
intervals
|
|
187
|
+
intervals: boolean;
|
|
223
188
|
}
|
|
224
|
-
|
|
225
|
-
constructor(nrItems?: number, min?: number, max?: number)
|
|
226
|
-
if (nrItems !== undefined) { this.nrItems = nrItems; }
|
|
227
|
-
if (min !== undefined) { this.min = min; }
|
|
228
|
-
if (max !== undefined) { this.max = max; }
|
|
229
|
-
}
|
|
189
|
+
class SpanLinearItemsDto {
|
|
190
|
+
constructor(nrItems?: number, min?: number, max?: number);
|
|
230
191
|
/**
|
|
231
192
|
* Nr of items in the span
|
|
232
193
|
* @default 100
|
|
@@ -234,7 +195,7 @@ export namespace Vector {
|
|
|
234
195
|
* @maximum Infinity
|
|
235
196
|
* @step 1
|
|
236
197
|
*/
|
|
237
|
-
nrItems
|
|
198
|
+
nrItems: number;
|
|
238
199
|
/**
|
|
239
200
|
* Min value of the span
|
|
240
201
|
* @default 0
|
|
@@ -242,7 +203,7 @@ export namespace Vector {
|
|
|
242
203
|
* @maximum Infinity
|
|
243
204
|
* @step 1
|
|
244
205
|
*/
|
|
245
|
-
min
|
|
206
|
+
min: number;
|
|
246
207
|
/**
|
|
247
208
|
* Max value of the span
|
|
248
209
|
* @default 1
|
|
@@ -250,14 +211,10 @@ export namespace Vector {
|
|
|
250
211
|
* @maximum Infinity
|
|
251
212
|
* @step 1
|
|
252
213
|
*/
|
|
253
|
-
max
|
|
214
|
+
max: number;
|
|
254
215
|
}
|
|
255
|
-
|
|
256
|
-
constructor(point?: Base.Point3, distance?: number, vector?: number[])
|
|
257
|
-
if (point !== undefined) { this.point = point; }
|
|
258
|
-
if (distance !== undefined) { this.distance = distance; }
|
|
259
|
-
if (vector !== undefined) { this.vector = vector; }
|
|
260
|
-
}
|
|
216
|
+
class RayPointDto {
|
|
217
|
+
constructor(point?: Base.Point3, distance?: number, vector?: number[]);
|
|
261
218
|
/**
|
|
262
219
|
* Origin location of the ray
|
|
263
220
|
* @default undefined
|
|
@@ -277,22 +234,16 @@ export namespace Vector {
|
|
|
277
234
|
*/
|
|
278
235
|
vector: number[];
|
|
279
236
|
}
|
|
280
|
-
|
|
281
|
-
constructor(vectors?: number[][])
|
|
282
|
-
if (vectors !== undefined) { this.vectors = vectors; }
|
|
283
|
-
}
|
|
237
|
+
class VectorsDto {
|
|
238
|
+
constructor(vectors?: number[][]);
|
|
284
239
|
/**
|
|
285
240
|
* Vectors array
|
|
286
241
|
* @default undefined
|
|
287
242
|
*/
|
|
288
243
|
vectors: number[][];
|
|
289
244
|
}
|
|
290
|
-
|
|
291
|
-
constructor(fraction?: number, first?: Base.Vector3, second?: Base.Vector3)
|
|
292
|
-
if (fraction !== undefined) { this.fraction = fraction; }
|
|
293
|
-
if (first !== undefined) { this.first = first; }
|
|
294
|
-
if (second !== undefined) { this.second = second; }
|
|
295
|
-
}
|
|
245
|
+
class FractionTwoVectorsDto {
|
|
246
|
+
constructor(fraction?: number, first?: Base.Vector3, second?: Base.Vector3);
|
|
296
247
|
/**
|
|
297
248
|
* Fraction number
|
|
298
249
|
* @default 0.5
|
|
@@ -300,7 +251,7 @@ export namespace Vector {
|
|
|
300
251
|
* @maximum Infinity
|
|
301
252
|
* @step 0.1
|
|
302
253
|
*/
|
|
303
|
-
fraction
|
|
254
|
+
fraction: number;
|
|
304
255
|
/**
|
|
305
256
|
* First vector
|
|
306
257
|
* @default undefined
|
|
@@ -312,11 +263,8 @@ export namespace Vector {
|
|
|
312
263
|
*/
|
|
313
264
|
second: Base.Vector3;
|
|
314
265
|
}
|
|
315
|
-
|
|
316
|
-
constructor(scalar?: number, vector?: number[])
|
|
317
|
-
if (scalar !== undefined) { this.scalar = scalar; }
|
|
318
|
-
if (vector !== undefined) { this.vector = vector; }
|
|
319
|
-
}
|
|
266
|
+
class VectorScalarDto {
|
|
267
|
+
constructor(scalar?: number, vector?: number[]);
|
|
320
268
|
/**
|
|
321
269
|
* Scalar number
|
|
322
270
|
* @default 1
|
|
@@ -331,12 +279,8 @@ export namespace Vector {
|
|
|
331
279
|
*/
|
|
332
280
|
vector: number[];
|
|
333
281
|
}
|
|
334
|
-
|
|
335
|
-
constructor(reference?: number[], first?: Base.Vector3, second?: Base.Vector3)
|
|
336
|
-
if (reference !== undefined) { this.reference = reference; }
|
|
337
|
-
if (first !== undefined) { this.first = first; }
|
|
338
|
-
if (second !== undefined) { this.second = second; }
|
|
339
|
-
}
|
|
282
|
+
class TwoVectorsReferenceDto {
|
|
283
|
+
constructor(reference?: number[], first?: Base.Vector3, second?: Base.Vector3);
|
|
340
284
|
/**
|
|
341
285
|
* Reference vector
|
|
342
286
|
* @default undefined
|
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
import { Math } from "./inputs";
|
|
2
|
+
export var Vector;
|
|
3
|
+
(function (Vector) {
|
|
4
|
+
class TwoVectorsDto {
|
|
5
|
+
constructor(first, second) {
|
|
6
|
+
if (first !== undefined) {
|
|
7
|
+
this.first = first;
|
|
8
|
+
}
|
|
9
|
+
if (second !== undefined) {
|
|
10
|
+
this.second = second;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
Vector.TwoVectorsDto = TwoVectorsDto;
|
|
15
|
+
class VectorBoolDto {
|
|
16
|
+
constructor(vector) {
|
|
17
|
+
if (vector !== undefined) {
|
|
18
|
+
this.vector = vector;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
Vector.VectorBoolDto = VectorBoolDto;
|
|
23
|
+
class RemoveAllDuplicateVectorsDto {
|
|
24
|
+
constructor(vectors, tolerance) {
|
|
25
|
+
/**
|
|
26
|
+
* Tolerance value
|
|
27
|
+
* @default 1e-7
|
|
28
|
+
* @minimum 0
|
|
29
|
+
* @maximum Infinity
|
|
30
|
+
*/
|
|
31
|
+
this.tolerance = 1e-7;
|
|
32
|
+
if (vectors !== undefined) {
|
|
33
|
+
this.vectors = vectors;
|
|
34
|
+
}
|
|
35
|
+
if (tolerance !== undefined) {
|
|
36
|
+
this.tolerance = tolerance;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
Vector.RemoveAllDuplicateVectorsDto = RemoveAllDuplicateVectorsDto;
|
|
41
|
+
class RemoveConsecutiveDuplicateVectorsDto {
|
|
42
|
+
constructor(vectors, checkFirstAndLast, tolerance) {
|
|
43
|
+
/**
|
|
44
|
+
* Check first and last vectors
|
|
45
|
+
* @default false
|
|
46
|
+
*/
|
|
47
|
+
this.checkFirstAndLast = false;
|
|
48
|
+
/**
|
|
49
|
+
* Tolerance value
|
|
50
|
+
* @default 1e-7
|
|
51
|
+
* @minimum 0
|
|
52
|
+
* @maximum Infinity
|
|
53
|
+
*/
|
|
54
|
+
this.tolerance = 1e-7;
|
|
55
|
+
if (vectors !== undefined) {
|
|
56
|
+
this.vectors = vectors;
|
|
57
|
+
}
|
|
58
|
+
if (checkFirstAndLast !== undefined) {
|
|
59
|
+
this.checkFirstAndLast = checkFirstAndLast;
|
|
60
|
+
}
|
|
61
|
+
if (tolerance !== undefined) {
|
|
62
|
+
this.tolerance = tolerance;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
Vector.RemoveConsecutiveDuplicateVectorsDto = RemoveConsecutiveDuplicateVectorsDto;
|
|
67
|
+
class VectorDto {
|
|
68
|
+
constructor(vector) {
|
|
69
|
+
if (vector !== undefined) {
|
|
70
|
+
this.vector = vector;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
Vector.VectorDto = VectorDto;
|
|
75
|
+
class RangeMaxDto {
|
|
76
|
+
constructor(max) {
|
|
77
|
+
if (max !== undefined) {
|
|
78
|
+
this.max = max;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
Vector.RangeMaxDto = RangeMaxDto;
|
|
83
|
+
class VectorXYZDto {
|
|
84
|
+
constructor(x, y, z) {
|
|
85
|
+
if (x !== undefined) {
|
|
86
|
+
this.x = x;
|
|
87
|
+
}
|
|
88
|
+
if (y !== undefined) {
|
|
89
|
+
this.y = y;
|
|
90
|
+
}
|
|
91
|
+
if (z !== undefined) {
|
|
92
|
+
this.z = z;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
Vector.VectorXYZDto = VectorXYZDto;
|
|
97
|
+
class VectorXYDto {
|
|
98
|
+
constructor(x, y) {
|
|
99
|
+
if (x !== undefined) {
|
|
100
|
+
this.x = x;
|
|
101
|
+
}
|
|
102
|
+
if (y !== undefined) {
|
|
103
|
+
this.y = y;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
Vector.VectorXYDto = VectorXYDto;
|
|
108
|
+
class SpanDto {
|
|
109
|
+
constructor(step, min, max) {
|
|
110
|
+
/**
|
|
111
|
+
* Step of the span
|
|
112
|
+
* @default 0.1
|
|
113
|
+
* @minimum -Infinity
|
|
114
|
+
* @maximum Infinity
|
|
115
|
+
* @step 0.1
|
|
116
|
+
*/
|
|
117
|
+
this.step = 0.1;
|
|
118
|
+
/**
|
|
119
|
+
* Min value of the span
|
|
120
|
+
* @default 0
|
|
121
|
+
* @minimum -Infinity
|
|
122
|
+
* @maximum Infinity
|
|
123
|
+
* @step 1
|
|
124
|
+
*/
|
|
125
|
+
this.min = 0;
|
|
126
|
+
/**
|
|
127
|
+
* Max value of the span
|
|
128
|
+
* @default 1
|
|
129
|
+
* @minimum -Infinity
|
|
130
|
+
* @maximum Infinity
|
|
131
|
+
* @step 1
|
|
132
|
+
*/
|
|
133
|
+
this.max = 1;
|
|
134
|
+
if (step !== undefined) {
|
|
135
|
+
this.step = step;
|
|
136
|
+
}
|
|
137
|
+
if (min !== undefined) {
|
|
138
|
+
this.min = min;
|
|
139
|
+
}
|
|
140
|
+
if (max !== undefined) {
|
|
141
|
+
this.max = max;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
Vector.SpanDto = SpanDto;
|
|
146
|
+
class SpanEaseItemsDto {
|
|
147
|
+
constructor(nrItems, min, max, ease) {
|
|
148
|
+
/**
|
|
149
|
+
* Nr of items in the span
|
|
150
|
+
* @default 100
|
|
151
|
+
* @minimum 2
|
|
152
|
+
* @maximum Infinity
|
|
153
|
+
* @step 1
|
|
154
|
+
*/
|
|
155
|
+
this.nrItems = 100;
|
|
156
|
+
/**
|
|
157
|
+
* Min value of the span
|
|
158
|
+
* @default 0
|
|
159
|
+
* @minimum -Infinity
|
|
160
|
+
* @maximum Infinity
|
|
161
|
+
* @step 1
|
|
162
|
+
*/
|
|
163
|
+
this.min = 0;
|
|
164
|
+
/**
|
|
165
|
+
* Max value of the span
|
|
166
|
+
* @default 1
|
|
167
|
+
* @minimum -Infinity
|
|
168
|
+
* @maximum Infinity
|
|
169
|
+
* @step 1
|
|
170
|
+
*/
|
|
171
|
+
this.max = 1;
|
|
172
|
+
/**
|
|
173
|
+
* Ease type
|
|
174
|
+
* @default easeInSine
|
|
175
|
+
*/
|
|
176
|
+
this.ease = Math.easeEnum.easeInSine;
|
|
177
|
+
/**
|
|
178
|
+
* Indicates wether only intervals should be outputed. This will output step lengths between the values.
|
|
179
|
+
* @default false
|
|
180
|
+
*/
|
|
181
|
+
this.intervals = false;
|
|
182
|
+
if (nrItems !== undefined) {
|
|
183
|
+
this.nrItems = nrItems;
|
|
184
|
+
}
|
|
185
|
+
if (min !== undefined) {
|
|
186
|
+
this.min = min;
|
|
187
|
+
}
|
|
188
|
+
if (max !== undefined) {
|
|
189
|
+
this.max = max;
|
|
190
|
+
}
|
|
191
|
+
if (ease !== undefined) {
|
|
192
|
+
this.ease = ease;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
Vector.SpanEaseItemsDto = SpanEaseItemsDto;
|
|
197
|
+
class SpanLinearItemsDto {
|
|
198
|
+
constructor(nrItems, min, max) {
|
|
199
|
+
/**
|
|
200
|
+
* Nr of items in the span
|
|
201
|
+
* @default 100
|
|
202
|
+
* @minimum 2
|
|
203
|
+
* @maximum Infinity
|
|
204
|
+
* @step 1
|
|
205
|
+
*/
|
|
206
|
+
this.nrItems = 100;
|
|
207
|
+
/**
|
|
208
|
+
* Min value of the span
|
|
209
|
+
* @default 0
|
|
210
|
+
* @minimum -Infinity
|
|
211
|
+
* @maximum Infinity
|
|
212
|
+
* @step 1
|
|
213
|
+
*/
|
|
214
|
+
this.min = 0;
|
|
215
|
+
/**
|
|
216
|
+
* Max value of the span
|
|
217
|
+
* @default 1
|
|
218
|
+
* @minimum -Infinity
|
|
219
|
+
* @maximum Infinity
|
|
220
|
+
* @step 1
|
|
221
|
+
*/
|
|
222
|
+
this.max = 1;
|
|
223
|
+
if (nrItems !== undefined) {
|
|
224
|
+
this.nrItems = nrItems;
|
|
225
|
+
}
|
|
226
|
+
if (min !== undefined) {
|
|
227
|
+
this.min = min;
|
|
228
|
+
}
|
|
229
|
+
if (max !== undefined) {
|
|
230
|
+
this.max = max;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
Vector.SpanLinearItemsDto = SpanLinearItemsDto;
|
|
235
|
+
class RayPointDto {
|
|
236
|
+
constructor(point, distance, vector) {
|
|
237
|
+
if (point !== undefined) {
|
|
238
|
+
this.point = point;
|
|
239
|
+
}
|
|
240
|
+
if (distance !== undefined) {
|
|
241
|
+
this.distance = distance;
|
|
242
|
+
}
|
|
243
|
+
if (vector !== undefined) {
|
|
244
|
+
this.vector = vector;
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
Vector.RayPointDto = RayPointDto;
|
|
249
|
+
class VectorsDto {
|
|
250
|
+
constructor(vectors) {
|
|
251
|
+
if (vectors !== undefined) {
|
|
252
|
+
this.vectors = vectors;
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
Vector.VectorsDto = VectorsDto;
|
|
257
|
+
class FractionTwoVectorsDto {
|
|
258
|
+
constructor(fraction, first, second) {
|
|
259
|
+
/**
|
|
260
|
+
* Fraction number
|
|
261
|
+
* @default 0.5
|
|
262
|
+
* @minimum -Infinity
|
|
263
|
+
* @maximum Infinity
|
|
264
|
+
* @step 0.1
|
|
265
|
+
*/
|
|
266
|
+
this.fraction = 0.5;
|
|
267
|
+
if (fraction !== undefined) {
|
|
268
|
+
this.fraction = fraction;
|
|
269
|
+
}
|
|
270
|
+
if (first !== undefined) {
|
|
271
|
+
this.first = first;
|
|
272
|
+
}
|
|
273
|
+
if (second !== undefined) {
|
|
274
|
+
this.second = second;
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
Vector.FractionTwoVectorsDto = FractionTwoVectorsDto;
|
|
279
|
+
class VectorScalarDto {
|
|
280
|
+
constructor(scalar, vector) {
|
|
281
|
+
if (scalar !== undefined) {
|
|
282
|
+
this.scalar = scalar;
|
|
283
|
+
}
|
|
284
|
+
if (vector !== undefined) {
|
|
285
|
+
this.vector = vector;
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
Vector.VectorScalarDto = VectorScalarDto;
|
|
290
|
+
class TwoVectorsReferenceDto {
|
|
291
|
+
constructor(reference, first, second) {
|
|
292
|
+
if (reference !== undefined) {
|
|
293
|
+
this.reference = reference;
|
|
294
|
+
}
|
|
295
|
+
if (first !== undefined) {
|
|
296
|
+
this.first = first;
|
|
297
|
+
}
|
|
298
|
+
if (second !== undefined) {
|
|
299
|
+
this.second = second;
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
Vector.TwoVectorsReferenceDto = TwoVectorsReferenceDto;
|
|
304
|
+
})(Vector || (Vector = {}));
|