@woosh/meep-engine 2.113.6 → 2.113.8

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.
Files changed (82) hide show
  1. package/build/bundle-worker-terrain.js +1 -1
  2. package/build/meep.cjs +168 -88
  3. package/build/meep.min.js +1 -1
  4. package/build/meep.module.js +168 -88
  5. package/package.json +1 -1
  6. package/src/core/binary/Base64.d.ts.map +1 -1
  7. package/src/core/binary/Base64.js +73 -31
  8. package/src/core/binary/BitSet.d.ts +2 -2
  9. package/src/core/binary/BitSet.d.ts.map +1 -1
  10. package/src/core/binary/BitSet.js +8 -8
  11. package/src/core/binary/align_32.d.ts +2 -2
  12. package/src/core/binary/align_32.d.ts.map +1 -1
  13. package/src/core/binary/align_32.js +7 -3
  14. package/src/core/binary/dec2hex.d.ts +2 -2
  15. package/src/core/binary/dec2hex.d.ts.map +1 -1
  16. package/src/core/binary/dec2hex.js +7 -3
  17. package/src/core/binary/downloadAsFile.d.ts +7 -1
  18. package/src/core/binary/downloadAsFile.d.ts.map +1 -1
  19. package/src/core/binary/downloadAsFile.js +10 -7
  20. package/src/core/binary/downloadUrlAsFile.d.ts +1 -1
  21. package/src/core/binary/downloadUrlAsFile.d.ts.map +1 -1
  22. package/src/core/binary/downloadUrlAsFile.js +6 -1
  23. package/src/core/binary/int32_to_binary_string.d.ts +1 -2
  24. package/src/core/binary/int32_to_binary_string.d.ts.map +1 -1
  25. package/src/core/binary/int32_to_binary_string.js +4 -2
  26. package/src/core/binary/url_to_data_url.d.ts +2 -1
  27. package/src/core/binary/url_to_data_url.d.ts.map +1 -1
  28. package/src/core/binary/url_to_data_url.js +2 -1
  29. package/src/core/codegen/LineBuilder.d.ts +4 -3
  30. package/src/core/codegen/LineBuilder.d.ts.map +1 -1
  31. package/src/core/codegen/LineBuilder.js +35 -6
  32. package/src/core/collection/array/arrayIndexByEquality.d.ts +1 -1
  33. package/src/core/collection/array/arrayIndexByEquality.js +1 -1
  34. package/src/core/collection/array/array_push_if_unique.d.ts.map +1 -1
  35. package/src/core/collection/array/array_push_if_unique.js +4 -0
  36. package/src/core/collection/list/List.d.ts.map +1 -1
  37. package/src/core/collection/list/List.js +7 -2
  38. package/src/core/collection/table/RowFirstTable.d.ts +12 -12
  39. package/src/core/collection/table/RowFirstTable.d.ts.map +1 -1
  40. package/src/core/collection/table/RowFirstTable.js +39 -36
  41. package/src/core/collection/table/RowFirstTableSpec.d.ts +1 -0
  42. package/src/core/collection/table/RowFirstTableSpec.d.ts.map +1 -1
  43. package/src/core/collection/table/RowFirstTableSpec.js +1 -0
  44. package/src/core/collection/table/serializeRowFirstTable.d.ts.map +1 -1
  45. package/src/core/collection/table/serializeRowFirstTable.js +6 -4
  46. package/src/core/geom/3d/frustum/frustum3_computeNearestPointToPoint.d.ts.map +1 -1
  47. package/src/core/geom/3d/frustum/frustum3_computeNearestPointToPoint.js +5 -5
  48. package/src/core/geom/3d/frustum/frustum_from_projection_matrix_array.d.ts +3 -2
  49. package/src/core/geom/3d/frustum/frustum_from_projection_matrix_array.d.ts.map +1 -1
  50. package/src/core/geom/3d/frustum/frustum_from_projection_matrix_array.js +9 -33
  51. package/src/core/geom/3d/plane/plane3_normalize.d.ts +11 -0
  52. package/src/core/geom/3d/plane/plane3_normalize.d.ts.map +1 -0
  53. package/src/core/geom/3d/plane/plane3_normalize.js +26 -0
  54. package/src/core/geom/3d/plane/plane3_project_point.d.ts +13 -0
  55. package/src/core/geom/3d/plane/plane3_project_point.d.ts.map +1 -0
  56. package/src/core/geom/3d/plane/{plane3_projectPoint.js → plane3_project_point.js} +6 -2
  57. package/src/core/math/isPowerOfTwo.d.ts +1 -1
  58. package/src/core/math/isPowerOfTwo.d.ts.map +1 -1
  59. package/src/core/math/isPowerOfTwo.js +2 -4
  60. package/src/core/model/LinearValue.d.ts +5 -1
  61. package/src/core/model/LinearValue.d.ts.map +1 -1
  62. package/src/core/model/LinearValue.js +16 -5
  63. package/src/core/model/ModuleRegistry.d.ts.map +1 -1
  64. package/src/core/model/ModuleRegistry.js +33 -29
  65. package/src/core/model/ResourceAccessSpecification.d.ts.map +1 -1
  66. package/src/core/model/ResourceAccessSpecification.js +7 -1
  67. package/src/core/model/node-graph/Connection.d.ts.map +1 -1
  68. package/src/core/model/node-graph/Connection.js +13 -7
  69. package/src/core/model/node-graph/NodeGraph.d.ts +2 -1
  70. package/src/core/model/node-graph/NodeGraph.d.ts.map +1 -1
  71. package/src/core/model/node-graph/NodeGraph.js +1 -1
  72. package/src/core/model/node-graph/node/NodeDescription.d.ts.map +1 -1
  73. package/src/core/model/node-graph/node/NodeDescription.js +8 -0
  74. package/src/core/model/node-graph/node/NodeInstance.d.ts.map +1 -1
  75. package/src/core/model/node-graph/node/NodeInstance.js +4 -0
  76. package/src/core/model/node-graph/node/NodeInstancePortReference.d.ts.map +1 -1
  77. package/src/core/model/node-graph/node/NodeInstancePortReference.js +6 -10
  78. package/src/core/bvh2/traversal/__process_point_if_within_planes.d.ts +0 -15
  79. package/src/core/bvh2/traversal/__process_point_if_within_planes.d.ts.map +0 -1
  80. package/src/core/bvh2/traversal/__process_point_if_within_planes.js +0 -56
  81. package/src/core/geom/3d/plane/plane3_projectPoint.d.ts +0 -13
  82. package/src/core/geom/3d/plane/plane3_projectPoint.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"List.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/list/List.js"],"names":[],"mappings":"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"}
