@woosh/meep-engine 2.113.3 → 2.113.4

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 (57) hide show
  1. package/build/meep.cjs +29 -28
  2. package/build/meep.min.js +1 -1
  3. package/build/meep.module.js +29 -28
  4. package/package.json +1 -1
  5. package/src/core/collection/array/combine_hash.d.ts +7 -0
  6. package/src/core/collection/array/combine_hash.d.ts.map +1 -0
  7. package/src/core/collection/array/combine_hash.js +13 -0
  8. package/src/core/collection/array/computeHashIntegerArray.d.ts.map +1 -1
  9. package/src/core/collection/array/computeHashIntegerArray.js +4 -7
  10. package/src/core/function/FunctionCompiler.js +3 -3
  11. package/src/core/geom/ConicRay.js +2 -2
  12. package/src/core/geom/Vector4.js +2 -2
  13. package/src/core/model/node-graph/node/NodeInstancePortReference.js +2 -2
  14. package/src/core/model/reactive/model/ReactiveBinaryExpression.d.ts.map +1 -1
  15. package/src/core/model/reactive/model/ReactiveBinaryExpression.js +2 -2
  16. package/src/core/model/reactive/model/terminal/ReactiveReference.d.ts.map +1 -1
  17. package/src/core/model/reactive/model/terminal/ReactiveReference.js +2 -2
  18. package/src/engine/asset/AssetDescription.js +2 -2
  19. package/src/engine/asset/loaders/material/computeMaterialHash.js +6 -6
  20. package/src/engine/asset/loaders/material/computeTextureHash.js +2 -2
  21. package/src/engine/ecs/animation/Animation.js +2 -2
  22. package/src/engine/ecs/animation/AnimationClip.d.ts.map +1 -1
  23. package/src/engine/ecs/animation/AnimationClip.js +4 -4
  24. package/src/engine/ecs/gui/GUIElement.js +2 -2
  25. package/src/engine/ecs/gui/hud/HeadsUpDisplay.js +2 -2
  26. package/src/engine/ecs/gui/position/ViewportPosition.js +2 -2
  27. package/src/engine/ecs/ik/IKConstraint.d.ts.map +1 -1
  28. package/src/engine/ecs/ik/IKConstraint.js +3 -3
  29. package/src/engine/graphics/ecs/animation/animator/AnimationClip.d.ts.map +1 -1
  30. package/src/engine/graphics/ecs/animation/animator/AnimationClip.js +4 -4
  31. package/src/engine/graphics/ecs/animation/animator/AnimationClipDefinition.js +4 -4
  32. package/src/engine/graphics/ecs/animation/animator/AnimationNotification.js +2 -2
  33. package/src/engine/graphics/ecs/animation/animator/AnimationNotificationDefinition.js +3 -3
  34. package/src/engine/graphics/ecs/animation/animator/graph/AnimationGraph.js +2 -2
  35. package/src/engine/graphics/ecs/animation/animator/graph/definition/AnimationGraphDefinition.d.ts.map +1 -1
  36. package/src/engine/graphics/ecs/animation/animator/graph/definition/AnimationGraphDefinition.js +8 -8
  37. package/src/engine/graphics/ecs/animation/animator/graph/definition/AnimationStateDefinition.js +2 -2
  38. package/src/engine/graphics/ecs/animation/animator/graph/definition/AnimationTransitionDefinition.js +3 -3
  39. package/src/engine/graphics/particles/particular/engine/emitter/ParticleEmitter.js +2 -2
  40. package/src/engine/graphics/particles/particular/engine/emitter/ParticleLayer.js +2 -2
  41. package/src/engine/graphics/particles/particular/engine/parameter/ParameterLookupTable.d.ts.map +1 -1
  42. package/src/engine/graphics/particles/particular/engine/parameter/ParameterLookupTable.js +8 -3
  43. package/src/engine/graphics/particles/particular/engine/parameter/ParameterTrack.d.ts.map +1 -1
  44. package/src/engine/graphics/particles/particular/engine/parameter/ParameterTrack.js +3 -3
  45. package/src/engine/graphics/particles/particular/engine/parameter/ParticleParameter.d.ts.map +1 -1
  46. package/src/engine/graphics/particles/particular/engine/parameter/ParticleParameter.js +4 -4
  47. package/src/engine/graphics/render/buffer/slot/parameter/ProgramValueSlotParameter.d.ts.map +1 -1
  48. package/src/engine/graphics/render/buffer/slot/parameter/ProgramValueSlotParameter.js +4 -4
  49. package/src/engine/graphics/render/frame_graph/resource/TextureResourceDescriptor.js +2 -2
  50. package/src/engine/grid/obstacle/GridObstacle.js +2 -2
  51. package/src/engine/intelligence/behavior/selector/WeightedElement.js +2 -2
  52. package/src/engine/sound/ecs/emitter/SoundEmitter.js +2 -2
  53. package/src/engine/sound/ecs/emitter/SoundTrack.d.ts.map +1 -1
  54. package/src/engine/sound/ecs/emitter/SoundTrack.js +6 -6
  55. package/src/misc/makeMaterialIconCached.js +2 -2
  56. package/src/view/common/HTMLElementCacheKey.d.ts.map +1 -1
  57. package/src/view/common/HTMLElementCacheKey.js +5 -5
@@ -50533,11 +50533,12 @@ function computeIntegerArrayHash(data, offset, length) {
50533
50533
  }
50534
50534
 
50535
50535
  /**
50536
- * Computes hash on integer values
50536
+ * Computes hash on integer values, useful for building composite hashes
50537
50537
  * @param {...number} value
50538
50538
  * @returns {number}
50539
50539
  */
