x_ite 9.4.4 → 9.5.0

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 (49) hide show
  1. package/README.md +19 -5
  2. package/dist/assets/components/Annotation.js +13 -13
  3. package/dist/assets/components/Annotation.min.js +1 -1
  4. package/dist/assets/components/CADGeometry.js +33 -17
  5. package/dist/assets/components/CADGeometry.min.js +1 -1
  6. package/dist/assets/components/CubeMapTexturing.js +25 -25
  7. package/dist/assets/components/CubeMapTexturing.min.js +1 -1
  8. package/dist/assets/components/DIS.js +13 -13
  9. package/dist/assets/components/DIS.min.js +1 -1
  10. package/dist/assets/components/EventUtilities.js +9 -9
  11. package/dist/assets/components/EventUtilities.min.js +1 -1
  12. package/dist/assets/components/Geometry2D.js +20 -20
  13. package/dist/assets/components/Geometry2D.min.js +1 -1
  14. package/dist/assets/components/Geospatial.js +45 -60
  15. package/dist/assets/components/Geospatial.min.js +1 -1
  16. package/dist/assets/components/HAnim.js +37 -34
  17. package/dist/assets/components/HAnim.min.js +1 -1
  18. package/dist/assets/components/KeyDeviceSensor.js +8 -8
  19. package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
  20. package/dist/assets/components/Layout.js +27 -27
  21. package/dist/assets/components/Layout.min.js +1 -1
  22. package/dist/assets/components/NURBS.js +23 -23
  23. package/dist/assets/components/NURBS.min.js +1 -1
  24. package/dist/assets/components/ParticleSystems.js +107 -155
  25. package/dist/assets/components/ParticleSystems.min.js +1 -1
  26. package/dist/assets/components/Picking.js +18 -18
  27. package/dist/assets/components/Picking.min.js +1 -1
  28. package/dist/assets/components/RigidBodyPhysics.js +17 -17
  29. package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
  30. package/dist/assets/components/Scripting.js +38 -38
  31. package/dist/assets/components/Scripting.min.js +1 -1
  32. package/dist/assets/components/Text.js +24 -24
  33. package/dist/assets/components/Text.min.js +1 -1
  34. package/dist/assets/components/TextureProjection.js +15 -15
  35. package/dist/assets/components/TextureProjection.min.js +1 -1
  36. package/dist/assets/components/Texturing3D.js +1956 -2567
  37. package/dist/assets/components/Texturing3D.min.js +1 -1
  38. package/dist/assets/components/VolumeRendering.js +19 -19
  39. package/dist/assets/components/VolumeRendering.min.js +1 -1
  40. package/dist/assets/components/X_ITE.js +303 -8
  41. package/dist/assets/components/X_ITE.min.js +1 -1
  42. package/dist/assets/lib/libktx.js +1 -1
  43. package/dist/x_ite.css +1 -1
  44. package/dist/x_ite.js +1264 -866
  45. package/dist/x_ite.min.js +1 -1
  46. package/dist/x_ite.min.mjs +1 -1
  47. package/dist/x_ite.mjs +1264 -866
  48. package/dist/x_ite.zip +0 -0
  49. package/package.json +6 -6