1
+ {"version":3,"file":"List.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/list/List.js"],"names":[],"mappings":";AAaA;;;;GAIG;AACH;IAuBI;;;OAGG;IACH,oBAHW,EAAE,EAqBZ;IA5CD;;OAEG;IACH;QACI;;;WAGG;wBADO,OAAO,CAAC,EAAC,MAAM,CAAC;QAG1B;;;WAGG;0BADO,OAAO,CAAC,EAAC,MAAM,CAAC;MAG5B;IAEF;;;OAGG;IACH,eAFU,CAAC,EAAE,CAEJ;IAmBL;;;OAGG;IACH,QAFU,MAAM,CAEc;IAGlC;;;;OAIG;IACH,WAHW,MAAM,GACJ,CAAC,GAAC,SAAS,CAOvB;IAED;;;;OAIG;IACH,WAHW,MAAM,SACN,CAAC,QAyBX;IAED;;;;OAIG;IACH,QAHW,CAAC,GACC,IAAI,CAUhB;IAED;;;;;;;OAOG;IACH,cAHW,CAAC,GACA,OAAO,CAUlB;IAED;;;;;;;OAOG;IACH,cALW,MAAM,MACN,CAAC,aAoBX;IAED;;;;;OAKG;IACH,sCAFa,MAAM,CAkClB;IAED;;;;;OAKG;IACH,gBAFW,CAAC,EAAE,QAqDb;IAED;;;OAGG;IACH,iBAFW,MAAO,CAAC,CAAC,QAmBnB;IAED;;;OAGG;IACH,uBAFW,MAAO,CAAC,CAAC,QAUnB;IAED;;;;;OAKG;IACH,kBAJW,MAAM,eACN,MAAM,GACJ,CAAC,EAAE,CAyBf;IAED;;;;OAIG;IACH,cAHW,MAAM,GACJ,CAAC,CAiBb;IAED;;;;OAIG;IACH,oBAHW,CAAC,EAAE,GACD,OAAO,CAwCnB;IAED;;;;OAIG;IACH,mBAHW,CAAC,GACA,OAAO,CAQlB;IAED;;;;OAIG;IACH,uCAGC;IAED;;;OAGG;IACH,SAFa,KAAM,CAAC,CAAC,CAIpB;IAED;;;;;;OAMG;IACH,cAJW,MAAM,QACN,MAAM,GACL,CAAC,EAAE,CAId;IAED;;;;OAIG;IACH,sBAFa,OAAO,CAWnB;IAED;;;;OAIG;IACH,2BAHoB,CAAC,KAAE,OAAO,uBAiB7B;IAED;;;;;OAKG;IACH,8BAJoB,CAAC,KAAE,OAAO,kBAElB,OAAO,CAgBlB;IAED;;;;OAIG;IACH,qCASC;IAED;;;;OAIG;IACH,4BAJsB,CAAC,6BAUtB;IAED;;;;OAIG;IACH,iBAHoB,CAAC,KAAE,OAAO,GACjB,MAAO,CAAC,CAAC,CAIrB;IAED;;;;OAIG;IACH,oBAFa,CAAC,GAAC,SAAS,CAcvB;IAED;;;;OAIG;IACH,0BAHoB,CAAC,KAAE,OAAO,GACjB,MAAM,CAiBlB;IAED;;;;;OAKG;IACH,8CAFa,OAAO,CAkBnB;IAED;;;;OAIG;IACH,YAHW,CAAC,GACC,OAAO,CAInB;IAED;;;;OAIG;IACH,qBAHW,CAAC,EAAE,GACD,OAAO,CAanB;IAED;;;OAGG;IACH,WAFa,OAAO,CAInB;IAED;;;;OAIG;IACH,YAHW,CAAC,GACC,MAAM,CAIlB;IAED;;;;;OAKG;IACH,wBAJoB,CAAC,4BAkBpB;IAED;;;;OAIG;IACH,qDAoBC;IAED,cAyBC;IAED;;;;;OAKG;IACH,gBAJW,KAAK,CAAC,CAAC,kDAuCjB;IAED;;;OAGG;IACH,YAFW,KAAK,CAAC,CAAC,GAAC,CAAC,EAAE,QAarB;IAED;;;OAGG;IACH,WAFa,CAAC,EAAE,CAIf;IAED,cAEC;IAED;;;;OAIG;IACH,oDAcC;IAED;;;OAGG;IACH,2CAcC;IAED;;;;OAIG;IACH,+DAaC;IAED;;;;OAIG;IACH,qEAIC;IAED;;;;OAIG;IACH,wEAQC;IAED;;;;OAIG;IACH,gEAFuB,CAAC,QAWvB;IAED;;;OAGG;IACH,QAFa,MAAM,CAgBlB;IAED;;;OAGG;IACH,SAFa,CAAC,GAAC,SAAS,CAIvB;IAED;;;OAGG;IACH,QAFY,CAAC,GAAC,SAAS,CAItB;IAED;;;OAGG;IACH,kCA8BC;IAED;;;;OAIG;IACH,eAHW,KAAK,CAAC,CAAC,GACL,MAAM,CA0BlB;CACJ;mBAn+BkB,+BAA+B"}
@@ -22,17 +22,19 @@ class List {
22
22
  */
23
23
  on = {
24
24
  /**
25
+ * @readonly
25
26
  * @type {Signal<T,number>}
26
27
  */
27
28
  added: new Signal(),
28
29
  /**
30
+ * @readonly
29
31
  * @type {Signal<T,number>}
30
32
  */
31
33
  removed: new Signal()
32
34
  };
33
35
 
34
36
  /**
35
- *
37
+ * @readonly
36
38
  * @type {T[]}
37
39
  */
38
40
  data = []
@@ -106,6 +108,7 @@ class List {
106
108
  /**
107
109
  *
108
110
  * @param {T} el
111
+ * @returns {this}
109
112
  */
110
113
  add(el) {
111
114
  this.data.push(el);
@@ -123,7 +126,7 @@ class List {
123
126
  * Note that this operation is rather slow as it triggers a linear scan
124
127
  * If the list gets large - consider using a {@link Set} class instead
125
128
  * @param {T} el
126
- * @return {boolean}
129
+ * @return {boolean} true if element was added, false if element already existed in the list
127
130
  */
128
131
  addUnique(el) {
129
132
  if (this.contains(el)) {
@@ -904,7 +907,9 @@ class List {
904
907
 
905
908
  for (let i = 0; i < length; i++) {
906
909
  const datum = this.data[i];
910
+
907
911
  const singleValue = datum.hash();
912
+
908
913
  hash = ((hash << 5) - hash) + singleValue;
909
914
  hash |= 0; // Convert to 32bit integer
910
915
  }
@@ -14,21 +14,11 @@ export class RowFirstTable {
14
14
  * @type {RowFirstTableSpec}
15
15
  */
16
16
  spec: RowFirstTableSpec;
17
- /**
18
- * @readonly
19
- * @type {Array.<BinaryDataType>}
20
- */
21
- readonly types: Array<BinaryDataType>;
22
17
  /**
23
18
  *
24
19
  * @type {ArrayBuffer}
25
20
  */
26
21
  data: ArrayBuffer;
27
- /**
28
- *
29
- * @type {number}
30
- */
31
- bytesPerRecord: number;
32
22
  /**
33
23
  * number of records
34
24
  * @type {number}
@@ -47,6 +37,16 @@ export class RowFirstTable {
47
37
  on: {
48
38
  added: Signal<any, any, any, any, any, any, any, any>;
49
39
  };
40
+ /**
41
+ * @deprecated access directly via spec instead
42
+ * @return {BinaryDataType[]}
43
+ */
44
+ get types(): BinaryDataType[];
45
+ /**
46
+ * @deprecated access {@link RowFirstTableSpec#bytesPerRecord} directly instead
47
+ * @return {number}
48
+ */
49
+ get bytesPerRecord(): number;
50
50
  /**
51
51
  * @private
52
52
  */
@@ -163,8 +163,8 @@ export class RowFirstTable {
163
163
  */
164
164
  clear(): void;
165
165
  /**
166
- *
167
- * @returns {Number}
166
+ * @deprecated access {@link RowFirstTableSpec#getColumnCount} from spec instead
167
+ * @returns {number}
168
168
  */
169
169
  getNumColumns(): number;
170
170
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"RowFirstTable.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/RowFirstTable.js"],"names":[],"mappings":"AAMA;;GAEG;AACH;IACI;;;;;OAKG;IACH,oDAHW,OAAO,EAuDjB;IA/CG;;;OAGG;IACH,wBAAgB;IAEhB;;;OAGG;IACH,gBAFU,qBAAsB,CAET;IAEvB;;;OAGG;IACH,MAFU,WAAW,CAEuB;IAE5C;;;OAGG;IACH,gBAFU,MAAM,CAEyB;IAEzC;;;OAGG;IACH,QAFU,MAAM,CAED;IAEf;;;OAGG;IACH,UAFU,MAAM,CAEC;IAEjB;;;OAGG;IACH,UAFU,QAAQ,CAEE;IAEpB;;MAEC;IAKL;;OAEG;IACH,mBAiBC;IAXG;;;OAGG;IACH,sBAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEb;IAEvC;;;OAGG;IACH,uBAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEX;IAG7C;;;;OAIG;IACH,uDAMC;IAED;;;OAGG;IACH,QAFa,MAAM,CA4BlB;IAED;;;OAGG;IACH,sBAFW,MAAM,QA+ChB;IAED;;OAEG;IACH,aAEC;IAED;;;OAGG;IACH,iBAFW,MAAM,QAchB;IAED;;;;;OAKG;IACH,yBAJW,MAAM,eACN,MAAM,SACN,MAAM,QAchB;IAED;;;;;OAKG;IACH,wBAJW,MAAM,eACN,MAAM,GACJ,MAAM,CAclB;IAED;;;;OAIG;IACH,kBAHW,MAAM,YACN,MAAM,QAyBhB;IAED;;;;;OAKG;IACH,kBAHW,MAAM,YACN,MAAM,QAqBhB;IAED;;;;OAIG;IACH,eAHW,MAAO,MAAM,CAAC,GACZ,MAAM,CAiBlB;IAED;;;;OAIG;IACH,eAHW,MAAM,4BAoChB;IAED;;;;OAIG;IACH,gBAHW,MAAM,UACN,MAAM,QAwBhB;IAED;;;;OAIG;IACH,YAFW,aAAa,QAsBvB;IAED;;;OAGG;IACH,cAHW,aAAa,GACX,OAAO,CAyBnB;IAED;;;;OAIG;IACH,wCAIC;IAED;;;;OAIG;IACH,cAHW,MAAM,UACN,MAAM,EAAE,QAMlB;IAED;;OAEG;IACH,qBA4BC;IAED;;OAEG;IACH,cAIC;IAED;;;OAGG;IACH,wBAEC;IAED;;;OAGG;IACH,cAFa,MAAM,EAAE,EAAE,CAgBtB;IAED;;OAEG;IACH,uBAIC;CACJ;mBA3iBkB,+BAA+B"}
1
+ {"version":3,"file":"RowFirstTable.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/RowFirstTable.js"],"names":[],"mappings":"AAMA;;GAEG;AACH;IACI;;;;;OAKG;IACH,oDAHW,OAAO,EA2CjB;IAnCG;;;OAGG;IACH,wBAAgB;IAEhB;;;OAGG;IACH,MAFU,WAAW,CAEuB;IAE5C;;;OAGG;IACH,QAFU,MAAM,CAED;IAEf;;;OAGG;IACH,UAFU,MAAM,CAEC;IAEjB;;;OAGG;IACH,UAFU,QAAQ,CAEE;IAEpB;;MAEC;IAKL;;;OAGG;IACH,8BAEC;IAED;;;OAGG;IACH,6BAEC;IAED;;OAEG;IACH,mBAcC;IAXG;;;OAGG;IACH,sBAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEb;IAEvC;;;OAGG;IACH,uBAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEX;IAG7C;;;;OAIG;IACH,uDAMC;IAED;;;OAGG;IACH,QAFa,MAAM,CA4BlB;IAED;;;OAGG;IACH,sBAFW,MAAM,QA+ChB;IAED;;OAEG;IACH,aAEC;IAED;;;OAGG;IACH,iBAFW,MAAM,QAchB;IAED;;;;;OAKG;IACH,yBAJW,MAAM,eACN,MAAM,SACN,MAAM,QAchB;IAED;;;;;OAKG;IACH,wBAJW,MAAM,eACN,MAAM,GACJ,MAAM,CAclB;IAED;;;;OAIG;IACH,kBAHW,MAAM,YACN,MAAM,QAyBhB;IAED;;;;;OAKG;IACH,kBAHW,MAAM,YACN,MAAM,QAqBhB;IAED;;;;OAIG;IACH,eAHW,MAAO,MAAM,CAAC,GACZ,MAAM,CAiBlB;IAED;;;;OAIG;IACH,eAHW,MAAM,4BAsChB;IAED;;;;OAIG;IACH,gBAHW,MAAM,UACN,MAAM,QAwBhB;IAED;;;;OAIG;IACH,YAFW,aAAa,QAsBvB;IAED;;;OAGG;IACH,cAHW,aAAa,GACX,OAAO,CAyBnB;IAED;;;;OAIG;IACH,wCAIC;IAED;;;;OAIG;IACH,cAHW,MAAM,UACN,MAAM,EAAE,QAMlB;IAED;;OAEG;IACH,qBA4BC;IAED;;OAEG;IACH,cAIC;IAED;;;OAGG;IACH,iBAFa,MAAM,CAIlB;IAED;;;OAGG;IACH,cAFa,MAAM,EAAE,EAAE,CAgBtB;IAED;;OAEG;IACH,uBAIC;CACJ;mBA9iBkB,+BAA+B"}
@@ -25,24 +25,12 @@ export class RowFirstTable {
25
25
  */
26
26
  this.spec = spec;
27
27
 
28
- /**
29
- * @readonly
30
- * @type {Array.<BinaryDataType>}
31
- */
32
- this.types = spec.types;
33
-
34
28
  /**
35
29
  *
36
30
  * @type {ArrayBuffer}
37
31
  */
38
32
  this.data = makeArrayBuffer(0, shared_array);
39
33
 
40
- /**
41
- *
42
- * @type {number}
43
- */
44
- this.bytesPerRecord = spec.bytesPerRecord;
45
-
46
34
  /**
47
35
  * number of records
48
36
  * @type {number}
@@ -68,15 +56,28 @@ export class RowFirstTable {
68
56
  this.initialize();
69
57
  }
70
58
 
59
+ /**
60
+ * @deprecated access directly via spec instead
61
+ * @return {BinaryDataType[]}
62
+ */
63
+ get types() {
64
+ return this.spec.types;
65
+ }
66
+
67
+ /**
68
+ * @deprecated access {@link RowFirstTableSpec#bytesPerRecord} directly instead
69
+ * @return {number}
70
+ */
71
+ get bytesPerRecord() {
72
+ return this.spec.bytesPerRecord;
73
+ }
74
+
71
75
  /**
72
76
  * @private
73
77
  */
74
78
  initialize() {
75
79
  const spec = this.spec;
76
80
 
77
- this.types = spec.types;
78
- this.bytesPerRecord = spec.bytesPerRecord;
79
-
80
81
  /**
81
82
  *
82
83
  * @type {function(DataView, number, number[]): void}
@@ -150,7 +151,7 @@ export class RowFirstTable {
150
151
 
151
152
  const oldData = this.data;
152
153
 
153
- const bytesPerRecord = this.bytesPerRecord;
154
+ const bytesPerRecord = this.spec.bytesPerRecord;
154
155
  const byteSize = rowCount * bytesPerRecord;
155
156
 
156
157
  try {
@@ -218,11 +219,11 @@ export class RowFirstTable {
218
219
  * @param {number} value
219
220
  */
220
221
  writeCellValue(rowIndex, columnIndex, value) {
221
- const bytesPerRecord = this.bytesPerRecord;
222
+ const spec = this.spec;
222
223
 
223
- const rowAddress = rowIndex * bytesPerRecord;
224
+ const bytesPerRecord = spec.bytesPerRecord;
224
225
 
225
- const spec = this.spec;
226
+ const rowAddress = rowIndex * bytesPerRecord;
226
227
 
227
228
  const cellWriters = spec.cellWriters;
228
229
 
@@ -238,11 +239,11 @@ export class RowFirstTable {
238
239
  * @returns {number}
239
240
  */
240
241
  readCellValue(rowIndex, columnIndex) {
241
- const bytesPerRecord = this.bytesPerRecord;
242
+ const spec = this.spec;
242
243
 
243
- const rowAddress = rowIndex * bytesPerRecord;
244
+ const bytesPerRecord = spec.bytesPerRecord;
244
245
 
245
- const spec = this.spec;
246
+ const rowAddress = rowIndex * bytesPerRecord;
246
247
 
247
248
  const cellReaders = spec.cellReaders;
248
249
 
@@ -265,7 +266,7 @@ export class RowFirstTable {
265
266
 
266
267
  const array = new Uint8Array(data);
267
268
 
268
- const bytesPerRecord = this.bytesPerRecord;
269
+ const bytesPerRecord = this.spec.bytesPerRecord;
269
270
 
270
271
  //shift tail of the table forward
271
272
  const target = index * bytesPerRecord;
@@ -294,7 +295,7 @@ export class RowFirstTable {
294
295
 
295
296
  const data = this.data;
296
297
 
297
- const bytesPerRecord = this.bytesPerRecord;
298
+ const bytesPerRecord = this.spec.bytesPerRecord;
298
299
 
299
300
  const array = new Uint8Array(data);
300
301
 
@@ -323,7 +324,7 @@ export class RowFirstTable {
323
324
 
324
325
  this.length = newRowCount;
325
326
 
326
- this.writeRowMethod(this.dataView, this.bytesPerRecord * rowIndex, values);
327
+ this.writeRowMethod(this.dataView, this.spec.bytesPerRecord * rowIndex, values);
327
328
 
328
329
  this.on.added.send2(rowIndex, values);
329
330
 
@@ -343,9 +344,11 @@ export class RowFirstTable {
343
344
  let i = this.length;
344
345
  this.length = newRowCount;
345
346
 
346
- const row = new Array(this.getNumColumns());
347
+ const spec = this.spec;
347
348
 
348
- const bytesPerRecord = this.bytesPerRecord;
349
+ const row = new Array(spec.getColumnCount());
350
+
351
+ const bytesPerRecord = spec.bytesPerRecord;
349
352
  const dataView = this.dataView;
350
353
  const writeRowMethod = this.writeRowMethod;
351
354
 
@@ -385,7 +388,7 @@ export class RowFirstTable {
385
388
  }
386
389
 
387
390
  // figure out addresses
388
- const bytes_per_record = this.bytesPerRecord;
391
+ const bytes_per_record = this.spec.bytesPerRecord;
389
392
 
390
393
  const source_address = source * bytes_per_record;
391
394
  const target_address = target * bytes_per_record;
@@ -420,7 +423,7 @@ export class RowFirstTable {
420
423
  const source = new Uint8Array(other.data);
421
424
 
422
425
  // copy data
423
- const data_byte_count = other.bytesPerRecord * record_count;
426
+ const data_byte_count = other.spec.bytesPerRecord * record_count;
424
427
  target.set(source.slice(0, data_byte_count));
425
428
 
426
429
  // TODO consider if we should invoke onAdded signal
@@ -441,7 +444,7 @@ export class RowFirstTable {
441
444
  return false;
442
445
  }
443
446
 
444
- const total_bytes = this_length * this.bytesPerRecord;
447
+ const total_bytes = this_length * this.spec.bytesPerRecord;
445
448
 
446
449
  for (let i = 0; i < total_bytes; i++) {
447
450
  const a = this.dataView.getUint8(i);
@@ -463,7 +466,7 @@ export class RowFirstTable {
463
466
  getRow(index, result) {
464
467
  assert.isNonNegativeInteger(index, 'index');
465
468
 
466
- this.readRowMethod(this.dataView, this.bytesPerRecord * index, result);
469
+ this.readRowMethod(this.dataView, this.spec.bytesPerRecord * index, result);
467
470
  }
468
471
 
469
472
  /**
@@ -474,14 +477,14 @@ export class RowFirstTable {
474
477
  setRow(index, record) {
475
478
  assert.isNonNegativeInteger(index, 'index');
476
479
 
477
- this.writeRowMethod(this.dataView, this.bytesPerRecord * index, record);
480
+ this.writeRowMethod(this.dataView, this.spec.bytesPerRecord * index, record);
478
481
  }
479
482
 
480
483
  /**
481
484
  * Reverse order of rows, row-0 will end up at and previously last row will become the first row etc.
482
485
  */
483
486
  reverse_rows() {
484
- const bpr = this.bytesPerRecord;
487
+ const bpr = this.spec.bytesPerRecord;
485
488
  const copy_buffer = new Uint8Array(bpr);
486
489
 
487
490
  const buffer = this.data;
@@ -520,11 +523,11 @@ export class RowFirstTable {
520
523
  }
521
524
 
522
525
  /**
523
- *
524
- * @returns {Number}
526
+ * @deprecated access {@link RowFirstTableSpec#getColumnCount} from spec instead
527
+ * @returns {number}
525
528
  */
526
529
  getNumColumns() {
527
- return this.types.length;
530
+ return this.spec.getColumnCount();
528
531
  }
529
532
 
530
533
  /**
@@ -33,6 +33,7 @@ export class RowFirstTableSpec {
33
33
  */
34
34
  readonly columnOffsets: Uint32Array;
35
35
  /**
36
+ * Number of bytes taken up by a single row of values
36
37
  * @readonly
37
38
  * @type {number}
38
39
  */
@@ -1 +1 @@
1
- {"version":3,"file":"RowFirstTableSpec.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/RowFirstTableSpec.js"],"names":[],"mappings":"AA+HA;;;GAGG;AACH;IA4GI;;;;;OAKG;IACH,kBAJW,cAAc,EAAE,eAChB,UAAU,GACR,iBAAiB,CAmB7B;IAlID;;;;;OAKG;IACH,mBAJW,cAAc,EAAE,eAChB,UAAU,EAqEpB;IA5DG;;;OAGG;IACH,gBAFU,cAAc,EAAE,CAER;IAElB;;;OAGG;IACH,qBAFU,UAAU,CAEQ;IAE5B;;;OAGG;IACH,wBAFU,WAAW,CAEyB;IAiB9C;;;OAGG;IACH,yBAFU,MAAM,CAEgB;IAEhC;;;OAGG;IACH,+BAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEA;IAEpD;;;OAGG;IACH,gCAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEC;IAIrD,mBAAsC;IACtC,mBAAsC;IAQ1C;;;OAGG;IACH,kBAFY,MAAM,CAIjB;IAED;;;OAGG;IACH,QAFY,MAAM,CAQjB;IAED;;;;OAIG;IACH,cAHW,iBAAiB,GACf,OAAO,CAQnB;IA4BL;;;OAGG;IACH,8BAFU,OAAO,CAE8B;CAN9C;+BA/P8B,qCAAqC;2BADzC,4BAA4B"}
1
+ {"version":3,"file":"RowFirstTableSpec.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/RowFirstTableSpec.js"],"names":[],"mappings":"AA+HA;;;GAGG;AACH;IA6GI;;;;;OAKG;IACH,kBAJW,cAAc,EAAE,eAChB,UAAU,GACR,iBAAiB,CAmB7B;IAnID;;;;;OAKG;IACH,mBAJW,cAAc,EAAE,eAChB,UAAU,EAsEpB;IA7DG;;;OAGG;IACH,gBAFU,cAAc,EAAE,CAER;IAElB;;;OAGG;IACH,qBAFU,UAAU,CAEQ;IAE5B;;;OAGG;IACH,wBAFU,WAAW,CAEyB;IAiB9C;;;;OAIG;IACH,yBAFU,MAAM,CAEgB;IAEhC;;;OAGG;IACH,+BAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEA;IAEpD;;;OAGG;IACH,gCAFmB,QAAQ,QAAE,MAAM,QAAE,MAAM,EAAE,KAAG,IAAI,CAEC;IAIrD,mBAAsC;IACtC,mBAAsC;IAQ1C;;;OAGG;IACH,kBAFY,MAAM,CAIjB;IAED;;;OAGG;IACH,QAFY,MAAM,CAQjB;IAED;;;;OAIG;IACH,cAHW,iBAAiB,GACf,OAAO,CAQnB;IA4BL;;;OAGG;IACH,8BAFU,OAAO,CAE8B;CAN9C;+BAhQ8B,qCAAqC;2BADzC,4BAA4B"}
@@ -176,6 +176,7 @@ export class RowFirstTableSpec {
176
176
 
177
177
 
178
178
  /**
179
+ * Number of bytes taken up by a single row of values
179
180
  * @readonly
180
181
  * @type {number}
181
182
  */
@@ -1 +1 @@
1
- {"version":3,"file":"serializeRowFirstTable.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/serializeRowFirstTable.js"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,yFAiBC"}
1
+ {"version":3,"file":"serializeRowFirstTable.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/table/serializeRowFirstTable.js"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,yFAmBC"}
@@ -6,21 +6,23 @@ import { DataTypeIndices } from "../../binary/type/DataTypeIndices.js";
6
6
  * @param {RowFirstTable} table
7
7
  */
8
8
  function serializeRowFirstTable(buffer, table) {
9
+ const spec = table.spec;
10
+
9
11
  //write types
10
- buffer.writeUint16(table.types.length);
11
- table.types.forEach(function (type) {
12
+ buffer.writeUint16(spec.types.length);
13
+ spec.types.forEach(function (type) {
12
14
  const typeIndex = DataTypeIndices[type];
13
15
  buffer.writeUint8(typeIndex);
14
16
  });
15
17
 
16
18
  //write record length
17
- buffer.writeUint32(table.bytesPerRecord);
19
+ buffer.writeUint32(spec.bytesPerRecord);
18
20
 
19
21
  //write number of records
20
22
  buffer.writeUint32(table.length);
21
23
 
22
24
  //write data
23
- const numDataBytes = table.length * table.bytesPerRecord;
25
+ const numDataBytes = table.length * spec.bytesPerRecord;
24
26
  buffer.writeBytes(new Uint8Array(table.data), 0, numDataBytes);
25
27
  }
26
28
 
@@ -1 +1 @@
1
- {"version":3,"file":"frustum3_computeNearestPointToPoint.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/frustum/frustum3_computeNearestPointToPoint.js"],"names":[],"mappings":"AAyBA;;;;;;;;GAQG;AACH,4DAPW,OAAO,UACP,OAAO,YACP,MAAM,YACN,MAAM,YACN,MAAM,GACJ,OAAO,CA+EnB;oBA/GmB,kBAAkB"}
1
+ {"version":3,"file":"frustum3_computeNearestPointToPoint.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/frustum/frustum3_computeNearestPointToPoint.js"],"names":[],"mappings":"AAyBA;;;;;;;;GAQG;AACH,4DAPW,OAAO,UACP,OAAO,YACP,MAAM,YACN,MAAM,YACN,MAAM,GACJ,OAAO,CA+EnB;oBA9GmB,kBAAkB"}
@@ -1,11 +1,11 @@
1
- import Vector3 from "../../Vector3.js";
2
- import { plane3_projectPoint } from "../plane/plane3_projectPoint.js";
3
- import { ray_computeNearestPointToPoint } from "../ray/ray_computeNearestPointToPoint.js";
4
1
  import { v3_distance_above_plane } from "../../vec3/v3_distance_above_plane.js";
2
+ import Vector3 from "../../Vector3.js";
3
+ import { plane3_compute_plane_intersection } from "../plane/plane3_compute_plane_intersection.js";
4
+ import { plane3_project_point } from "../plane/plane3_project_point.js";
5
5
  import {
6
6
  plane3_three_compute_convex_3_plane_intersection
7
7
  } from "../plane/plane3_three_compute_convex_3_plane_intersection.js";
8
- import { plane3_compute_plane_intersection } from "../plane/plane3_compute_plane_intersection.js";
8
+ import { ray_computeNearestPointToPoint } from "../ray/ray_computeNearestPointToPoint.js";
9
9
 
10
10
  /**
11
11
  *
@@ -72,7 +72,7 @@ export function frustum3_computeNearestPointToPoint(result, planes, target_x, ta
72
72
  const plane_0_index = scratch_outer_planes[0];
73
73
  const plane_0 = planes[plane_0_index];
74
74
  // point lies outside exactly one plane
75
- plane3_projectPoint(result, target_x, target_y, target_z, plane_0.normal.z, plane_0.normal.y, plane_0.normal.z, plane_0.constant);
75
+ plane3_project_point(result, target_x, target_y, target_z, plane_0.normal.z, plane_0.normal.y, plane_0.normal.z, plane_0.constant);
76
76
  } else if (outside_plane_count === 2) {
77
77
  // outside two planes, nearest point lies on the intersection line of two planes
78
78
 
@@ -1,9 +1,10 @@
1
1
  /**
2
+ *
2
3
  * Set frustum from projection matrix
3
4
  * NOTE: uses Gribb/Hartmann method
4
5
  * @see "Fast Extraction of Viewing Frustum Planes from the WorldView-Projection Matrix", 2001 by Gribb & Hartmann
5
- * @param {number[]|Float32Array} frustum_planes
6
- * @param {number[]} m4
6
+ * @param {number[]|Float32Array} frustum_planes tuples of 4, where each tuple is a plane normal (x,y,z) followed by a planar offset constant [normal_x, normal_y, normal_z, constant]
7
+ * @param {number[]} m4 assumed to be view-projection matrix
7
8
  */
8
9
  export function frustum_from_projection_matrix_array(frustum_planes: number[] | Float32Array, m4: number[]): void;
9
10
  //# sourceMappingURL=frustum_from_projection_matrix_array.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"frustum_from_projection_matrix_array.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/frustum/frustum_from_projection_matrix_array.js"],"names":[],"mappings":"AA2BA;;;;;;GAMG;AACH,qEAHW,MAAM,EAAE,GAAC,YAAY,MACrB,MAAM,EAAE,QAkClB"}
1
+ {"version":3,"file":"frustum_from_projection_matrix_array.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/frustum/frustum_from_projection_matrix_array.js"],"names":[],"mappings":"AAEA;;;;;;;GAOG;AACH,qEAHW,MAAM,EAAE,GAAC,YAAY,MACrB,MAAM,EAAE,QAkClB"}
@@ -1,36 +1,12 @@
1
- import { v3_length } from "../../vec3/v3_length.js";
1
+ import { plane3_normalize } from "../plane/plane3_normalize.js";
2
2
 
3
3
  /**
4
4
  *
5
- * @param {number[]} destination
6
- * @param {number} destination_offset
7
- * @param {number} x
8
- * @param {number} y
9
- * @param {number} z
10
- * @param {number} w
11
- */
12
- function array_set_plane_normalized(
13
- destination, destination_offset,
14
- x, y, z, w
15
- ) {
16
- // compute vector length
17
- const length = v3_length(x, y, z);
18
-
19
- const inverse_length = 1.0 / length;
20
-
21
- // apply normalization
22
- destination[destination_offset] = x * inverse_length;
23
- destination[destination_offset + 1] = y * inverse_length;
24
- destination[destination_offset + 2] = z * inverse_length;
25
- destination[destination_offset + 3] = w * inverse_length;
26
- }
27
-
28
- /**
29
5
  * Set frustum from projection matrix
30
6
  * NOTE: uses Gribb/Hartmann method
31
7
  * @see "Fast Extraction of Viewing Frustum Planes from the WorldView-Projection Matrix", 2001 by Gribb & Hartmann
32
- * @param {number[]|Float32Array} frustum_planes
33
- * @param {number[]} m4
8
+ * @param {number[]|Float32Array} frustum_planes tuples of 4, where each tuple is a plane normal (x,y,z) followed by a planar offset constant [normal_x, normal_y, normal_z, constant]
9
+ * @param {number[]} m4 assumed to be view-projection matrix
34
10
  */
35
11
  export function frustum_from_projection_matrix_array(frustum_planes, m4) {
36
12
 
@@ -46,22 +22,22 @@ export function frustum_from_projection_matrix_array(frustum_planes, m4) {
46
22
  const me12 = m4[12];
47
23
  const me15 = m4[15];
48
24
 
49
- array_set_plane_normalized(frustum_planes, 0, me3 - me0, me7 - me4, me11 - me8, me15 - me12);
50
- array_set_plane_normalized(frustum_planes, 4, me3 + me0, me7 + me4, me11 + me8, me15 + me12);
25
+ plane3_normalize(frustum_planes, 0, me3 - me0, me7 - me4, me11 - me8, me15 - me12);
26
+ plane3_normalize(frustum_planes, 4, me3 + me0, me7 + me4, me11 + me8, me15 + me12);
51
27
 
52
28
  const me1 = m4[1];
53
29
  const me5 = m4[5];
54
30
  const me9 = m4[9];
55
31
  const me13 = m4[13];
56
32
 
57
- array_set_plane_normalized(frustum_planes, 8, me3 + me1, me7 + me5, me11 + me9, me15 + me13);
58
- array_set_plane_normalized(frustum_planes, 12, me3 - me1, me7 - me5, me11 - me9, me15 - me13);
33
+ plane3_normalize(frustum_planes, 8, me3 + me1, me7 + me5, me11 + me9, me15 + me13);
34
+ plane3_normalize(frustum_planes, 12, me3 - me1, me7 - me5, me11 - me9, me15 - me13);
59
35
 
60
36
  const me2 = m4[2];
61
37
  const me6 = m4[6];
62
38
  const me10 = m4[10];
63
39
  const me14 = m4[14];
64
40
 
65
- array_set_plane_normalized(frustum_planes, 16, me3 - me2, me7 - me6, me11 - me10, me15 - me14);
66
- array_set_plane_normalized(frustum_planes, 20, me3 + me2, me7 + me6, me11 + me10, me15 + me14);
41
+ plane3_normalize(frustum_planes, 16, me3 - me2, me7 - me6, me11 - me10, me15 - me14);
42
+ plane3_normalize(frustum_planes, 20, me3 + me2, me7 + me6, me11 + me10, me15 + me14);
67
43
  }
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Normalizes plane representation
3
+ * @param {number[]} destination
4
+ * @param {number} destination_offset
5
+ * @param {number} x plane normal X
6
+ * @param {number} y plane normal Y
7
+ * @param {number} z plane normal Z
8
+ * @param {number} w planar offset constant
9
+ */
10
+ export function plane3_normalize(destination: number[], destination_offset: number, x: number, y: number, z: number, w: number): void;
11
+ //# sourceMappingURL=plane3_normalize.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plane3_normalize.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/plane/plane3_normalize.js"],"names":[],"mappings":"AAEA;;;;;;;;GAQG;AACH,8CAPW,MAAM,EAAE,sBACR,MAAM,KACN,MAAM,KACN,MAAM,KACN,MAAM,KACN,MAAM,QAgBhB"}
@@ -0,0 +1,26 @@
1
+ import { v3_length } from "../../vec3/v3_length.js";
2
+
3
+ /**
4
+ * Normalizes plane representation
5
+ * @param {number[]} destination
6
+ * @param {number} destination_offset
7
+ * @param {number} x plane normal X
8
+ * @param {number} y plane normal Y
9
+ * @param {number} z plane normal Z
10
+ * @param {number} w planar offset constant
11
+ */
12
+ export function plane3_normalize(
13
+ destination, destination_offset,
14
+ x, y, z, w
15
+ ) {
16
+ // compute vector length
17
+ const length = v3_length(x, y, z);
18
+
19
+ const inverse_length = 1.0 / length;
20
+
21
+ // apply normalization
22
+ destination[destination_offset] = x * inverse_length;
23
+ destination[destination_offset + 1] = y * inverse_length;
24
+ destination[destination_offset + 2] = z * inverse_length;
25
+ destination[destination_offset + 3] = w * inverse_length;
26
+ }
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Project a point onto a plane
3
+ * @param {Vector3} result
4
+ * @param {number} point_x
5
+ * @param {number} point_y
6
+ * @param {number} point_z
7
+ * @param {number} normal_x
8
+ * @param {number} normal_y
9
+ * @param {number} normal_z
10
+ * @param {number} plane_offset
11
+ */
12
+ export function plane3_project_point(result: Vector3, point_x: number, point_y: number, point_z: number, normal_x: number, normal_y: number, normal_z: number, plane_offset: number): void;
13
+ //# sourceMappingURL=plane3_project_point.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plane3_project_point.d.ts","sourceRoot":"","sources":["../../../../../../src/core/geom/3d/plane/plane3_project_point.js"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AACH,+DARW,MAAM,WACN,MAAM,WACN,MAAM,YACN,MAAM,YACN,MAAM,YACN,MAAM,gBACN,MAAM,QAgBhB"}
@@ -1,7 +1,7 @@
1
1
  import { v3_distance_above_plane } from "../../vec3/v3_distance_above_plane.js";
2
2
 
3
3
  /**
4
- *
4
+ * Project a point onto a plane
5
5
  * @param {Vector3} result
6
6
  * @param {number} point_x
7
7
  * @param {number} point_y
@@ -11,7 +11,11 @@ import { v3_distance_above_plane } from "../../vec3/v3_distance_above_plane.js";
11
11
  * @param {number} normal_z
12
12
  * @param {number} plane_offset
13
13
  */
14
- export function plane3_projectPoint(result, point_x, point_y, point_z, normal_x, normal_y, normal_z, plane_offset) {
14
+ export function plane3_project_point(
15
+ result,
16
+ point_x, point_y, point_z,
17
+ normal_x, normal_y, normal_z, plane_offset
18
+ ) {
15
19
  const distance = v3_distance_above_plane(point_x, point_y, point_z, normal_x, normal_y, normal_z, plane_offset);
16
20
 
17
21
  const negative_distance = -distance;
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Is the number a power of two?
3
3
  * e.g. 2,4,8,16 etc.
4
- * NOTE: only valid for non-negative integers
4
+ * NOTE: only valid for non-negative integers, includes 0
5
5
  * @param {number} value
6
6
  * @returns {boolean}
7
7
  */
@@ -1 +1 @@
1
- {"version":3,"file":"isPowerOfTwo.d.ts","sourceRoot":"","sources":["../../../../src/core/math/isPowerOfTwo.js"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,oCAHW,MAAM,GACJ,OAAO,CAQnB"}
1
+ {"version":3,"file":"isPowerOfTwo.d.ts","sourceRoot":"","sources":["../../../../src/core/math/isPowerOfTwo.js"],"names":[],"mappings":"AAEA;;;;;;GAMG;AACH,oCAHW,MAAM,GACJ,OAAO,CAMnB"}
@@ -3,14 +3,12 @@ import { assert } from "../assert.js";
3
3
  /**
4
4
  * Is the number a power of two?
5
5
  * e.g. 2,4,8,16 etc.
6
- * NOTE: only valid for non-negative integers
6
+ * NOTE: only valid for non-negative integers, includes 0
7
7
  * @param {number} value
8
8
  * @returns {boolean}
9
9
  */
10
10
  export function isPowerOfTwo(value) {
11
11
  assert.isNonNegativeInteger(value, 'value');
12
12
 
13
-
14
- return (value & (value - 1)) === 0 && value !== 0;
15
-
13
+ return (value & (value - 1)) === 0;
16
14
  }
@@ -8,6 +8,11 @@ declare class LinearValue {
8
8
  * @constructor
9
9
  */
10
10
  constructor(x?: number, a?: number, b?: number);
11
+ /**
12
+ * @readonly
13
+ * @type {Signal}
14
+ */
15
+ readonly onChanged: Signal;
11
16
  /**
12
17
  *
13
18
  * @type {number}
@@ -23,7 +28,6 @@ declare class LinearValue {
23
28
  * @type {number}
24
29
  */
25
30
  b: number;
26
- onChanged: Signal<any, any, any, any, any, any, any, any>;
27
31
  /**
28
32
  *
29
33
  * @param {LinearValue} other
@@ -1 +1 @@
1
- {"version":3,"file":"LinearValue.d.ts","sourceRoot":"","sources":["../../../../src/core/model/LinearValue.js"],"names":[],"mappings":";AAEA;IACI;;;;;;OAMG;IACH,gBALW,MAAM,MACN,MAAM,MACN,MAAM,EAqBhB;IAjBG;;;OAGG;IACH,GAFU,MAAM,CAEgB;IAChC;;;OAGG;IACH,GAFU,MAAM,CAEgB;IAChC;;;OAGG;IACH,GAFU,MAAM,CAEgB;IAEhC,0DAA6B;IAGjC;;;;OAIG;IACH,YAHW,WAAW,GACT,WAAW,CAIvB;IAED;;;;;;OAMG;IACH,OALW,MAAM,KACN,MAAM,KACN,MAAM,GACJ,WAAW,CASvB;IAED;;;;OAIG;IACH,uBAFa,WAAW,CAOvB;IAED;;;;OAIG;IACH,uBAFa,WAAW,CAIvB;IAED;;;;OAIG;IACH,qBAFa,WAAW,CAOvB;IAED;;;;OAIG;IACH,qBAFa,WAAW,CAIvB;IAED;;;OAGG;IACH,YAFa,MAAM,CAKlB;IAED;;;;OAIG;IACH,cAHW,WAAW,GACT,OAAO,CAInB;IAED;;;;MAMC;IAED,0BAEC;CACJ;mBA9HkB,4BAA4B"}
1
+ {"version":3,"file":"LinearValue.d.ts","sourceRoot":"","sources":["../../../../src/core/model/LinearValue.js"],"names":[],"mappings":";AAGA;IAQI;;;;;;OAMG;IACH,gBALW,MAAM,MACN,MAAM,MACN,MAAM,EAwBhB;IAlCD;;;OAGG;IACH,oBAFU,MAAM,CAES;IAcrB;;;OAGG;IACH,GAFU,MAAM,CAEN;IACV;;;OAGG;IACH,GAFU,MAAM,CAEN;IACV;;;OAGG;IACH,GAFU,MAAM,CAEN;IAId;;;;OAIG;IACH,YAHW,WAAW,GACT,WAAW,CAIvB;IAED;;;;;;OAMG;IACH,OALW,MAAM,KACN,MAAM,KACN,MAAM,GACJ,WAAW,CASvB;IAED;;;;OAIG;IACH,uBAFa,WAAW,CAOvB;IAED;;;;OAIG;IACH,uBAFa,WAAW,CAIvB;IAED;;;;OAIG;IACH,qBAFa,WAAW,CAOvB;IAED;;;;OAIG;IACH,qBAFa,WAAW,CAIvB;IAED;;;OAGG;IACH,YAFa,MAAM,CAKlB;IAED;;;;OAIG;IACH,cAHW,WAAW,GACT,OAAO,CAInB;IAED;;;;MAMC;IAED,0BAEC;CACJ;mBAxIkB,4BAA4B"}