50540
- function computeHashIntegerArray(...value) {
50540
+ function combine_hash(...value) {
50541
+
50541
50542
  return computeIntegerArrayHash(value, 0, value.length);
50542
50543
  }
50543
50544
 
@@ -50799,7 +50800,7 @@ class Vector4 {
50799
50800
  * @return {number}
50800
50801
  */
50801
50802
  hash() {
50802
- return computeHashIntegerArray(
50803
+ return combine_hash(
50803
50804
  computeHashFloat(this.x),
50804
50805
  computeHashFloat(this.y),
50805
50806
  computeHashFloat(this.z),
@@ -75863,15 +75864,6 @@ class GenericRendererAdapter extends AbstractRenderAdapter {
75863
75864
 
75864
75865
  }
75865
75866
 
75866
- /**
75867
- *
75868
- * @param {Plane} plane
75869
- * @returns {number}
75870
- */
75871
- function planeHash(plane) {
75872
- return mortonEncode_magicbits(plane.normal.x, plane.normal.y, plane.normal.z) ^ plane.constant;
75873
- }
75874
-
75875
75867
  /**
75876
75868
  * @template T
75877
75869
  * @param {T[]} array
@@ -75897,6 +75889,23 @@ function computeHashArray(array, elementHashFunction, thisArg) {
75897
75889
  return hash;
75898
75890
  }
75899
75891
 
75892
+ /**
75893
+ *
75894
+ * @param {THREE.Color} c
75895
+ */
75896
+ function computeHashColor(c) {
75897
+ return c.getHex();
75898
+ }
75899
+
75900
+ /**
75901
+ *
75902
+ * @param {Plane} plane
75903
+ * @returns {number}
75904
+ */
75905
+ function planeHash(plane) {
75906
+ return mortonEncode_magicbits(plane.normal.x, plane.normal.y, plane.normal.z) ^ plane.constant;
75907
+ }
75908
+
75900
75909
  /**
75901
75910
  *
75902
75911
  * @param {THREE.Texture} texture
@@ -75910,14 +75919,6 @@ function textureHashById(texture) {
75910
75919
  return texture.id;
75911
75920
  }
75912
75921
 
75913
- /**
75914
- *
75915
- * @param {THREE.Color} c
75916
- */
75917
- function computeHashColor(c) {
75918
- return c.getHex();
75919
- }
75920
-
75921
75922
  /**
75922
75923
  *
75923
75924
  * @param {Material|MeshStandardMaterial|ShaderMaterial} material
@@ -75925,7 +75926,7 @@ function computeHashColor(c) {
75925
75926
  */
75926
75927
  function computeMaterialHash(material) {
75927
75928
 
75928
- let hash = computeHashIntegerArray(
75929
+ let hash = combine_hash(
75929
75930
  computeHashFloat(material.alphaTest),
75930
75931
  material.blendDst,
75931
75932
  material.blendDstAlpha === null ? 0 : computeHashFloat(material.blendDstAlpha),
@@ -75959,7 +75960,7 @@ function computeMaterialHash(material) {
75959
75960
 
75960
75961
 
75961
75962
  if (material.isMeshStandardMaterial) {
75962
- hash = computeHashIntegerArray(
75963
+ hash = combine_hash(
75963
75964
  hash,
75964
75965
  computeHashColor(material.color),
75965
75966
  computeHashFloat(material.roughness),
@@ -76507,7 +76508,7 @@ function computeTextureHash(t) {
76507
76508
 
76508
76509
  const specificHash = computeSpecificHash(t);
76509
76510
 
76510
- return computeHashIntegerArray(
76511
+ return combine_hash(
76511
76512
  t.mapping,
76512
76513
  t.wrapS,
76513
76514
  t.wrapT,
@@ -85548,7 +85549,7 @@ class AssetDescription {
85548
85549
  * @returns {number}
85549
85550
  */
85550
85551
  hash() {
85551
- return computeHashIntegerArray(
85552
+ return combine_hash(
85552
85553
  computeStringHash(this.path),
85553
85554
  computeStringHash(this.type)
85554
85555
  );
@@ -98228,7 +98229,7 @@ function isArrayEqual(first, second) {
98228
98229
  * @param {KeyValuePair<string,string>} pair
98229
98230
  */
98230
98231
  function computeStringPairHash(pair) {
98231
- return computeHashIntegerArray(
98232
+ return combine_hash(
98232
98233
  computeStringHash(pair.key),
98233
98234
  computeStringHash(pair.value)
98234
98235
  );
@@ -98463,7 +98464,7 @@ class HTMLElementCacheKey {
98463
98464
  const tagHash = computeStringHash(this.tag);
98464
98465
 
98465
98466
 
98466
- this.__hash = computeHashIntegerArray(
98467
+ this.__hash = combine_hash(
98467
98468
  styleHash,
98468
98469
  attributeHash,
98469
98470
  tagHash
@@ -102796,7 +102797,7 @@ class GUIElement {
102796
102797
  * @return {number}
102797
102798
  */
102798
102799
  hash() {
102799
- return computeHashIntegerArray(
102800
+ return combine_hash(
102800
102801
  this.flags,
102801
102802
  computeStringHash(this.klass),
102802
102803
  this.anchor.hash(),
@@ -102933,7 +102934,7 @@ class ViewportPosition {
102933
102934
  }
102934
102935
 
102935
102936
  hash() {
102936
- return computeHashIntegerArray(
102937
+ return combine_hash(
102937
102938
  this.position.hash(),
102938
102939
  this.offset.hash(),
102939
102940
  this.anchor.hash(),
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "description": "Fully featured ECS game engine written in JavaScript",
6
6
  "type": "module",
7
7
  "author": "Alexander Goldring",
8
- "version": "2.113.3",
8
+ "version": "2.113.4",
9
9
  "main": "build/meep.module.js",
10
10
  "module": "build/meep.module.js",
11
11
  "exports": {
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Computes hash on integer values, useful for building composite hashes
3
+ * @param {...number} value
4
+ * @returns {number}
5
+ */
6
+ export function combine_hash(...value: number[]): number;
7
+ //# sourceMappingURL=combine_hash.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"combine_hash.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/array/combine_hash.js"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,uCAHc,MAAM,KACP,MAAM,CAMlB"}
@@ -0,0 +1,13 @@
1
+ import { assert } from "../../assert.js";
2
+ import { computeIntegerArrayHash } from "../../primitives/array/computeIntegerArrayHash.js";
3
+
4
+ /**
5
+ * Computes hash on integer values, useful for building composite hashes
6
+ * @param {...number} value
7
+ * @returns {number}
8
+ */
9
+ export function combine_hash(...value) {
10
+ assert.isArray(value, 'value');
11
+
12
+ return computeIntegerArrayHash(value, 0, value.length);
13
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"computeHashIntegerArray.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/array/computeHashIntegerArray.js"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,kDAHc,MAAM,KACP,MAAM,CAIlB"}
1
+ {"version":3,"file":"computeHashIntegerArray.d.ts","sourceRoot":"","sources":["../../../../../src/core/collection/array/computeHashIntegerArray.js"],"names":[],"mappings":"AAEA;;;GAGG;AACH,gDAFsB,CAAC,MAAM,CAAC,OAAG,MAAM,CAEa"}
@@ -1,10 +1,7 @@
1
- import { computeIntegerArrayHash } from "../../primitives/array/computeIntegerArrayHash.js";
1
+ import { combine_hash } from "./combine_hash.js";
2
2
 
3
3
  /**
4
- * Computes hash on integer values
5
- * @param {...number} value
6
- * @returns {number}
4
+ * @deprecated use {@link combine_hash} instead
5
+ * @type {function(...[number]): number}
7
6
  */
8
- export function computeHashIntegerArray(...value) {
9
- return computeIntegerArrayHash(value, 0, value.length);
10
- }
7
+ export const computeHashIntegerArray = combine_hash;
@@ -1,11 +1,11 @@
1
1
  import { assert } from "../assert.js";
2
2
  import { Cache } from "../cache/Cache.js";
3
+ import { combine_hash } from "../collection/array/combine_hash.js";
4
+ import { computeHashArray } from "../collection/array/computeHashArray.js";
3
5
  import { isArrayEqualStrict } from "../collection/array/isArrayEqualStrict.js";
4
6
  import { invokeObjectEquals } from "../model/object/invokeObjectEquals.js";
5
7
  import { invokeObjectHash } from "../model/object/invokeObjectHash.js";
6
8
  import { computeStringHash } from "../primitives/strings/computeStringHash.js";
7
- import { computeHashArray } from "../collection/array/computeHashArray.js";
8
- import { computeHashIntegerArray } from "../collection/array/computeHashIntegerArray.js";
9
9
  import { string_compute_byte_size } from "../primitives/strings/string_compute_byte_size.js";
10
10
 
11
11
  /**
@@ -49,7 +49,7 @@ class FunctionDefinition {
49
49
  }
50
50
 
51
51
  updateHash() {
52
- this.__hash = computeHashIntegerArray(
52
+ this.__hash = combine_hash(
53
53
  computeStringHash(this.name),
54
54
  computeStringHash(this.body),
55
55
  computeHashArray(this.args, computeStringHash)
@@ -1,5 +1,5 @@
1
1
  import { assert } from "../assert.js";
2
- import { computeHashIntegerArray } from "../collection/array/computeHashIntegerArray.js";
2
+ import { combine_hash } from "../collection/array/combine_hash.js";
3
3
  import { EPSILON } from "../math/EPSILON.js";
4
4
  import { epsilonEquals } from "../math/epsilonEquals.js";
5
5
  import { computeHashFloat } from "../primitives/numbers/computeHashFloat.js";
@@ -81,7 +81,7 @@ export class ConicRay {
81
81
  }
82
82
 
83
83
  hash() {
84
- return computeHashIntegerArray(
84
+ return combine_hash(
85
85
  computeHashFloat(this.angle),
86
86
  this.direction.hash()
87
87
  );
@@ -1,5 +1,5 @@
1
1
  import { assert } from "../assert.js";
2
- import { computeHashIntegerArray } from "../collection/array/computeHashIntegerArray.js";
2
+ import { combine_hash } from "../collection/array/combine_hash.js";
3
3
  import { Signal } from "../events/signal/Signal.js";
4
4
  import { lerp } from "../math/lerp.js";
5
5
  import { computeHashFloat } from "../primitives/numbers/computeHashFloat.js";
@@ -273,7 +273,7 @@ class Vector4 {
273
273
  * @return {number}
274
274
  */
275
275
  hash() {
276
- return computeHashIntegerArray(
276
+ return combine_hash(
277
277
  computeHashFloat(this.x),
278
278
  computeHashFloat(this.y),
279
279
  computeHashFloat(this.z),
@@ -1,5 +1,5 @@
1
1
  import { assert } from "../../../assert.js";
2
- import { computeHashIntegerArray } from "../../../collection/array/computeHashIntegerArray.js";
2
+ import { combine_hash } from "../../../collection/array/combine_hash.js";
3
3
 
4
4
  /**
5
5
  *
@@ -133,7 +133,7 @@ export class NodeInstancePortReference {
133
133
  }
134
134
 
135
135
  hash() {
136
- return computeHashIntegerArray(
136
+ return combine_hash(
137
137
  this.instance.hash(),
138
138
  this.port.hash()
139
139
  );
@@ -1 +1 @@
1
- {"version":3,"file":"ReactiveBinaryExpression.d.ts","sourceRoot":"","sources":["../../../../../../src/core/model/reactive/model/ReactiveBinaryExpression.js"],"names":[],"mappings":"AAIA;;GAEG;AACH;IACI,cAqBC;IAlBG;;;OAGG;IACH,MAFU,0BAAmB,IAAI,CAEjB;IAChB;;;OAGG;IACH,OAFU,0BAAmB,IAAI,CAEhB;IAEjB;;;;OAIG;IACH,mBAA2B;IAI/B,uBAQC;IAED,wBAcC;IAED,eAMC;IAED,0BAQC;IAED,eAUC;IAED;;;OAGG;IACH,kCAFa,IAAE,OAAO,GAAC,MAAM,CAI5B;IAED,2CAKC;IAED;;;;OAIG;IACH,qCAkBC;IAED,mBAaC;IAyBL;;;;;;OAMG;IACH,wBAFU,OAAO,CAE+B;IAEhD;;;OAGG;IACH,6BAFU,OAAO,CAEoC;CAfpD;mCAlKkC,yBAAyB"}
1
+ {"version":3,"file":"ReactiveBinaryExpression.d.ts","sourceRoot":"","sources":["../../../../../../src/core/model/reactive/model/ReactiveBinaryExpression.js"],"names":[],"mappings":"AAIA;;GAEG;AACH;IACI,cAqBC;IAlBG;;;OAGG;IACH,MAFU,0BAAmB,IAAI,CAEjB;IAChB;;;OAGG;IACH,OAFU,0BAAmB,IAAI,CAEhB;IAEjB;;;;OAIG;IACH,mBAA2B;IAI/B,uBAQC;IAED,wBAcC;IAED,eAMC;IAED,0BAQC;IAED,eAUC;IAED;;;OAGG;IACH,kCAFa,IAAE,OAAO,GAAC,MAAM,CAI5B;IAED,2CAKC;IAED;;;;OAIG;IACH,qCAkBC;IAED,mBAaC;IAyBL;;;;;;OAMG;IACH,wBAFU,OAAO,CAE+B;IAEhD;;;OAGG;IACH,6BAFU,OAAO,CAEoC;CAfpD;mCAjKkC,yBAAyB"}
@@ -1,6 +1,6 @@
1
1
  import { assert } from "../../../assert.js";
2
+ import { combine_hash } from "../../../collection/array/combine_hash.js";
2
3
  import { ReactiveExpression } from "./ReactiveExpression.js";
3
- import { computeHashIntegerArray } from "../../../collection/array/computeHashIntegerArray.js";
4
4
 
5
5
  /**
6
6
  * @extends {ReactiveExpression}
@@ -56,7 +56,7 @@ export class ReactiveBinaryExpression extends ReactiveExpression {
56
56
  }
57
57
 
58
58
  hash() {
59
- return computeHashIntegerArray(
59
+ return combine_hash(
60
60
  this.left.hash(),
61
61
  this.right.hash(),
62
62
  super.hash()
@@ -1 +1 @@
1
- {"version":3,"file":"ReactiveReference.d.ts","sourceRoot":"","sources":["../../../../../../../src/core/model/reactive/model/terminal/ReactiveReference.js"],"names":[],"mappings":"AAOA;;GAEG;AACH;IAEI;;;OAGG;IACH,kBAFW,MAAM,EAgBhB;IAXG;;;OAGG;IACH,MAFU,MAAM,CAEA;IAEhB;;;OAGG;IACH,QAFU,mDAA0C,CAElC;IAGtB;;;OAGG;IACH,YAFW,iBAAiB,QAU3B;IAED;;;OAGG;IACH,SAFY,iBAAiB,CAQ5B;IAED,gCAEC;IAED,2BAmBC;IAED,mBAQC;IAED,wBAKC;IAED,iBAEC;IAGD,eAKC;IAED,0BAGC;IAOL;;;OAGG;IACH,qBAFU,OAAO,CAEqB;IAEtC;;;OAGG;IACH,sBAFU,OAAO,CAEsB;CAZtC;;IAcD;;;;;OAKG;IACH,6DAaC;;mCAtJkC,0BAA0B"}
1
+ {"version":3,"file":"ReactiveReference.d.ts","sourceRoot":"","sources":["../../../../../../../src/core/model/reactive/model/terminal/ReactiveReference.js"],"names":[],"mappings":"AAOA;;GAEG;AACH;IAEI;;;OAGG;IACH,kBAFW,MAAM,EAgBhB;IAXG;;;OAGG;IACH,MAFU,MAAM,CAEA;IAEhB;;;OAGG;IACH,QAFU,mDAA0C,CAElC;IAGtB;;;OAGG;IACH,YAFW,iBAAiB,QAU3B;IAED;;;OAGG;IACH,SAFY,iBAAiB,CAQ5B;IAED,gCAEC;IAED,2BAmBC;IAED,mBAQC;IAED,wBAKC;IAED,iBAEC;IAGD,eAKC;IAED,0BAGC;IAOL;;;OAGG;IACH,qBAFU,OAAO,CAEqB;IAEtC;;;OAGG;IACH,sBAFU,OAAO,CAEsB;CAZtC;;IAcD;;;;;OAKG;IACH,6DAaC;;mCArJkC,0BAA0B"}
@@ -1,8 +1,8 @@
1
1
  import { assert } from "../../../../assert.js";
2
+ import { combine_hash } from "../../../../collection/array/combine_hash.js";
2
3
  import DataType from "../../../../parser/simple/DataType.js";
3
4
  import { computeStringHash } from "../../../../primitives/strings/computeStringHash.js";
4
5
  import { ReactiveExpression } from "../ReactiveExpression.js";
5
- import { computeHashIntegerArray } from "../../../../collection/array/computeHashIntegerArray.js";
6
6
 
7
7
 
8
8
  /**
@@ -104,7 +104,7 @@ export class ReactiveReference extends ReactiveExpression {
104
104
 
105
105
 
106
106
  hash() {
107
- return computeHashIntegerArray(
107
+ return combine_hash(
108
108
  computeStringHash(this.name),
109
109
  super.hash()
110
110
  );
@@ -1,5 +1,5 @@
1
1
  import { assert } from "../../core/assert.js";
2
- import { computeHashIntegerArray } from "../../core/collection/array/computeHashIntegerArray.js";
2
+ import { combine_hash } from "../../core/collection/array/combine_hash.js";
3
3
  import { computeStringHash } from "../../core/primitives/strings/computeStringHash.js";
4
4
 
5
5
  export class AssetDescription {
@@ -39,7 +39,7 @@ export class AssetDescription {
39
39
  * @returns {number}
40
40
  */
41
41
  hash() {
42
- return computeHashIntegerArray(
42
+ return combine_hash(
43
43
  computeStringHash(this.path),
44
44
  computeStringHash(this.type)
45
45
  );
@@ -1,10 +1,10 @@
1
- import { planeHash } from "./planeHash.js";
2
- import { computeStringHash } from "../../../../core/primitives/strings/computeStringHash.js";
1
+ import { combine_hash } from "../../../../core/collection/array/combine_hash.js";
3
2
  import { computeHashArray } from "../../../../core/collection/array/computeHashArray.js";
4
- import { computeHashIntegerArray } from "../../../../core/collection/array/computeHashIntegerArray.js";
5
3
  import { computeHashFloat } from "../../../../core/primitives/numbers/computeHashFloat.js";
6
- import { textureHashById } from "./textureHashById.js";
4
+ import { computeStringHash } from "../../../../core/primitives/strings/computeStringHash.js";
7
5
  import { computeHashColor } from "./computeHashColor.js";
6
+ import { planeHash } from "./planeHash.js";
7
+ import { textureHashById } from "./textureHashById.js";
8
8
 
9
9
  /**
10
10
  *
@@ -13,7 +13,7 @@ import { computeHashColor } from "./computeHashColor.js";
13
13
  */
14
14
  export function computeMaterialHash(material) {
15
15
 
16
- let hash = computeHashIntegerArray(
16
+ let hash = combine_hash(
17
17
  computeHashFloat(material.alphaTest),
18
18
  material.blendDst,
19
19
  material.blendDstAlpha === null ? 0 : computeHashFloat(material.blendDstAlpha),
@@ -47,7 +47,7 @@ export function computeMaterialHash(material) {
47
47
 
48
48
 
49
49
  if (material.isMeshStandardMaterial) {
50
- hash = computeHashIntegerArray(
50
+ hash = combine_hash(
51
51
  hash,
52
52
  computeHashColor(material.color),
53
53
  computeHashFloat(material.roughness),
@@ -1,4 +1,4 @@
1
- import { computeHashIntegerArray } from "../../../../core/collection/array/computeHashIntegerArray.js";
1
+ import { combine_hash } from "../../../../core/collection/array/combine_hash.js";
2
2
  import { murmur3_32 } from "../../../../core/math/hash/murmur3_32.js";
3
3
  import { computeHashFloat } from "../../../../core/primitives/numbers/computeHashFloat.js";
4
4
  import { computeStringHash } from "../../../../core/primitives/strings/computeStringHash.js";
@@ -123,7 +123,7 @@ export function computeTextureHash(t) {
123
123
 
124
124
  const specificHash = computeSpecificHash(t);
125
125
 
126
- return computeHashIntegerArray(
126
+ return combine_hash(
127
127
  t.mapping,
128
128
  t.wrapS,
129
129
  t.wrapT,
@@ -1,4 +1,4 @@
1
- import { computeHashIntegerArray } from "../../../core/collection/array/computeHashIntegerArray.js";
1
+ import { combine_hash } from "../../../core/collection/array/combine_hash.js";
2
2
  import List from '../../../core/collection/list/List.js';
3
3
  import { computeHashFloat } from "../../../core/primitives/numbers/computeHashFloat.js";
4
4
  import { AnimationClip } from "./AnimationClip.js";
@@ -115,7 +115,7 @@ export class Animation {
115
115
  * @returns {number}
116
116
  */
117
117
  hash() {
118
- return computeHashIntegerArray(
118
+ return combine_hash(
119
119
  this.clips.hash(),
120
120
  computeHashFloat(this.debtTime)
121
121
  );
@@ -1 +1 @@
1
- {"version":3,"file":"AnimationClip.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/animation/AnimationClip.js"],"names":[],"mappings":"AAKA;IAEQ,qBAAkC;IAClC,6BAAyC;IAEzC;;;OAGG;IACH,QAFU,OAAO,CAEW;IAE5B;;;OAGG;IACH,WAFU,OAAO,CAEc;IAE/B;;;OAGG;IACH,OAFU,MAAM,CAEF;IAGlB;;;;OAIG;IACH,cAHW,aAAa,GACX,OAAO,CAQnB;IAED;;;OAGG;IACH,QAFa,MAAM,CAUlB;IAED;;;;OAIG;IACH,WAHW,MAAM,oBAAkB,GACtB,OAAO,CAInB;IAED,0BA4BC;IAED;;;;;;MAQC;IAED;;;OAGG;IACH,2CAQC;IAED;;;OAGG;IACH,6CAOC;CACJ;2BAnI0B,uCAAuC;4BACtC,wCAAwC;oBAChD,+BAA+B"}
1
+ {"version":3,"file":"AnimationClip.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/animation/AnimationClip.js"],"names":[],"mappings":"AAKA;IAEQ,qBAAkC;IAClC,6BAAyC;IAEzC;;;OAGG;IACH,QAFU,OAAO,CAEW;IAE5B;;;OAGG;IACH,WAFU,OAAO,CAEc;IAE/B;;;OAGG;IACH,OAFU,MAAM,CAEF;IAGlB;;;;OAIG;IACH,cAHW,aAAa,GACX,OAAO,CAQnB;IAED;;;OAGG;IACH,QAFa,MAAM,CAUlB;IAED;;;;OAIG;IACH,WAHW,MAAM,oBAAkB,GACtB,OAAO,CAInB;IAED,0BA4BC;IAED;;;;;;MAQC;IAED;;;OAGG;IACH,2CAQC;IAED;;;OAGG;IACH,6CAOC;CACJ;2BAhI0B,uCAAuC;4BADtC,wCAAwC;oBADhD,+BAA+B"}
@@ -1,7 +1,7 @@
1
- import ObservedString from "../../../core/model/ObservedString.js";
2
- import ObservedInteger from "../../../core/model/ObservedInteger.js";
1
+ import { combine_hash } from "../../../core/collection/array/combine_hash.js";
3
2
  import Vector1 from "../../../core/geom/Vector1.js";
4
- import { computeHashIntegerArray } from "../../../core/collection/array/computeHashIntegerArray.js";
3
+ import ObservedInteger from "../../../core/model/ObservedInteger.js";
4
+ import ObservedString from "../../../core/model/ObservedString.js";
5
5
 
6
6
  export class AnimationClip {
7
7
  constructor() {
@@ -45,7 +45,7 @@ export class AnimationClip {
45
45
  * @returns {number}
46
46
  */
47
47
  hash() {
48
- return computeHashIntegerArray(
48
+ return combine_hash(
49
49
  this.name.hash(),
50
50
  this.repeatCount.hash(),
51
51
  this.weight.hash(),
@@ -1,5 +1,5 @@
1
1
  import { assert } from "../../../core/assert.js";
2
- import { computeHashIntegerArray } from "../../../core/collection/array/computeHashIntegerArray.js";
2
+ import { combine_hash } from "../../../core/collection/array/combine_hash.js";
3
3
  import Vector2 from '../../../core/geom/Vector2.js';
4
4
  import { objectDeepEquals } from "../../../core/model/object/objectDeepEquals.js";
5
5
  import ObservedBoolean from "../../../core/model/ObservedBoolean.js";
@@ -148,7 +148,7 @@ class GUIElement {
148
148
  * @return {number}
149
149
  */
150
150
  hash() {
151
- return computeHashIntegerArray(
151
+ return combine_hash(
152
152
  this.flags,
153
153
  computeStringHash(this.klass),
154
154
  this.anchor.hash(),
@@ -1,4 +1,4 @@
1
- import { computeHashIntegerArray } from "../../../../core/collection/array/computeHashIntegerArray.js";
1
+ import { combine_hash } from "../../../../core/collection/array/combine_hash.js";
2
2
  import Vector3 from '../../../../core/geom/Vector3.js';
3
3
  import { HeadsUpDisplayFlag } from "./HeadsUpDisplayFlag.js";
4
4
 
@@ -73,7 +73,7 @@ class HeadsUpDisplay {
73
73
  * @return {number}
74
74
  */
75
75
  hash() {
76
- return computeHashIntegerArray(
76
+ return combine_hash(
77
77
  this.flags,
78
78
  this.worldOffset.hash()
79
79
  );
@@ -1,4 +1,4 @@
1
- import { computeHashIntegerArray } from "../../../../core/collection/array/computeHashIntegerArray.js";
1
+ import { combine_hash } from "../../../../core/collection/array/combine_hash.js";
2
2
  import Vector2 from "../../../../core/geom/Vector2.js";
3
3
  import ObservedBoolean from "../../../../core/model/ObservedBoolean.js";
4
4
  import { computeHashFloat } from "../../../../core/primitives/numbers/computeHashFloat.js";
@@ -86,7 +86,7 @@ class ViewportPosition {
86
86
  }
87
87
 
88
88
  hash() {
89
- return computeHashIntegerArray(
89
+ return combine_hash(
90
90
  this.position.hash(),
91
91
  this.offset.hash(),
92
92
  this.anchor.hash(),
@@ -1 +1 @@
1
- {"version":3,"file":"IKConstraint.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/ik/IKConstraint.js"],"names":[],"mappings":"AAKA;IAEI;;;OAGG;IACH,iBAAc;IAEd;;;;OAIG;IACH,QAFU,MAAM,CAEL;IAEX;;;OAGG;IACH,UAFU,eAAe,CAEY;IAErC;;;OAGG;IACH,UAFU,MAAM,CAEH;IAEb;;;OAGG;IACH,OAFU,MAAM,CAEA;IAEhB;;;OAGG;IACH,QAFU,MAAM,CAEA;IAGhB;;;OAGG;IACH,YAFW,YAAY,QAStB;IAED,sBAMC;IAED;;;;OAIG;IACH,cAHW,YAAY,GACV,OAAO,CASnB;IAED;;;OAGG;IACH,QAFY,MAAM,CAWjB;CACJ;gCA9F+B,gDAAgD"}
1
+ {"version":3,"file":"IKConstraint.d.ts","sourceRoot":"","sources":["../../../../../src/engine/ecs/ik/IKConstraint.js"],"names":[],"mappings":"AAKA;IAEI;;;OAGG;IACH,iBAAc;IAEd;;;;OAIG;IACH,QAFU,MAAM,CAEL;IAEX;;;OAGG;IACH,UAFU,eAAe,CAEY;IAErC;;;OAGG;IACH,UAFU,MAAM,CAEH;IAEb;;;OAGG;IACH,OAFU,MAAM,CAEA;IAEhB;;;OAGG;IACH,QAFU,MAAM,CAEA;IAGhB;;;OAGG;IACH,YAFW,YAAY,QAStB;IAED,sBAMC;IAED;;;;OAIG;IACH,cAHW,YAAY,GACV,OAAO,CASnB;IAED;;;OAGG;IACH,QAFY,MAAM,CAWjB;CACJ;gCA7F+B,gDAAgD"}
@@ -1,7 +1,7 @@
1
+ import { combine_hash } from "../../../core/collection/array/combine_hash.js";
1
2
  import { NumericInterval } from "../../../core/math/interval/NumericInterval.js";
2
- import { computeHashIntegerArray } from "../../../core/collection/array/computeHashIntegerArray.js";
3
- import { computeStringHash } from "../../../core/primitives/strings/computeStringHash.js";
4
3
  import { computeHashFloat } from "../../../core/primitives/numbers/computeHashFloat.js";
4
+ import { computeStringHash } from "../../../core/primitives/strings/computeStringHash.js";
5
5
 
6
6
  export class IKConstraint {
7
7
 
@@ -83,7 +83,7 @@ export class IKConstraint {
83
83
  * @return {number}
84
84
  */
85
85
  hash() {
86
- return computeHashIntegerArray(
86
+ return combine_hash(
87
87
  computeStringHash(this.effector),
88
88
  computeHashFloat(this.offset),
89
89
  this.distance.hash(),
@@ -1 +1 @@
1
- {"version":3,"file":"AnimationClip.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/ecs/animation/animator/AnimationClip.js"],"names":[],"mappings":"AAOA;IAEQ;;;OAGG;IACH,6BAAe;IAEf;;;OAGG;IACH,QAFU,MAAM,CAED;IAEf;;;OAGG;IACH,WAFU,MAAM,CAEE;IAElB;;;OAGG;IACH,OAFU,MAAM,GAAC,iBAAiB,CAEpB;IAGlB;;;;;;OAMG;IACH,8BALW,MAAM,sCAEN,MAAM,SACN,MAAM,QA+FhB;IAED;;;OAGG;IACH,8DAeC;IAED;;;;OAIG;IACH,cAHW,MAAM,GAAC,iBAAiB,GACtB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,iBAAiB,GACtB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,iBAAiB,SACxB,OAAO,QAQjB;IAED;;;;OAIG;IACH,cAHW,MAAM,GAAC,iBAAiB,GACtB,OAAO,CAInB;IAGD;;;;OAIG;IACH,cAHW,aAAa,GACX,OAAO,CAYnB;IAED;;OAEG;IACH,QAFa,MAAM,CASlB;CACJ;kCAjOiC,wBAAwB"}
1
+ {"version":3,"file":"AnimationClip.d.ts","sourceRoot":"","sources":["../../../../../../../src/engine/graphics/ecs/animation/animator/AnimationClip.js"],"names":[],"mappings":"AAOA;IAEQ;;;OAGG;IACH,6BAAe;IAEf;;;OAGG;IACH,QAFU,MAAM,CAED;IAEf;;;OAGG;IACH,WAFU,MAAM,CAEE;IAElB;;;OAGG;IACH,OAFU,MAAM,GAAC,iBAAiB,CAEpB;IAGlB;;;;;;OAMG;IACH,8BALW,MAAM,sCAEN,MAAM,SACN,MAAM,QA+FhB;IAED;;;OAGG;IACH,8DAeC;IAED;;;;OAIG;IACH,cAHW,MAAM,GAAC,iBAAiB,GACtB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,iBAAiB,GACtB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GAAC,iBAAiB,SACxB,OAAO,QAQjB;IAED;;;;OAIG;IACH,cAHW,MAAM,GAAC,iBAAiB,GACtB,OAAO,CAInB;IAGD;;;;OAIG;IACH,cAHW,aAAa,GACX,OAAO,CAYnB;IAED;;OAEG;IACH,QAFa,MAAM,CASlB;CACJ;kCA9NiC,wBAAwB"}
@@ -1,9 +1,9 @@
1
+ import { LoopOnce, LoopRepeat } from "three";
2
+ import { combine_hash } from "../../../../../core/collection/array/combine_hash.js";
1
3
  import { min2 } from "../../../../../core/math/min2.js";
4
+ import { computeHashFloat } from "../../../../../core/primitives/numbers/computeHashFloat.js";
2
5
  import { AnimationClipFlag } from "./AnimationClipFlag.js";
3
- import { LoopOnce, LoopRepeat } from "three";
4
6
  import { AnimationEventTypes } from "./AnimationEventTypes.js";
5
- import { computeHashIntegerArray } from "../../../../../core/collection/array/computeHashIntegerArray.js";
6
- import { computeHashFloat } from "../../../../../core/primitives/numbers/computeHashFloat.js";
7
7
 
8
8
  export class AnimationClip {
9
9
  constructor() {
@@ -217,7 +217,7 @@ export class AnimationClip {
217
217
  * @returns {number}
218
218
  */
219
219
  hash() {
220
- return computeHashIntegerArray(
220
+ return combine_hash(
221
221
  this.flags,
222
222
  computeHashFloat(this.weight),
223
223
  computeHashFloat(this.timeScale),
@@ -1,8 +1,8 @@
1
- import { computeStringHash } from "../../../../../core/primitives/strings/computeStringHash.js";
2
- import { invokeObjectHash } from "../../../../../core/model/object/invokeObjectHash.js";
1
+ import { combine_hash } from "../../../../../core/collection/array/combine_hash.js";
3
2
  import { computeHashArray } from "../../../../../core/collection/array/computeHashArray.js";
4
- import { computeHashIntegerArray } from "../../../../../core/collection/array/computeHashIntegerArray.js";
5
3
  import { isArrayEqual } from "../../../../../core/collection/array/isArrayEqual.js";
4
+ import { invokeObjectHash } from "../../../../../core/model/object/invokeObjectHash.js";
5
+ import { computeStringHash } from "../../../../../core/primitives/strings/computeStringHash.js";
6
6
 
7
7
  /**
8
8
  *
@@ -108,7 +108,7 @@ export class AnimationClipDefinition {
108
108
  * @returns {number}
109
109
  */
110
110
  hash() {
111
- return computeHashIntegerArray(
111
+ return combine_hash(
112
112
  computeStringHash(this.name),
113
113
  computeHashArray(this.notifications, invokeObjectHash),
114
114
  computeHashArray(this.tags, computeStringHash)
@@ -1,4 +1,4 @@
1
- import { computeHashIntegerArray } from "../../../../../core/collection/array/computeHashIntegerArray.js";
1
+ import { combine_hash } from "../../../../../core/collection/array/combine_hash.js";
2
2
  import { computeHashFloat } from "../../../../../core/primitives/numbers/computeHashFloat.js";
3
3
 
4
4
  export class AnimationNotification {
@@ -35,7 +35,7 @@ export class AnimationNotification {
35
35
  * @returns {number}
36
36
  */
37
37
  hash() {
38
- return computeHashIntegerArray(
38
+ return combine_hash(
39
39
  computeHashFloat(this.time),
40
40
  this.def.hash()
41
41
  );
@@ -1,7 +1,7 @@
1
+ import { combine_hash } from "../../../../../core/collection/array/combine_hash.js";
2
+ import { computeObjectHash } from "../../../../../core/math/hash/computeObjectHash.js";
1
3
  import { objectDeepEquals } from "../../../../../core/model/object/objectDeepEquals.js";
2
4
  import { computeStringHash } from "../../../../../core/primitives/strings/computeStringHash.js";
3
- import { computeHashIntegerArray } from "../../../../../core/collection/array/computeHashIntegerArray.js";
4
- import { computeObjectHash } from "../../../../../core/math/hash/computeObjectHash.js";
5
5
 
6
6
  export class AnimationNotificationDefinition {
7
7
  constructor() {
@@ -36,7 +36,7 @@ export class AnimationNotificationDefinition {
36
36
  * @returns {number}
37
37
  */
38
38
  hash() {
39
- return computeHashIntegerArray(
39
+ return combine_hash(
40
40
  computeStringHash(this.event),
41
41
  computeObjectHash(this.data)
42
42
  );
@@ -1,6 +1,6 @@
1
1
  import { AnimationMixer } from "three";
2
2
  import { assert } from "../../../../../../core/assert.js";
3
- import { computeHashIntegerArray } from "../../../../../../core/collection/array/computeHashIntegerArray.js";
3
+ import { combine_hash } from "../../../../../../core/collection/array/combine_hash.js";
4
4
  import { computeHashFloat } from "../../../../../../core/primitives/numbers/computeHashFloat.js";
5
5
  import { threeUpdateTransform } from "../../../../util/threeUpdateTransform.js";
6
6
  import { AnimationGraphFlag } from "./AnimationGraphFlag.js";
@@ -125,7 +125,7 @@ export class AnimationGraph {
125
125
  * @returns {number}
126
126
  */
127
127
  hash() {
128
- return computeHashIntegerArray(
128
+ return combine_hash(
129
129
  this.flags,
130
130
  computeHashFloat(this.debtTime),
131
131
  this.state.hash(),
@@ -1 +1 @@
1
- {"version":3,"file":"AnimationGraphDefinition.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/engine/graphics/ecs/animation/animator/graph/definition/AnimationGraphDefinition.js"],"names":[],"mappings":"AAUA;IAEI;;;OAGG;IACH,QAFU,wBAAwB,EAAE,CAExB;IAEZ;;;OAGG;IACH,aAFU,+BAA+B,CAExB;IAEjB;;;OAGG;IACH,cAFU,wBAAwB,CAEd;IAEpB;;;OAGG;IACH,WAFU,uBAAuB,EAAE,CAEpB;IAEf;;;;OAIG;IACH,cAHW,wBAAwB,GACtB,OAAO,CAWnB;IAED;;OAEG;IACH,QAFa,MAAM,CAQlB;IAED;;;;OAIG;IACH,6BAHW,MAAM,EAAE,GACN,wBAAwB,GAAC,SAAS,CAiC9C;IAED;;;OAGG;IACH,oBAFY,gBAAgB,CAI3B;IAED;;;;OAIG;IACH,kBAHW,uBAAuB,GACrB,MAAM,CAIlB;IAED,cAcC;IAED;;;;OAIG;IACH,8BAHoB,aAAa,+BAahC;IAED;;;OAGG;IACH,gBAFW,wBAAwB,WAYlC;IAED;;;;OAIG;IACH,qBAHW,wBAAwB,GACvB,OAAO,CAIlB;IAED;;;;OAIG;IACH,mBAHW,wBAAwB,GACtB,OAAO,CAYnB;CACJ;yCA9LwC,+BAA+B;wCAChC,kCAAkC;iCAFzC,oCAAoC;8BAGvC,wBAAwB"}
1
+ {"version":3,"file":"AnimationGraphDefinition.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/engine/graphics/ecs/animation/animator/graph/definition/AnimationGraphDefinition.js"],"names":[],"mappings":"AAUA;IAEI;;;OAGG;IACH,QAFU,wBAAwB,EAAE,CAExB;IAEZ;;;OAGG;IACH,aAFU,+BAA+B,CAExB;IAEjB;;;OAGG;IACH,cAFU,wBAAwB,CAEd;IAEpB;;;OAGG;IACH,WAFU,uBAAuB,EAAE,CAEpB;IAEf;;;;OAIG;IACH,cAHW,wBAAwB,GACtB,OAAO,CAWnB;IAED;;OAEG;IACH,QAFa,MAAM,CAQlB;IAED;;;;OAIG;IACH,6BAHW,MAAM,EAAE,GACN,wBAAwB,GAAC,SAAS,CAiC9C;IAED;;;OAGG;IACH,oBAFY,gBAAgB,CAI3B;IAED;;;;OAIG;IACH,kBAHW,uBAAuB,GACrB,MAAM,CAIlB;IAED,cAcC;IAED;;;;OAIG;IACH,8BAHoB,aAAa,+BAahC;IAED;;;OAGG;IACH,gBAFW,wBAAwB,WAYlC;IAED;;;;OAIG;IACH,qBAHW,wBAAwB,GACvB,OAAO,CAIlB;IAED;;;;OAIG;IACH,mBAHW,wBAAwB,GACtB,OAAO,CAYnB;CACJ;yCAxLwC,+BAA+B;wCAHhC,kCAAkC;iCACzC,oCAAoC;8BAFvC,wBAAwB"}