@@ -1,4 +1,4 @@
1
- /* X_ITE v9.4.4 */(() => { // webpackBootstrap
1
+ /* X_ITE v9.5.0 */(() => { // webpackBootstrap
2
2
  /******/ "use strict";
3
3
  /******/ // The require scope
4
4
  /******/ var __webpack_require__ = {};
@@ -39,25 +39,25 @@ var __webpack_exports__ = {};
39
39
  // UNUSED EXPORTS: default
40
40
 
41
41
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Components\")"
42
- const Components_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Components");
42
+ const Components_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Components");
43
43
  var Components_default = /*#__PURE__*/__webpack_require__.n(Components_namespaceObject);
44
44
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Fields\")"
45
- const Fields_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Fields");
45
+ const Fields_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Fields");
46
46
  var Fields_default = /*#__PURE__*/__webpack_require__.n(Fields_namespaceObject);
47
47
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Base/X3DFieldDefinition\")"
48
- const X3DFieldDefinition_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Base/X3DFieldDefinition");
48
+ const X3DFieldDefinition_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Base/X3DFieldDefinition");
49
49
  var X3DFieldDefinition_default = /*#__PURE__*/__webpack_require__.n(X3DFieldDefinition_namespaceObject);
50
50
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Base/FieldDefinitionArray\")"
51
- const FieldDefinitionArray_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Base/FieldDefinitionArray");
51
+ const FieldDefinitionArray_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Base/FieldDefinitionArray");
52
52
  var FieldDefinitionArray_default = /*#__PURE__*/__webpack_require__.n(FieldDefinitionArray_namespaceObject);
53
53
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Components/Shape/X3DAppearanceChildNode\")"
54
- const X3DAppearanceChildNode_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Components/Shape/X3DAppearanceChildNode");
54
+ const X3DAppearanceChildNode_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Components/Shape/X3DAppearanceChildNode");
55
55
  var X3DAppearanceChildNode_default = /*#__PURE__*/__webpack_require__.n(X3DAppearanceChildNode_namespaceObject);
56
56
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Base/X3DConstants\")"
57
- const X3DConstants_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Base/X3DConstants");
57
+ const X3DConstants_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Base/X3DConstants");
58
58
  var X3DConstants_default = /*#__PURE__*/__webpack_require__.n(X3DConstants_namespaceObject);
59
59
  ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Namespace\")"
60
- const Namespace_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.4.4")] .require ("x_ite/Namespace");
60
+ const Namespace_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Namespace");
61
61
  var Namespace_default = /*#__PURE__*/__webpack_require__.n(Namespace_namespaceObject);
62
62
  ;// CONCATENATED MODULE: ./src/x_ite/Components/X_ITE/BlendMode.js
63
63
  /*******************************************************************************
@@ -433,6 +433,299 @@ const DepthMode_default_ = DepthMode;
433
433
 
434
434
  Namespace_default().add ("DepthMode", "x_ite/Components/X_ITE/DepthMode", DepthMode_default_);
435
435
  /* harmony default export */ const X_ITE_DepthMode = (DepthMode_default_);
436
+ ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Components/Shape/X3DShapeNode\")"
437
+ const X3DShapeNode_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Components/Shape/X3DShapeNode");
438
+ var X3DShapeNode_default = /*#__PURE__*/__webpack_require__.n(X3DShapeNode_namespaceObject);
439
+ ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Rendering/TraverseType\")"
440
+ const TraverseType_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Rendering/TraverseType");
441
+ var TraverseType_default = /*#__PURE__*/__webpack_require__.n(TraverseType_namespaceObject);
442
+ ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"x_ite/Rendering/VertexArray\")"
443
+ const VertexArray_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("x_ite/Rendering/VertexArray");
444
+ var VertexArray_default = /*#__PURE__*/__webpack_require__.n(VertexArray_namespaceObject);
445
+ ;// CONCATENATED MODULE: external "window [Symbol .for (\"X_ITE.X3D\")] .require (\"standard/Math/Numbers/Matrix4\")"
446
+ const Matrix4_namespaceObject = window [Symbol .for ("X_ITE.X3D-9.5.0")] .require ("standard/Math/Numbers/Matrix4");
447
+ var Matrix4_default = /*#__PURE__*/__webpack_require__.n(Matrix4_namespaceObject);
448
+ ;// CONCATENATED MODULE: ./src/x_ite/Components/X_ITE/InstancedShape.js
449
+ /*******************************************************************************
450
+ *
451
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
452
+ *
453
+ * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
454
+ *
455
+ * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
456
+ *
457
+ * The copyright notice above does not evidence any actual of intended
458
+ * publication of such source code, and is an unpublished work by create3000.
459
+ * This material contains CONFIDENTIAL INFORMATION that is the property of
460
+ * create3000.
461
+ *
462
+ * No permission is granted to copy, distribute, or create derivative works from
463
+ * the contents of this software, in whole or in part, without the prior written
464
+ * permission of create3000.
465
+ *
466
+ * NON-MILITARY USE ONLY
467
+ *
468
+ * All create3000 software are effectively free software with a non-military use
469
+ * restriction. It is free. Well commented source is provided. You may reuse the
470
+ * source in any way you please with the exception anything that uses it must be
471
+ * marked to indicate is contains 'non-military use only' components.
472
+ *
473
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
474
+ *
475
+ * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
476
+ *
477
+ * This file is part of the X_ITE Project.
478
+ *
479
+ * X_ITE is free software: you can redistribute it and/or modify it under the
480
+ * terms of the GNU General Public License version 3 only, as published by the
481
+ * Free Software Foundation.
482
+ *
483
+ * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
484
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
485
+ * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
486
+ * details (a copy is included in the LICENSE file that accompanied this code).
487
+ *
488
+ * You should have received a copy of the GNU General Public License version 3
489
+ * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
490
+ * copy of the GPLv3 License.
491
+ *
492
+ * For Silvio, Joy and Adi.
493
+ *
494
+ ******************************************************************************/
495
+
496
+
497
+
498
+
499
+
500
+
501
+
502
+
503
+
504
+
505
+ function InstancedShape (executionContext)
506
+ {
507
+ X3DShapeNode_default().call (this, executionContext);
508
+
509
+ this .addType ((X3DConstants_default()).InstancedShape);
510
+
511
+ this .addChildObjects ((X3DConstants_default()).outputOnly, "matrices", new (Fields_default()).SFTime ());
512
+ }
513
+
514
+ Object .assign (Object .setPrototypeOf (InstancedShape .prototype, (X3DShapeNode_default()).prototype),
515
+ {
516
+ initialize ()
517
+ {
518
+ X3DShapeNode_default().prototype .initialize .call (this);
519
+
520
+ const
521
+ browser = this .getBrowser (),
522
+ gl = browser .getContext ();
523
+
524
+ // Check version.
525
+
526
+ if (browser .getContext () .getVersion () < 2)
527
+ return;
528
+
529
+ this .numInstances = 0;
530
+ this .instances = Object .assign (gl .createBuffer (), { vertexArrayObject: new (VertexArray_default()) (gl) });
531
+ this .instancesStride = Float32Array .BYTES_PER_ELEMENT * (16 + 9); // mat4 + mat3
532
+ this .matrixOffset = 0;
533
+ this .normalMatrixOffset = Float32Array .BYTES_PER_ELEMENT * 16;
534
+
535
+ this ._translations .addInterest ("set_transform__", this);
536
+ this ._rotations .addInterest ("set_transform__", this);
537
+ this ._scales .addInterest ("set_transform__", this);
538
+ this ._matrices .addInterest ("set_matrices__", this);
539
+
540
+ this .set_transform__ ();
541
+ },
542
+ getShapeKey ()
543
+ {
544
+ return 3;
545
+ },
546
+ getNumInstances ()
547
+ {
548
+ return this .numInstances;
549
+ },
550
+ getInstances ()
551
+ {
552
+ return this .instances;
553
+ },
554
+ set_bbox__ ()
555
+ { },
556
+ set_transform__ ()
557
+ {
558
+ this ._matrices = this .getBrowser () .getCurrentTime ();
559
+ },
560
+ set_matrices__ ()
561
+ {
562
+ const
563
+ browser = this .getBrowser (),
564
+ gl = browser .getContext (),
565
+ translations = this ._translations,
566
+ rotations = this ._rotations,
567
+ scales = this ._scales,
568
+ numTranslations = translations .length,
569
+ numRotations = rotations .length,
570
+ numScales = scales .length,
571
+ numInstances = Math .max (numTranslations, numRotations, numScales),
572
+ stride = this .instancesStride / Float32Array .BYTES_PER_ELEMENT,
573
+ length = this .instancesStride * numInstances,
574
+ data = new Float32Array (length),
575
+ matrix = new (Matrix4_default()) ();
576
+
577
+ this .numInstances = numInstances;
578
+
579
+ X3DShapeNode_default().prototype .set_bbox__ .call (this);
580
+
581
+ const
582
+ bbox = this .bbox .copy (),
583
+ instanceBBox = this .bbox .copy ();
584
+
585
+ this .bbox .set ();
586
+
587
+ for (let i = 0, o = 0; i < numInstances; ++ i, o += stride)
588
+ {
589
+ matrix .identity ();
590
+
591
+ if (numTranslations)
592
+ matrix .translate (translations [Math .min (i, numTranslations - 1)] .getValue ());
593
+
594
+ if (numRotations)
595
+ matrix .rotate (rotations [Math .min (i, numRotations - 1)] .getValue ());
596
+
597
+ if (numScales)
598
+ matrix .scale (scales [Math .min (i, numScales - 1)] .getValue ());
599
+
600
+ data .set (matrix, o);
601
+ data .set (matrix .submatrix .transpose () .inverse (), o + 16);
602
+
603
+ this .bbox .add (instanceBBox .assign (bbox) .multRight (matrix));
604
+ }
605
+
606
+ this .getBBoxSize () .assign (this .bbox .size);
607
+ this .getBBoxCenter () .assign (this .bbox .center);
608
+
609
+ gl .bindBuffer (gl .ARRAY_BUFFER, this .instances);
610
+ gl .bufferData (gl .ARRAY_BUFFER, data, gl .DYNAMIC_DRAW);
611
+ },
612
+ set_geometry__ ()
613
+ {
614
+ X3DShapeNode_default().prototype .set_geometry__ .call (this);
615
+
616
+ if (this .getGeometry ())
617
+ delete this .traverse;
618
+ else
619
+ this .traverse = Function .prototype;
620
+
621
+ this .set_transform__ ();
622
+ },
623
+ intersectsBox (box, clipPlanes, modelViewMatrix)
624
+ { },
625
+ traverse (type, renderObject)
626
+ {
627
+ if (!this .numInstances)
628
+ return;
629
+
630
+ // Always look at ParticleSystem if you do modify something here and there.
631
+
632
+ switch (type)
633
+ {
634
+ case (TraverseType_default()).POINTER:
635
+ {
636
+ if (this ._pointerEvents .getValue ())
637
+ renderObject .addPointingShape (this);
638
+
639
+ break;
640
+ }
641
+ case (TraverseType_default()).PICKING:
642
+ {
643
+ break;
644
+ }
645
+ case (TraverseType_default()).COLLISION:
646
+ {
647
+ renderObject .addCollisionShape (this);
648
+ break;
649
+ }
650
+ case (TraverseType_default()).SHADOW:
651
+ {
652
+ if (this ._castShadow .getValue ())
653
+ renderObject .addShadowShape (this);
654
+
655
+ break;
656
+ }
657
+ case (TraverseType_default()).DISPLAY:
658
+ {
659
+ if (renderObject .addDisplayShape (this))
660
+ {
661
+ // Currently used for GeneratedCubeMapTexture.
662
+ this .getAppearance () .traverse (type, renderObject);
663
+ }
664
+
665
+ break;
666
+ }
667
+ }
668
+
669
+ // Currently used for ScreenText and Tools.
670
+ this .getGeometry () .traverse (type, renderObject);
671
+ },
672
+ displaySimple (gl, renderContext, shaderNode)
673
+ {
674
+ this .getGeometry () .displaySimpleInstanced (gl, shaderNode, this);
675
+ },
676
+ display (gl, renderContext)
677
+ {
678
+ this .getGeometry () .displayInstanced (gl, renderContext, this);
679
+ },
680
+ });
681
+
682
+ Object .defineProperties (InstancedShape,
683
+ {
684
+ typeName:
685
+ {
686
+ value: "InstancedShape",
687
+ enumerable: true,
688
+ },
689
+ componentInfo:
690
+ {
691
+ value: Object .freeze ({ name: "X_ITE", level: 1 }),
692
+ enumerable: true,
693
+ },
694
+ containerField:
695
+ {
696
+ value: "children",
697
+ enumerable: true,
698
+ },
699
+ specificationRange:
700
+ {
701
+ value: Object .freeze ({ from: "2.0", to: "Infinity" }),
702
+ enumerable: true,
703
+ },
704
+ fieldDefinitions:
705
+ {
706
+ value: new (FieldDefinitionArray_default()) ([
707
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "metadata", new (Fields_default()).SFNode ()),
708
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "translations", new (Fields_default()).MFVec3f ()),
709
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "rotations", new (Fields_default()).MFRotation ()),
710
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "scales", new (Fields_default()).MFVec3f ()),
711
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "pointerEvents", new (Fields_default()).SFBool (true)),
712
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "castShadow", new (Fields_default()).SFBool (true)),
713
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "visible", new (Fields_default()).SFBool (true)),
714
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "bboxDisplay", new (Fields_default()).SFBool ()),
715
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).initializeOnly, "bboxSize", new (Fields_default()).SFVec3f (-1, -1, -1)),
716
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).initializeOnly, "bboxCenter", new (Fields_default()).SFVec3f ()),
717
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "appearance", new (Fields_default()).SFNode ()),
718
+ new (X3DFieldDefinition_default()) ((X3DConstants_default()).inputOutput, "geometry", new (Fields_default()).SFNode ()),
719
+ ]),
720
+ enumerable: true,
721
+ },
722
+ });
723
+
724
+ const InstancedShape_default_ = InstancedShape;
725
+ ;
726
+
727
+ Namespace_default().add ("InstancedShape", "x_ite/Components/X_ITE/InstancedShape", InstancedShape_default_);
728
+ /* harmony default export */ const X_ITE_InstancedShape = (InstancedShape_default_);
436
729
  ;// CONCATENATED MODULE: ./src/assets/components/X_ITE.js
437
730
  /*******************************************************************************
438
731
  *
@@ -485,12 +778,14 @@ Namespace_default().add ("DepthMode", "x_ite/Components/X_ITE/DepthMode", DepthM
485
778
 
486
779
 
487
780
 
781
+
488
782
  Components_default().add ({
489
783
  name: "X_ITE",
490
784
  concreteNodes:
491
785
  [
492
786
  X_ITE_BlendMode,
493
787
  X_ITE_DepthMode,
788
+ X_ITE_InstancedShape,
494
789
  ],
495
790
  abstractNodes:
496
791
  [
@@ -1 +1 @@
1
- /* X_ITE v9.4.4 */(()=>{"use strict";var t={n:e=>{var o=e&&e.__esModule?()=>e.default:()=>e;return t.d(o,{a:o}),o},d:(e,o)=>{for(var i in o)t.o(o,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:o[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e)};const e=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Components");var o=t.n(e);const i=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Fields");var s=t.n(i);const a=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Base/X3DFieldDefinition");var n=t.n(a);const r=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Base/FieldDefinitionArray");var _=t.n(r);const p=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Components/Shape/X3DAppearanceChildNode");var h=t.n(p);const c=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Base/X3DConstants");var l=t.n(c);const u=window[Symbol.for("X_ITE.X3D-9.4.4")].require("x_ite/Namespace");var T=t.n(u);function d(t){h().call(this,t),this.addType(l().BlendMode),this.factorTypes=new Map,this.equationTypes=new Map}Object.assign(Object.setPrototypeOf(d.prototype,h().prototype),{initialize(){h().prototype.initialize.call(this);const t=this.getBrowser().getContext(),e=t.getExtension("EXT_blend_minmax");this.factorTypes.set("ZERO",t.ZERO),this.factorTypes.set("ONE",t.ONE),this.factorTypes.set("SRC_COLOR",t.SRC_COLOR),this.factorTypes.set("ONE_MINUS_SRC_COLOR",t.ONE_MINUS_SRC_COLOR),this.factorTypes.set("DST_COLOR",t.DST_COLOR),this.factorTypes.set("ONE_MINUS_DST_COLOR",t.ONE_MINUS_DST_COLOR),this.factorTypes.set("SRC_ALPHA",t.SRC_ALPHA),this.factorTypes.set("ONE_MINUS_SRC_ALPHA",t.ONE_MINUS_SRC_ALPHA),this.factorTypes.set("DST_ALPHA",t.DST_ALPHA),this.factorTypes.set("ONE_MINUS_DST_ALPHA",t.ONE_MINUS_DST_ALPHA),this.factorTypes.set("SRC_ALPHA_SATURATE",t.SRC_ALPHA_SATURATE),this.factorTypes.set("CONSTANT_COLOR",t.CONSTANT_COLOR),this.factorTypes.set("ONE_MINUS_CONSTANT_COLOR",t.ONE_MINUS_CONSTANT_COLOR),this.factorTypes.set("CONSTANT_ALPHA",t.CONSTANT_ALPHA),this.factorTypes.set("ONE_MINUS_CONSTANT_ALPHA",t.ONE_MINUS_CONSTANT_ALPHA),this.equationTypes.set("FUNC_ADD",t.FUNC_ADD),this.equationTypes.set("FUNC_SUBTRACT",t.FUNC_SUBTRACT),this.equationTypes.set("FUNC_REVERSE_SUBTRACT",t.FUNC_REVERSE_SUBTRACT),this.equationTypes.set("MIN",t.MIN||e&&e.MIN_EXT),this.equationTypes.set("MAX",t.MAX||e&&e.MAX_EXT),this._sourceColorFactor.addInterest("set_sourceColorFactor__",this),this._sourceAlphaFactor.addInterest("set_sourceAlphaFactor__",this),this._destinationColorFactor.addInterest("set_destinationColorFactor__",this),this._destinationAlphaFactor.addInterest("set_destinationAlphaFactor__",this),this._colorEquation.addInterest("set_colorEquation__",this),this._alphaEquation.addInterest("set_alphaEquation__",this),this.set_sourceColorFactor__(),this.set_sourceAlphaFactor__(),this.set_destinationColorFactor__(),this.set_destinationAlphaFactor__(),this.set_colorEquation__(),this.set_alphaEquation__()},set_sourceColorFactor__(){this.sourceColorFactorType=this.factorTypes.get(this._sourceColorFactor.getValue()),void 0===this.sourceColorFactorType&&(this.sourceColorFactorType=this.factorTypes.get("SRC_ALPHA"))},set_sourceAlphaFactor__(){this.sourceAlphaFactorType=this.factorTypes.get(this._sourceAlphaFactor.getValue()),void 0===this.sourceAlphaFactorType&&(this.sourceAlphaFactorType=this.factorTypes.get("ONE"))},set_destinationColorFactor__(){this.destinationColorFactorType=this.factorTypes.get(this._destinationColorFactor.getValue()),void 0===this.destinationColorFactorType&&(this.destinationColorFactorType=this.factorTypes.get("ONE_MINUS_SRC_ALPHA"))},set_destinationAlphaFactor__(){this.destinationAlphaFactorType=this.factorTypes.get(this._destinationAlphaFactor.getValue()),void 0===this.destinationAlphaFactorType&&(this.destinationAlphaFactorType=this.factorTypes.get("ONE_MINUS_SRC_ALPHA"))},set_colorEquation__(){this.colorEquationType=this.equationTypes.get(this._colorEquation.getValue()),void 0===this.colorEquationType&&(this.colorEquationType=this.equationTypes.get("FUNC_ADD"))},set_alphaEquation__(){this.alphaEquationType=this.equationTypes.get(this._alphaEquation.getValue()),void 0===this.alphaEquationType&&(this.alphaEquationType=this.equationTypes.get("FUNC_ADD"))},enable(t){const e=this._blendColor.getValue();t.blendColor(e.r,e.g,e.b,e.a),t.blendFuncSeparate(this.sourceColorFactorType,this.destinationColorFactorType,this.sourceAlphaFactorType,this.destinationAlphaFactorType),t.blendEquationSeparate(this.colorEquationType,this.alphaEquationType)},disable(t){t.blendFuncSeparate(t.SRC_ALPHA,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA),t.blendEquationSeparate(t.FUNC_ADD,t.FUNC_ADD)}}),Object.defineProperties(d,{typeName:{value:"BlendMode",enumerable:!0},componentInfo:{value:Object.freeze({name:"X_ITE",level:1}),enumerable:!0},containerField:{value:"blendMode",enumerable:!0},specificationRange:{value:Object.freeze({from:"3.3",to:"Infinity"}),enumerable:!0},fieldDefinitions:{value:new(_())([new(n())(l().inputOutput,"metadata",new(s().SFNode)),new(n())(l().inputOutput,"blendColor",new(s().SFColorRGBA)),new(n())(l().inputOutput,"sourceColorFactor",new(s().SFString)("SRC_ALPHA")),new(n())(l().inputOutput,"sourceAlphaFactor",new(s().SFString)("ONE")),new(n())(l().inputOutput,"destinationColorFactor",new(s().SFString)("ONE_MINUS_SRC_ALPHA")),new(n())(l().inputOutput,"destinationAlphaFactor",new(s().SFString)("ONE_MINUS_SRC_ALPHA")),new(n())(l().inputOutput,"colorEquation",new(s().SFString)("FUNC_ADD")),new(n())(l().inputOutput,"alphaEquation",new(s().SFString)("FUNC_ADD"))]),enumerable:!0}});const A=d;T().add("BlendMode","x_ite/Components/X_ITE/BlendMode",A);const E=A;function S(t){h().call(this,t),this.addType(l().DepthMode)}Object.assign(Object.setPrototypeOf(S.prototype,h().prototype),{initialize(){h().prototype.initialize.call(this),this._depthFunc.addInterest("set_depthFunc__",this),this.set_depthFunc__()},set_depthFunc__:function(){const t=new Map([["NEVER","NEVER"],["LESS","LESS"],["EQUAL","EQUAL"],["LESS_EQUAL","LEQUAL"],["GREATER","GREATER"],["NOT_EQUAL","NOTEQUAL"],["GREATER_EQUAL","GEQUAL"],["ALWAYS","ALWAYS"]]);return function(){const e=this.getBrowser().getContext();this.depthFunc=e[t.get(this._depthFunc.getValue())??"LEQUAL"]}}(),enable(t){this.depthTest=t.isEnabled(t.DEPTH_TEST),this.depthWriteMask=t.getParameter(t.DEPTH_WRITEMASK),t.enable(t.POLYGON_OFFSET_FILL),t.polygonOffset(...this._polygonOffset),this._depthTest.getValue()?t.enable(t.DEPTH_TEST):t.disable(t.DEPTH_TEST),t.depthFunc(this.depthFunc),t.depthRange(...this._depthRange.getValue()),t.depthMask(this._depthMask.getValue())},disable(t){t.disable(t.POLYGON_OFFSET_FILL),this.depthTest?t.enable(t.DEPTH_TEST):t.disable(t.DEPTH_TEST),t.depthFunc(t.LEQUAL),t.depthRange(0,1),t.depthMask(this.depthWriteMask)}}),Object.defineProperties(S,{typeName:{value:"DepthMode",enumerable:!0},componentInfo:{value:Object.freeze({name:"X_ITE",level:1}),enumerable:!0},containerField:{value:"depthMode",enumerable:!0},specificationRange:{value:Object.freeze({from:"4.0",to:"Infinity"}),enumerable:!0},fieldDefinitions:{value:new(_())([new(n())(l().inputOutput,"metadata",new(s().SFNode)),new(n())(l().inputOutput,"polygonOffset",new(s().SFVec2f)),new(n())(l().inputOutput,"depthRange",new(s().SFVec2f)(0,1)),new(n())(l().inputOutput,"depthTest",new(s().SFBool)(!0)),new(n())(l().inputOutput,"depthFunc",new(s().SFString)("LESS_EQUAL")),new(n())(l().inputOutput,"depthMask",new(s().SFBool)(!0))]),enumerable:!0}});const O=S;T().add("DepthMode","x_ite/Components/X_ITE/DepthMode",O);const F=O;o().add({name:"X_ITE",concreteNodes:[E,F],abstractNodes:[]});const C=void 0;T().add("X_ITE","assets/components/X_ITE",C)})();
1
+ /* X_ITE v9.5.0 */(()=>{"use strict";var t={n:e=>{var s=e&&e.__esModule?()=>e.default:()=>e;return t.d(s,{a:s}),s},d:(e,s)=>{for(var i in s)t.o(s,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:s[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e)};const e=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Components");var s=t.n(e);const i=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Fields");var n=t.n(i);const o=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Base/X3DFieldDefinition");var a=t.n(o);const r=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Base/FieldDefinitionArray");var _=t.n(r);const p=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Components/Shape/X3DAppearanceChildNode");var h=t.n(p);const l=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Base/X3DConstants");var c=t.n(l);const u=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Namespace");var d=t.n(u);function T(t){h().call(this,t),this.addType(c().BlendMode),this.factorTypes=new Map,this.equationTypes=new Map}Object.assign(Object.setPrototypeOf(T.prototype,h().prototype),{initialize(){h().prototype.initialize.call(this);const t=this.getBrowser().getContext(),e=t.getExtension("EXT_blend_minmax");this.factorTypes.set("ZERO",t.ZERO),this.factorTypes.set("ONE",t.ONE),this.factorTypes.set("SRC_COLOR",t.SRC_COLOR),this.factorTypes.set("ONE_MINUS_SRC_COLOR",t.ONE_MINUS_SRC_COLOR),this.factorTypes.set("DST_COLOR",t.DST_COLOR),this.factorTypes.set("ONE_MINUS_DST_COLOR",t.ONE_MINUS_DST_COLOR),this.factorTypes.set("SRC_ALPHA",t.SRC_ALPHA),this.factorTypes.set("ONE_MINUS_SRC_ALPHA",t.ONE_MINUS_SRC_ALPHA),this.factorTypes.set("DST_ALPHA",t.DST_ALPHA),this.factorTypes.set("ONE_MINUS_DST_ALPHA",t.ONE_MINUS_DST_ALPHA),this.factorTypes.set("SRC_ALPHA_SATURATE",t.SRC_ALPHA_SATURATE),this.factorTypes.set("CONSTANT_COLOR",t.CONSTANT_COLOR),this.factorTypes.set("ONE_MINUS_CONSTANT_COLOR",t.ONE_MINUS_CONSTANT_COLOR),this.factorTypes.set("CONSTANT_ALPHA",t.CONSTANT_ALPHA),this.factorTypes.set("ONE_MINUS_CONSTANT_ALPHA",t.ONE_MINUS_CONSTANT_ALPHA),this.equationTypes.set("FUNC_ADD",t.FUNC_ADD),this.equationTypes.set("FUNC_SUBTRACT",t.FUNC_SUBTRACT),this.equationTypes.set("FUNC_REVERSE_SUBTRACT",t.FUNC_REVERSE_SUBTRACT),this.equationTypes.set("MIN",t.MIN||e&&e.MIN_EXT),this.equationTypes.set("MAX",t.MAX||e&&e.MAX_EXT),this._sourceColorFactor.addInterest("set_sourceColorFactor__",this),this._sourceAlphaFactor.addInterest("set_sourceAlphaFactor__",this),this._destinationColorFactor.addInterest("set_destinationColorFactor__",this),this._destinationAlphaFactor.addInterest("set_destinationAlphaFactor__",this),this._colorEquation.addInterest("set_colorEquation__",this),this._alphaEquation.addInterest("set_alphaEquation__",this),this.set_sourceColorFactor__(),this.set_sourceAlphaFactor__(),this.set_destinationColorFactor__(),this.set_destinationAlphaFactor__(),this.set_colorEquation__(),this.set_alphaEquation__()},set_sourceColorFactor__(){this.sourceColorFactorType=this.factorTypes.get(this._sourceColorFactor.getValue()),void 0===this.sourceColorFactorType&&(this.sourceColorFactorType=this.factorTypes.get("SRC_ALPHA"))},set_sourceAlphaFactor__(){this.sourceAlphaFactorType=this.factorTypes.get(this._sourceAlphaFactor.getValue()),void 0===this.sourceAlphaFactorType&&(this.sourceAlphaFactorType=this.factorTypes.get("ONE"))},set_destinationColorFactor__(){this.destinationColorFactorType=this.factorTypes.get(this._destinationColorFactor.getValue()),void 0===this.destinationColorFactorType&&(this.destinationColorFactorType=this.factorTypes.get("ONE_MINUS_SRC_ALPHA"))},set_destinationAlphaFactor__(){this.destinationAlphaFactorType=this.factorTypes.get(this._destinationAlphaFactor.getValue()),void 0===this.destinationAlphaFactorType&&(this.destinationAlphaFactorType=this.factorTypes.get("ONE_MINUS_SRC_ALPHA"))},set_colorEquation__(){this.colorEquationType=this.equationTypes.get(this._colorEquation.getValue()),void 0===this.colorEquationType&&(this.colorEquationType=this.equationTypes.get("FUNC_ADD"))},set_alphaEquation__(){this.alphaEquationType=this.equationTypes.get(this._alphaEquation.getValue()),void 0===this.alphaEquationType&&(this.alphaEquationType=this.equationTypes.get("FUNC_ADD"))},enable(t){const e=this._blendColor.getValue();t.blendColor(e.r,e.g,e.b,e.a),t.blendFuncSeparate(this.sourceColorFactorType,this.destinationColorFactorType,this.sourceAlphaFactorType,this.destinationAlphaFactorType),t.blendEquationSeparate(this.colorEquationType,this.alphaEquationType)},disable(t){t.blendFuncSeparate(t.SRC_ALPHA,t.ONE_MINUS_SRC_ALPHA,t.ONE,t.ONE_MINUS_SRC_ALPHA),t.blendEquationSeparate(t.FUNC_ADD,t.FUNC_ADD)}}),Object.defineProperties(T,{typeName:{value:"BlendMode",enumerable:!0},componentInfo:{value:Object.freeze({name:"X_ITE",level:1}),enumerable:!0},containerField:{value:"blendMode",enumerable:!0},specificationRange:{value:Object.freeze({from:"3.3",to:"Infinity"}),enumerable:!0},fieldDefinitions:{value:new(_())([new(a())(c().inputOutput,"metadata",new(n().SFNode)),new(a())(c().inputOutput,"blendColor",new(n().SFColorRGBA)),new(a())(c().inputOutput,"sourceColorFactor",new(n().SFString)("SRC_ALPHA")),new(a())(c().inputOutput,"sourceAlphaFactor",new(n().SFString)("ONE")),new(a())(c().inputOutput,"destinationColorFactor",new(n().SFString)("ONE_MINUS_SRC_ALPHA")),new(a())(c().inputOutput,"destinationAlphaFactor",new(n().SFString)("ONE_MINUS_SRC_ALPHA")),new(a())(c().inputOutput,"colorEquation",new(n().SFString)("FUNC_ADD")),new(a())(c().inputOutput,"alphaEquation",new(n().SFString)("FUNC_ADD"))]),enumerable:!0}});const S=T;d().add("BlendMode","x_ite/Components/X_ITE/BlendMode",S);const E=S;function A(t){h().call(this,t),this.addType(c().DepthMode)}Object.assign(Object.setPrototypeOf(A.prototype,h().prototype),{initialize(){h().prototype.initialize.call(this),this._depthFunc.addInterest("set_depthFunc__",this),this.set_depthFunc__()},set_depthFunc__:function(){const t=new Map([["NEVER","NEVER"],["LESS","LESS"],["EQUAL","EQUAL"],["LESS_EQUAL","LEQUAL"],["GREATER","GREATER"],["NOT_EQUAL","NOTEQUAL"],["GREATER_EQUAL","GEQUAL"],["ALWAYS","ALWAYS"]]);return function(){const e=this.getBrowser().getContext();this.depthFunc=e[t.get(this._depthFunc.getValue())??"LEQUAL"]}}(),enable(t){this.depthTest=t.isEnabled(t.DEPTH_TEST),this.depthWriteMask=t.getParameter(t.DEPTH_WRITEMASK),t.enable(t.POLYGON_OFFSET_FILL),t.polygonOffset(...this._polygonOffset),this._depthTest.getValue()?t.enable(t.DEPTH_TEST):t.disable(t.DEPTH_TEST),t.depthFunc(this.depthFunc),t.depthRange(...this._depthRange.getValue()),t.depthMask(this._depthMask.getValue())},disable(t){t.disable(t.POLYGON_OFFSET_FILL),this.depthTest?t.enable(t.DEPTH_TEST):t.disable(t.DEPTH_TEST),t.depthFunc(t.LEQUAL),t.depthRange(0,1),t.depthMask(this.depthWriteMask)}}),Object.defineProperties(A,{typeName:{value:"DepthMode",enumerable:!0},componentInfo:{value:Object.freeze({name:"X_ITE",level:1}),enumerable:!0},containerField:{value:"depthMode",enumerable:!0},specificationRange:{value:Object.freeze({from:"4.0",to:"Infinity"}),enumerable:!0},fieldDefinitions:{value:new(_())([new(a())(c().inputOutput,"metadata",new(n().SFNode)),new(a())(c().inputOutput,"polygonOffset",new(n().SFVec2f)),new(a())(c().inputOutput,"depthRange",new(n().SFVec2f)(0,1)),new(a())(c().inputOutput,"depthTest",new(n().SFBool)(!0)),new(a())(c().inputOutput,"depthFunc",new(n().SFString)("LESS_EQUAL")),new(a())(c().inputOutput,"depthMask",new(n().SFBool)(!0))]),enumerable:!0}});const y=A;d().add("DepthMode","x_ite/Components/X_ITE/DepthMode",y);const O=y,F=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Components/Shape/X3DShapeNode");var f=t.n(F);const b=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Rendering/TraverseType");var C=t.n(b);const N=window[Symbol.for("X_ITE.X3D-9.5.0")].require("x_ite/Rendering/VertexArray");var w=t.n(N);const m=window[Symbol.for("X_ITE.X3D-9.5.0")].require("standard/Math/Numbers/Matrix4");var g=t.n(m);function I(t){f().call(this,t),this.addType(c().InstancedShape),this.addChildObjects(c().outputOnly,"matrices",new(n().SFTime))}Object.assign(Object.setPrototypeOf(I.prototype,f().prototype),{initialize(){f().prototype.initialize.call(this);const t=this.getBrowser(),e=t.getContext();t.getContext().getVersion()<2||(this.numInstances=0,this.instances=Object.assign(e.createBuffer(),{vertexArrayObject:new(w())(e)}),this.instancesStride=25*Float32Array.BYTES_PER_ELEMENT,this.matrixOffset=0,this.normalMatrixOffset=16*Float32Array.BYTES_PER_ELEMENT,this._translations.addInterest("set_transform__",this),this._rotations.addInterest("set_transform__",this),this._scales.addInterest("set_transform__",this),this._matrices.addInterest("set_matrices__",this),this.set_transform__())},getShapeKey:()=>3,getNumInstances(){return this.numInstances},getInstances(){return this.instances},set_bbox__(){},set_transform__(){this._matrices=this.getBrowser().getCurrentTime()},set_matrices__(){const t=this.getBrowser().getContext(),e=this._translations,s=this._rotations,i=this._scales,n=e.length,o=s.length,a=i.length,r=Math.max(n,o,a),_=this.instancesStride/Float32Array.BYTES_PER_ELEMENT,p=this.instancesStride*r,h=new Float32Array(p),l=new(g());this.numInstances=r,f().prototype.set_bbox__.call(this);const c=this.bbox.copy(),u=this.bbox.copy();this.bbox.set();for(let t=0,p=0;t<r;++t,p+=_)l.identity(),n&&l.translate(e[Math.min(t,n-1)].getValue()),o&&l.rotate(s[Math.min(t,o-1)].getValue()),a&&l.scale(i[Math.min(t,a-1)].getValue()),h.set(l,p),h.set(l.submatrix.transpose().inverse(),p+16),this.bbox.add(u.assign(c).multRight(l));this.getBBoxSize().assign(this.bbox.size),this.getBBoxCenter().assign(this.bbox.center),t.bindBuffer(t.ARRAY_BUFFER,this.instances),t.bufferData(t.ARRAY_BUFFER,h,t.DYNAMIC_DRAW)},set_geometry__(){f().prototype.set_geometry__.call(this),this.getGeometry()?delete this.traverse:this.traverse=Function.prototype,this.set_transform__()},intersectsBox(t,e,s){},traverse(t,e){if(this.numInstances){switch(t){case C().POINTER:this._pointerEvents.getValue()&&e.addPointingShape(this);break;case C().PICKING:break;case C().COLLISION:e.addCollisionShape(this);break;case C().SHADOW:this._castShadow.getValue()&&e.addShadowShape(this);break;case C().DISPLAY:e.addDisplayShape(this)&&this.getAppearance().traverse(t,e)}this.getGeometry().traverse(t,e)}},displaySimple(t,e,s){this.getGeometry().displaySimpleInstanced(t,s,this)},display(t,e){this.getGeometry().displayInstanced(t,e,this)}}),Object.defineProperties(I,{typeName:{value:"InstancedShape",enumerable:!0},componentInfo:{value:Object.freeze({name:"X_ITE",level:1}),enumerable:!0},containerField:{value:"children",enumerable:!0},specificationRange:{value:Object.freeze({from:"2.0",to:"Infinity"}),enumerable:!0},fieldDefinitions:{value:new(_())([new(a())(c().inputOutput,"metadata",new(n().SFNode)),new(a())(c().inputOutput,"translations",new(n().MFVec3f)),new(a())(c().inputOutput,"rotations",new(n().MFRotation)),new(a())(c().inputOutput,"scales",new(n().MFVec3f)),new(a())(c().inputOutput,"pointerEvents",new(n().SFBool)(!0)),new(a())(c().inputOutput,"castShadow",new(n().SFBool)(!0)),new(a())(c().inputOutput,"visible",new(n().SFBool)(!0)),new(a())(c().inputOutput,"bboxDisplay",new(n().SFBool)),new(a())(c().initializeOnly,"bboxSize",new(n().SFVec3f)(-1,-1,-1)),new(a())(c().initializeOnly,"bboxCenter",new(n().SFVec3f)),new(a())(c().inputOutput,"appearance",new(n().SFNode)),new(a())(c().inputOutput,"geometry",new(n().SFNode))]),enumerable:!0}});const R=I;d().add("InstancedShape","x_ite/Components/X_ITE/InstancedShape",R);const L=R;s().add({name:"X_ITE",concreteNodes:[E,O,L],abstractNodes:[]});const D=void 0;d().add("X_ITE","assets/components/X_ITE",D)})();