x_ite 5.0.3 → 6.1.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 (385) hide show
  1. package/.vscode/settings.json +12 -5
  2. package/.vscode/tasks.json +25 -1
  3. package/Makefile +36 -28
  4. package/README.md +6 -11
  5. package/build/bin/dist.pl +0 -6
  6. package/build/bin/examples-and-tests.pl +75 -0
  7. package/build/bin/tests-menu.pl +57 -0
  8. package/build/bin/version.pl +7 -4
  9. package/build/parts/default.start.frag.js +3 -2
  10. package/dist/assets/components/annotation.js +3 -2
  11. package/dist/assets/components/annotation.min.js +1 -1
  12. package/dist/assets/components/cad-geometry.js +3 -2
  13. package/dist/assets/components/cad-geometry.min.js +1 -1
  14. package/dist/assets/components/cube-map-texturing.js +8 -20
  15. package/dist/assets/components/cube-map-texturing.min.js +1 -1
  16. package/dist/assets/components/dis.js +3 -2
  17. package/dist/assets/components/dis.min.js +1 -1
  18. package/dist/assets/components/event-utilities.js +4 -3
  19. package/dist/assets/components/event-utilities.min.js +1 -1
  20. package/dist/assets/components/geometry2d.js +38 -52
  21. package/dist/assets/components/geometry2d.min.js +1 -1
  22. package/dist/assets/components/geospatial.js +34 -1686
  23. package/dist/assets/components/geospatial.min.js +1 -1
  24. package/dist/assets/components/h-anim.js +71 -77
  25. package/dist/assets/components/h-anim.min.js +1 -1
  26. package/dist/assets/components/key-device-sensor.js +4 -3
  27. package/dist/assets/components/key-device-sensor.min.js +1 -1
  28. package/dist/assets/components/layout.js +101 -173
  29. package/dist/assets/components/layout.min.js +1 -1
  30. package/dist/assets/components/nurbs.js +3 -2
  31. package/dist/assets/components/nurbs.min.js +1 -1
  32. package/dist/assets/components/particle-systems.js +1926 -1669
  33. package/dist/assets/components/particle-systems.min.js +1 -1
  34. package/dist/assets/components/picking.js +34 -41
  35. package/dist/assets/components/picking.min.js +1 -1
  36. package/dist/assets/components/projective-texture-mapping.js +73 -86
  37. package/dist/assets/components/projective-texture-mapping.min.js +1 -1
  38. package/dist/assets/components/rigid-body-physics.js +37 -57
  39. package/dist/assets/components/rigid-body-physics.min.js +1 -1
  40. package/dist/assets/components/scripting.js +3 -2
  41. package/dist/assets/components/scripting.min.js +1 -1
  42. package/dist/assets/components/texturing-3d.js +27 -33
  43. package/dist/assets/components/texturing-3d.min.js +3 -3
  44. package/dist/assets/components/volume-rendering.js +12 -11
  45. package/dist/assets/components/volume-rendering.min.js +1 -1
  46. package/dist/assets/components/x_ite.js +3 -2
  47. package/dist/assets/components/x_ite.min.js +1 -1
  48. package/dist/assets/images/Shading.png +0 -0
  49. package/dist/assets/linetype/1.png +0 -0
  50. package/dist/assets/linetype/10.png +0 -0
  51. package/dist/assets/linetype/11.png +0 -0
  52. package/dist/assets/linetype/12.png +0 -0
  53. package/dist/assets/linetype/13.png +0 -0
  54. package/dist/assets/linetype/14.png +0 -0
  55. package/dist/assets/linetype/15.png +0 -0
  56. package/dist/assets/linetype/16.png +0 -0
  57. package/dist/assets/linetype/2.png +0 -0
  58. package/dist/assets/linetype/3.png +0 -0
  59. package/dist/assets/linetype/4.png +0 -0
  60. package/dist/assets/linetype/5.png +0 -0
  61. package/dist/assets/linetype/6.png +0 -0
  62. package/dist/assets/linetype/7.png +0 -0
  63. package/dist/assets/linetype/8.png +0 -0
  64. package/dist/assets/linetype/9.png +0 -0
  65. package/dist/assets/shaders/webgl1/Gouraud.vs +1 -1
  66. package/dist/assets/shaders/webgl1/Line.fs +0 -21
  67. package/dist/assets/shaders/webgl1/Line.vs +0 -10
  68. package/dist/assets/shaders/webgl1/PBR.fs +1 -1
  69. package/dist/assets/shaders/webgl1/PBR.vs +1 -1
  70. package/dist/assets/shaders/webgl1/Phong.fs +1 -1
  71. package/dist/assets/shaders/webgl1/Point.vs +1 -1
  72. package/dist/assets/shaders/webgl2/Depth.vs +29 -1
  73. package/dist/assets/shaders/webgl2/Gouraud.vs +32 -4
  74. package/dist/assets/shaders/webgl2/Line.fs +24 -12
  75. package/dist/assets/shaders/webgl2/Line.vs +36 -11
  76. package/dist/assets/shaders/webgl2/LineTransform.fs +4 -0
  77. package/dist/assets/shaders/webgl2/LineTransform.vs +57 -0
  78. package/dist/assets/shaders/webgl2/PBR.fs +1 -1
  79. package/dist/assets/shaders/webgl2/PBR.vs +35 -7
  80. package/dist/assets/shaders/webgl2/Phong.fs +1 -1
  81. package/dist/assets/shaders/webgl2/Phong.vs +31 -3
  82. package/dist/assets/shaders/webgl2/Point.vs +30 -2
  83. package/dist/assets/shaders/webgl2/Unlit.vs +31 -3
  84. package/dist/example.html +6 -6
  85. package/dist/x_ite.css +199 -224
  86. package/dist/x_ite.js +16335 -15917
  87. package/dist/x_ite.min.js +17 -17
  88. package/dist/x_ite.zip +0 -0
  89. package/docs/404.md +6 -0
  90. package/docs/Accessing-the-External-Browser.md +21 -15
  91. package/docs/Browser-Support.md +6 -0
  92. package/docs/Custom-Shaders.md +18 -25
  93. package/docs/Features.md +11 -5
  94. package/docs/Gemfile +44 -0
  95. package/docs/Gemfile.lock +122 -0
  96. package/docs/Glossary.md +6 -0
  97. package/docs/How-To-Configure-Your-Web-Server.md +6 -0
  98. package/docs/Supported-Nodes.md +9 -1
  99. package/docs/What's-New.md +93 -39
  100. package/docs/XHTML-DOM-Integration.md +6 -0
  101. package/docs/_config.yml +2 -2
  102. package/docs/assets/css/main.scss +26 -0
  103. package/docs/index.md +42 -50
  104. package/docs/reference/Browser-Services.md +9 -3
  105. package/docs/reference/Constants-Services.md +6 -0
  106. package/docs/reference/ECMAScript-Object-and-Function-Definitions.md +12 -6
  107. package/docs/reference/Field-Services-and-Objects.md +105 -1
  108. package/docs/reference/Prototype-Services.md +11 -0
  109. package/docs/reference/Route-Services.md +9 -0
  110. package/docs/reference/Scene-Services.md +17 -2
  111. package/docs/reference/Script-Node-Authoring-Interface.md +7 -1
  112. package/docs/tutorials/Adding-backgrounds.md +6 -0
  113. package/docs/tutorials/Adding-fog.md +6 -0
  114. package/docs/tutorials/Adding-sound.md +6 -0
  115. package/docs/tutorials/Animating-transforms.md +6 -0
  116. package/docs/tutorials/Basic-Nodes.md +6 -0
  117. package/docs/tutorials/Building-a-X3D-world.md +6 -0
  118. package/docs/tutorials/Building-elevation-grids.md +6 -0
  119. package/docs/tutorials/Building-extruded-shapes.md +6 -0
  120. package/docs/tutorials/Building-primitive-shapes.md +6 -0
  121. package/docs/tutorials/Building-shapes-out-of-points,-lines,-and-faces.md +6 -0
  122. package/docs/tutorials/Controlling-appearance-with-materials.md +6 -0
  123. package/docs/tutorials/Controlling-color-on-coordinate-based-geometry.md +6 -0
  124. package/docs/tutorials/Controlling-detail.md +6 -0
  125. package/docs/tutorials/Controlling-how-textures-are-mapped.md +6 -0
  126. package/docs/tutorials/Controlling-navigation.md +6 -0
  127. package/docs/tutorials/Controlling-shading-on-coordinate-based-geometry.md +6 -0
  128. package/docs/tutorials/Controlling-the-viewpoint.md +6 -0
  129. package/docs/tutorials/Creating-new-node-types.md +6 -0
  130. package/docs/tutorials/Grouping-nodes.md +6 -0
  131. package/docs/tutorials/Hello,-World!.md +6 -0
  132. package/docs/tutorials/Improving-Performance.md +6 -0
  133. package/docs/tutorials/Increasing-Rendering-Speed.md +6 -0
  134. package/docs/tutorials/Introducing-X3D.md +6 -0
  135. package/docs/tutorials/Introducing-animation.md +6 -0
  136. package/docs/tutorials/Introducing-script-use.md +6 -0
  137. package/docs/tutorials/Lighting-your-world.md +6 -0
  138. package/docs/tutorials/Mapping-textures.md +6 -0
  139. package/docs/tutorials/Naming-nodes.md +6 -0
  140. package/docs/tutorials/Providing-information-about-your-world.md +6 -0
  141. package/docs/tutorials/Sensing-the-viewer.md +6 -0
  142. package/docs/tutorials/Sensing-viewer-actions.md +6 -0
  143. package/docs/tutorials/Transforming-Shapes.md +6 -0
  144. package/docs/tutorials/Writing-program-scripts-with-ECMAScript.md +6 -0
  145. package/docs/tutorials/index.md +42 -36
  146. package/package.json +6 -7
  147. package/src/assets/components/geometry2d.js +1 -1
  148. package/src/assets/components/key-device-sensor.js +1 -1
  149. package/src/assets/components/layout.js +1 -1
  150. package/src/assets/components/particle-systems.js +1 -1
  151. package/src/assets/components/volume-rendering.js +1 -1
  152. package/src/assets/images/Shading.png +0 -0
  153. package/src/assets/linetype/1.png +0 -0
  154. package/src/assets/linetype/10.png +0 -0
  155. package/src/assets/linetype/11.png +0 -0
  156. package/src/assets/linetype/12.png +0 -0
  157. package/src/assets/linetype/13.png +0 -0
  158. package/src/assets/linetype/14.png +0 -0
  159. package/src/assets/linetype/15.png +0 -0
  160. package/src/assets/linetype/16.png +0 -0
  161. package/src/assets/linetype/2.png +0 -0
  162. package/src/assets/linetype/3.png +0 -0
  163. package/src/assets/linetype/4.png +0 -0
  164. package/src/assets/linetype/5.png +0 -0
  165. package/src/assets/linetype/6.png +0 -0
  166. package/src/assets/linetype/7.png +0 -0
  167. package/src/assets/linetype/8.png +0 -0
  168. package/src/assets/linetype/9.png +0 -0
  169. package/src/assets/shaders/Types.glsl +1 -9
  170. package/src/assets/shaders/webgl1/Gouraud.fs +1 -1
  171. package/src/assets/shaders/webgl1/Gouraud.vs +2 -3
  172. package/src/assets/shaders/webgl1/Line.fs +3 -28
  173. package/src/assets/shaders/webgl1/Line.vs +6 -20
  174. package/src/assets/shaders/webgl1/PBR.fs +6 -6
  175. package/src/assets/shaders/webgl1/PBR.vs +1 -1
  176. package/src/assets/shaders/webgl1/Phong.fs +10 -10
  177. package/src/assets/shaders/webgl1/Point.vs +2 -2
  178. package/src/assets/shaders/webgl1/Unlit.fs +4 -4
  179. package/src/assets/shaders/webgl1/include/Normal.glsl +1 -1
  180. package/src/assets/shaders/webgl1/include/Texture.glsl +3 -8
  181. package/src/assets/shaders/webgl2/Depth.vs +4 -1
  182. package/src/assets/shaders/webgl2/Gouraud.fs +1 -1
  183. package/src/assets/shaders/webgl2/Gouraud.vs +8 -6
  184. package/src/assets/shaders/webgl2/Line.fs +11 -17
  185. package/src/assets/shaders/webgl2/Line.vs +17 -21
  186. package/src/assets/shaders/webgl2/LineTransform.fs +6 -0
  187. package/src/assets/shaders/webgl2/LineTransform.vs +77 -0
  188. package/src/assets/shaders/webgl2/PBR.fs +6 -6
  189. package/src/assets/shaders/webgl2/PBR.vs +10 -7
  190. package/src/assets/shaders/webgl2/Phong.fs +11 -11
  191. package/src/assets/shaders/webgl2/Phong.vs +6 -3
  192. package/src/assets/shaders/webgl2/Point.vs +5 -4
  193. package/src/assets/shaders/webgl2/Unlit.fs +5 -5
  194. package/src/assets/shaders/webgl2/Unlit.vs +6 -3
  195. package/src/assets/shaders/webgl2/include/Line2.glsl +20 -0
  196. package/src/assets/shaders/webgl2/include/Normal.glsl +1 -1
  197. package/src/assets/shaders/webgl2/include/Particle.glsl +36 -0
  198. package/src/assets/shaders/webgl2/include/Texture.glsl +3 -3
  199. package/src/example.html +6 -6
  200. package/src/examples.js +5 -4
  201. package/src/standard/Math/Algorithm.js +12 -28
  202. package/src/standard/Math/Geometry/Line2.js +163 -0
  203. package/src/standard/Math/Geometry/Line3.js +3 -5
  204. package/src/standard/Math/Geometry/Plane3.js +0 -2
  205. package/src/standard/Math/Geometry/Triangle3.js +1 -1
  206. package/src/standard/Math/Geometry/ViewVolume.js +121 -103
  207. package/src/standard/Math/Numbers/Color3.js +6 -0
  208. package/src/standard/Math/Numbers/Color4.js +7 -0
  209. package/src/standard/Math/Numbers/Complex.js +48 -34
  210. package/src/standard/Math/Numbers/Matrix2.js +62 -2
  211. package/src/standard/Math/Numbers/Matrix3.js +129 -110
  212. package/src/standard/Math/Numbers/Matrix4.js +138 -119
  213. package/src/standard/Math/Numbers/Quaternion.js +12 -5
  214. package/src/standard/Math/Numbers/Rotation4.js +8 -1
  215. package/src/standard/Math/Numbers/Vector2.js +42 -9
  216. package/src/standard/Math/Numbers/Vector3.js +50 -14
  217. package/src/standard/Math/Numbers/Vector4.js +48 -11
  218. package/src/standard/Math/Utility/BVH.js +45 -17
  219. package/src/tests.js +68 -66
  220. package/src/x_ite/Base/X3DBaseNode.js +22 -11
  221. package/src/x_ite/Base/X3DField.js +1 -1
  222. package/src/x_ite/Browser/Core/BrowserOptions.js +24 -143
  223. package/src/x_ite/Browser/Core/BrowserTimings.js +6 -4
  224. package/src/x_ite/Browser/Core/Context.js +185 -0
  225. package/src/x_ite/Browser/Core/ContextMenu.js +398 -211
  226. package/src/x_ite/Browser/Core/Notification.js +1 -0
  227. package/src/x_ite/Browser/Core/X3DCoreContext.js +35 -146
  228. package/src/x_ite/Browser/Followers/X3DArrayFollowerTemplate.js +1 -1
  229. package/src/x_ite/Browser/Geometry2D/Disk2DOptions.js +1 -0
  230. package/src/x_ite/Browser/Geometry2D/X3DGeometry2DContext.js +2 -2
  231. package/src/x_ite/Browser/Geometry3D/X3DGeometry3DContext.js +41 -2
  232. package/src/x_ite/Browser/Geospatial/Geocentric.js +2 -2
  233. package/src/x_ite/Browser/Interpolation/CatmullRomSplineInterpolatorTemplate.js +1 -1
  234. package/src/x_ite/Browser/Layout/ScreenText.js +18 -65
  235. package/src/x_ite/Browser/Layout/X3DLayoutContext.js +59 -16
  236. package/src/x_ite/Browser/Navigation/ExamineViewer.js +13 -20
  237. package/src/x_ite/Browser/Navigation/LookAtViewer.js +1 -4
  238. package/src/x_ite/Browser/Navigation/PlaneViewer.js +0 -3
  239. package/src/x_ite/Browser/Navigation/X3DFlyViewer.js +15 -8
  240. package/src/x_ite/Browser/Navigation/X3DViewer.js +12 -20
  241. package/src/x_ite/Browser/Networking/X3DNetworkingContext.js +11 -7
  242. package/src/x_ite/Browser/ParticleSystems/BVH.glsl +183 -0
  243. package/src/x_ite/Browser/ParticleSystems/Box3.glsl +47 -0
  244. package/src/x_ite/Browser/ParticleSystems/GeometryTypes.js +66 -0
  245. package/src/x_ite/Browser/ParticleSystems/Line3.glsl +55 -0
  246. package/src/x_ite/Browser/ParticleSystems/Plane3.glsl +160 -0
  247. package/src/x_ite/Browser/PointingDeviceSensor/PointingDevice.js +27 -3
  248. package/src/x_ite/Browser/PointingDeviceSensor/X3DPointingDeviceSensorContext.js +41 -37
  249. package/src/x_ite/Browser/Rendering/X3DRenderingContext.js +21 -13
  250. package/src/x_ite/Browser/Shaders/Shader.js +33 -12
  251. package/src/x_ite/Browser/Shaders/ShaderSource.js +6 -0
  252. package/src/x_ite/Browser/Shaders/ShaderTest.js +16 -10
  253. package/src/x_ite/Browser/Shape/X3DShapeContext.js +50 -9
  254. package/src/x_ite/Browser/Text/X3DTextContext.js +4 -13
  255. package/src/x_ite/Browser/Text/X3DTextGeometry.js +2 -1
  256. package/src/x_ite/Browser/Texturing/X3DTexturingContext.js +71 -34
  257. package/src/x_ite/Browser/Texturing3D/DICOMParser.js +2 -2
  258. package/src/x_ite/Browser/Time/X3DTimeContext.js +4 -2
  259. package/src/x_ite/Browser/VERSION.js +1 -1
  260. package/src/x_ite/Browser/X3DBrowser.js +7 -6
  261. package/src/x_ite/Browser/X3DBrowserContext.js +43 -10
  262. package/src/x_ite/Components/Core/X3DNode.js +4 -0
  263. package/src/x_ite/Components/Core/X3DPrototypeInstance.js +0 -2
  264. package/src/x_ite/Components/CubeMapTexturing/ComposedCubeMapTexture.js +3 -4
  265. package/src/x_ite/Components/CubeMapTexturing/GeneratedCubeMapTexture.js +1 -12
  266. package/src/x_ite/Components/CubeMapTexturing/ImageCubeMapTexture.js +1 -2
  267. package/src/x_ite/Components/EnvironmentalEffects/TextureBackground.js +1 -1
  268. package/src/x_ite/Components/EnvironmentalEffects/X3DBackgroundNode.js +76 -77
  269. package/src/x_ite/Components/EnvironmentalEffects/X3DFogObject.js +2 -9
  270. package/src/x_ite/Components/EnvironmentalSensor/ProximitySensor.js +51 -65
  271. package/src/x_ite/Components/EventUtilities/X3DSequencerNode.js +1 -1
  272. package/src/x_ite/Components/Followers/ColorDamper.js +1 -1
  273. package/src/x_ite/Components/Followers/X3DChaserNode.js +18 -32
  274. package/src/x_ite/Components/Followers/X3DDamperNode.js +1 -6
  275. package/src/x_ite/Components/Followers/X3DFollowerNode.js +1 -1
  276. package/src/x_ite/Components/Geometry2D/Disk2D.js +30 -46
  277. package/src/x_ite/Components/Geometry2D/TriangleSet2D.js +1 -1
  278. package/src/x_ite/Components/Geometry3D/ElevationGrid.js +12 -4
  279. package/src/x_ite/Components/Geometry3D/IndexedFaceSet.js +4 -4
  280. package/src/x_ite/Components/Geospatial/GeoCoordinate.js +10 -27
  281. package/src/x_ite/Components/Geospatial/GeoLOD.js +1 -1
  282. package/src/x_ite/Components/Geospatial/GeoPositionInterpolator.js +5 -10
  283. package/src/x_ite/Components/Geospatial/GeoTouchSensor.js +9 -16
  284. package/src/x_ite/Components/Geospatial/GeoTransform.js +6 -18
  285. package/src/x_ite/Components/Geospatial/GeoViewpoint.js +26 -30
  286. package/src/x_ite/Components/Geospatial/X3DGeospatialObject.js +20 -27
  287. package/src/x_ite/Components/Grouping/X3DGroupingNode.js +8 -8
  288. package/src/x_ite/Components/Grouping/X3DTransformNode.js +0 -4
  289. package/src/x_ite/Components/HAnim/HAnimHumanoid.js +68 -75
  290. package/src/x_ite/Components/Interpolation/OrientationInterpolator.js +4 -11
  291. package/src/x_ite/Components/Interpolation/X3DInterpolatorNode.js +1 -1
  292. package/src/x_ite/Components/Layout/LayoutGroup.js +4 -9
  293. package/src/x_ite/Components/Layout/ScreenFontStyle.js +1 -1
  294. package/src/x_ite/Components/Layout/ScreenGroup.js +16 -80
  295. package/src/x_ite/Components/Lighting/DirectionalLight.js +28 -36
  296. package/src/x_ite/Components/Lighting/PointLight.js +32 -47
  297. package/src/x_ite/Components/Lighting/SpotLight.js +33 -48
  298. package/src/x_ite/Components/Navigation/Billboard.js +49 -56
  299. package/src/x_ite/Components/Navigation/LOD.js +2 -2
  300. package/src/x_ite/Components/Navigation/OrthoViewpoint.js +29 -30
  301. package/src/x_ite/Components/Navigation/Viewpoint.js +16 -20
  302. package/src/x_ite/Components/Navigation/X3DViewpointNode.js +82 -111
  303. package/src/x_ite/Components/Networking/Anchor.js +18 -7
  304. package/src/x_ite/Components/ParticleSystems/BoundedPhysicsModel.js +6 -6
  305. package/src/x_ite/Components/ParticleSystems/ConeEmitter.js +44 -36
  306. package/src/x_ite/Components/ParticleSystems/ExplosionEmitter.js +26 -17
  307. package/src/x_ite/Components/ParticleSystems/ForcePhysicsModel.js +20 -7
  308. package/src/x_ite/Components/ParticleSystems/ParticleSystem.js +463 -882
  309. package/src/x_ite/Components/ParticleSystems/PointEmitter.js +39 -35
  310. package/src/x_ite/Components/ParticleSystems/PolylineEmitter.js +112 -128
  311. package/src/x_ite/Components/ParticleSystems/SurfaceEmitter.js +105 -112
  312. package/src/x_ite/Components/ParticleSystems/VolumeEmitter.js +138 -176
  313. package/src/x_ite/Components/ParticleSystems/WindPhysicsModel.js +16 -11
  314. package/src/x_ite/Components/ParticleSystems/X3DParticleEmitterNode.js +807 -217
  315. package/src/x_ite/Components/Picking/LinePickSensor.js +31 -39
  316. package/src/x_ite/Components/PointingDeviceSensor/CylinderSensor.js +91 -108
  317. package/src/x_ite/Components/PointingDeviceSensor/PlaneSensor.js +56 -59
  318. package/src/x_ite/Components/PointingDeviceSensor/SphereSensor.js +54 -71
  319. package/src/x_ite/Components/PointingDeviceSensor/TouchSensor.js +8 -15
  320. package/src/x_ite/Components/ProjectiveTextureMapping/TextureProjectorParallel.js +43 -50
  321. package/src/x_ite/Components/ProjectiveTextureMapping/TextureProjectorPerspective.js +32 -39
  322. package/src/x_ite/Components/Rendering/ClipPlane.js +3 -11
  323. package/src/x_ite/Components/Rendering/Color.js +12 -24
  324. package/src/x_ite/Components/Rendering/ColorRGBA.js +13 -25
  325. package/src/x_ite/Components/Rendering/IndexedLineSet.js +26 -4
  326. package/src/x_ite/Components/Rendering/LineSet.js +35 -13
  327. package/src/x_ite/Components/Rendering/PointSet.js +35 -13
  328. package/src/x_ite/Components/Rendering/X3DComposedGeometryNode.js +13 -5
  329. package/src/x_ite/Components/Rendering/X3DGeometryNode.js +331 -387
  330. package/src/x_ite/Components/Rendering/X3DLineGeometryNode.js +350 -140
  331. package/src/x_ite/Components/Rendering/X3DPointGeometryNode.js +116 -126
  332. package/src/x_ite/Components/RigidBodyPhysics/DoubleAxisHingeJoint.js +24 -38
  333. package/src/x_ite/Components/RigidBodyPhysics/SingleAxisHingeJoint.js +10 -17
  334. package/src/x_ite/Components/Shaders/ComposedShader.js +35 -75
  335. package/src/x_ite/Components/Shaders/FloatVertexAttribute.js +8 -11
  336. package/src/x_ite/Components/Shaders/Matrix3VertexAttribute.js +10 -14
  337. package/src/x_ite/Components/Shaders/Matrix4VertexAttribute.js +10 -14
  338. package/src/x_ite/Components/Shaders/ShaderPart.js +1 -10
  339. package/src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js +220 -210
  340. package/src/x_ite/Components/Shaders/X3DShaderNode.js +28 -10
  341. package/src/x_ite/Components/Shaders/X3DVertexAttributeNode.js +15 -1
  342. package/src/x_ite/Components/Shape/Appearance.js +37 -4
  343. package/src/x_ite/Components/Shape/FillProperties.js +12 -1
  344. package/src/x_ite/Components/Shape/LineProperties.js +33 -1
  345. package/src/x_ite/Components/Shape/PointProperties.js +24 -3
  346. package/src/x_ite/Components/Shape/Shape.js +30 -39
  347. package/src/x_ite/Components/Shape/TwoSidedMaterial.js +3 -1
  348. package/src/x_ite/Components/Sound/Sound.js +31 -41
  349. package/src/x_ite/Components/Text/Text.js +6 -20
  350. package/src/x_ite/Components/Texturing/ImageTexture.js +1 -1
  351. package/src/x_ite/Components/Texturing/MovieTexture.js +1 -1
  352. package/src/x_ite/Components/Texturing/PixelTexture.js +2 -2
  353. package/src/x_ite/Components/Texturing/TextureCoordinate.js +5 -5
  354. package/src/x_ite/Components/Texturing/TextureProperties.js +4 -4
  355. package/src/x_ite/Components/Texturing/X3DSingleTextureNode.js +5 -4
  356. package/src/x_ite/Components/Texturing/X3DTexture2DNode.js +24 -33
  357. package/src/x_ite/Components/Texturing3D/TextureCoordinate3D.js +5 -5
  358. package/src/x_ite/Components/Texturing3D/TextureCoordinate4D.js +5 -5
  359. package/src/x_ite/Components/Texturing3D/X3DTexture3DNode.js +12 -19
  360. package/src/x_ite/Components/VolumeRendering/X3DVolumeDataNode.js +8 -8
  361. package/src/x_ite/Components.js +2 -2
  362. package/src/x_ite/Fallback.js +9 -3
  363. package/src/x_ite/Fields/SFColor.js +4 -0
  364. package/src/x_ite/Fields/SFColorRGBA.js +4 -0
  365. package/src/x_ite/Fields/SFImage.js +2 -11
  366. package/src/x_ite/Fields/SFMatrixPrototypeTemplate.js +4 -0
  367. package/src/x_ite/Fields/SFRotation.js +4 -0
  368. package/src/x_ite/Fields/SFString.js +4 -0
  369. package/src/x_ite/Fields/SFVecPrototypeTemplate.js +22 -2
  370. package/src/x_ite/Parser/XMLParser.js +1 -1
  371. package/src/x_ite/Rendering/TextureBuffer.js +43 -36
  372. package/src/x_ite/Rendering/VertexArray.js +103 -0
  373. package/src/x_ite/Rendering/X3DRenderObject.js +127 -148
  374. package/src/x_ite/X3D.js +32 -26
  375. package/src/x_ite.config.js +0 -5
  376. package/src/x_ite.css +216 -175
  377. package/src/x_ite.html +15 -10
  378. package/src/x_ite.js +49 -1
  379. package/x_ite.min.html +15 -10
  380. package/dist/assets/hatching/0.png +0 -0
  381. package/dist/assets/linetype/0.png +0 -0
  382. package/src/assets/hatching/0.png +0 -0
  383. package/src/assets/linetype/0.png +0 -0
  384. package/src/spinner.css +0 -67
  385. package/src/x_ite/Browser/Shape/LineStipples.xcf +0 -0
@@ -1 +1 @@
1
- !function(){const e=window[Symbol.for("X_ITE.X3D-5.0.3")].define,t=window[Symbol.for("X_ITE.X3D-5.0.3")].require;e("standard/Math/Geometry/Spheroid3",[],(function(){"use strict";function e(e,t){switch(arguments.length){case 0:this.semiMajorAxis=0,this.semiMinorAxis=0;break;case 2:this.semiMajorAxis=e,this.semiMinorAxis=t;break;case 3:const i=arguments[1];this.semiMajorAxis=e,this.semiMinorAxis=e*(1-1/i)}}return e.prototype={constructor:e,getSemiMajorAxis:function(){return this.semiMajorAxis},getSemiMinorAxis:function(){return this.semiMinorAxis},toString:function(){return this.semiMajorAxis+" "+this.semiMinorAxis}},e})),e("standard/Geospatial/ReferenceEllipsoids",["standard/Math/Geometry/Spheroid3"],(function(e){"use strict";return{AA:new e(6377563.396,299.3249646,!0),AM:new e(6377340.189,299.3249646,!0),AN:new e(6378160,298.25,!0),BN:new e(6377483.865,299.1528128,!0),BR:new e(6377397.155,299.1528128,!0),CC:new e(6378206.4,294.9786982,!0),CD:new e(6378249.145,293.465,!0),EA:new e(6377276.345,300.8017,!0),EB:new e(6377298.556,300.8017,!0),EC:new e(6377301.243,300.8017,!0),ED:new e(6377295.664,300.8017,!0),EE:new e(6377304.063,300.8017,!0),EF:new e(6377309.613,300.8017,!0),FA:new e(6378155,298.3,!0),HE:new e(6378200,298.3,!0),HO:new e(6378270,297,!0),ID:new e(6378160,298.247,!0),IN:new e(6378388,297,!0),KA:new e(6378245,298.3,!0),RF:new e(6378137,298.257222101,!0),SA:new e(6378160,298.25,!0),WD:new e(6378135,298.26,!0),WE:new e(6378137,298.257223563,!0),SUN:new e(696342e3,1/9e-6,!0),MERCURY:new e(2439700,2439700),VENUS:new e(6051800,6051800),MOON:new e(1738140,1735970),MARS:new e(3395428,3377678),JUPITER:new e(71492e3,66854e3),SATURN:new e(60268e3,54364e3),URANUS:new e(2555e3,24973e3),NEPTUNE:new e(24764e3,24341e3),PLUTO:new e(1153e3,1153e3)}})),e("standard/Geospatial/Geodetic",["standard/Math/Numbers/Vector3","standard/Math/Algorithm"],(function(e,t){"use strict";function i(e,t,i){this.longitudeFirst=!t,this.degrees=!i,this.a=e.getSemiMajorAxis(),this.c=e.getSemiMinorAxis(),this.c2a2=Math.pow(e.getSemiMinorAxis()/this.a,2),this.ecc2=1-this.c2a2}return i.prototype={constructor:i,convert:function(e,t){const i=e.z;if(this.longitudeFirst)var n=e.y,o=e.x;else n=e.x,o=e.y;return this.degrees&&(n*=Math.PI/180,o*=Math.PI/180),this.convertRadians(n,o,i,t)},convertRadians:function(e,t,i,n){const o=Math.sin(e),s=Math.pow(o,2),r=Math.cos(e),a=this.a/Math.sqrt(1-this.ecc2*s),l=(a+i)*r;return n.set(l*Math.cos(t),l*Math.sin(t),(a*this.c2a2+i)*o)},apply:function(e,t){if(this.applyRadians(e,t),this.degrees&&(t.x*=180/Math.PI,t.y*=180/Math.PI),this.longitudeFirst){const e=t.x;t.x=t.y,t.y=e}return t},applyRadians:function(e,t){const i=e.x,n=e.y,o=e.z,s=Math.sqrt(i*i+n*n);if(0==s)return t.set(Math.PI,0,o-this.c);let r=0,a=Math.atan2(n,i),l=0,h=this.a,c=h,d=this.ecc2;for(let e=0;e<30;++e){const e=l,t=r;r=Math.atan(o/s/(1-d*c/(c+l)));const i=Math.sin(r);if(c=h/Math.sqrt(1-d*i*i),l=s/Math.cos(r)-c,Math.abs(l-e)<.001&&Math.abs(r-t)<1e-10)break}return t.set(r,a,l)},normal:function(e,t){const i=this.applyRadians(e,t),n=i.x,o=i.y,s=Math.cos(n),r=Math.cos(o)*s,a=Math.sin(o)*s,l=Math.sin(n);return t.set(r,a,l)}},i})),e("standard/Geospatial/UniversalTransverseMercator",["standard/Geospatial/Geodetic","standard/Math/Numbers/Vector3","standard/Math/Algorithm"],(function(e,t,i){"use strict";const n=1e7,o=5e5,s=.9996;function r(t,n,o,r){const a=t.getSemiMajorAxis(),l=1-Math.pow(t.getSemiMinorAxis()/a,2),h=l/(1-l),c=(1-Math.sqrt(1-l))/(1+Math.sqrt(1-l));this.southernHemisphere=!o,this.eastingFirst=!r,this.a=a,this.ecc2=l,this.EE=h,this.E8=8*h,this.E9=9*h,this.E252=252*h,this.e1=c,this.A=s*(a*(1-l/4-3*l*l/64-5*l*l*l/256)),this.B=3*c/2-7*c*c*c/32,this.C=21*c*c/16-55*c*c*c*c/32,this.D=151*c*c*c/96,this.E=a*(1-l),this.W=1-l/4-3*l*l/64-5*l*l*l/256,this.X=3*l/8+3*l*l/32+45*l*l*l/1024,this.Y=15*l*l/256+45*l*l*l/1024,this.Z=35*l*l*l/3072,this.longitude0=i.radians(6*n-183),this.geodeticConverter=new e(t,!0,!0)}return r.prototype={constructor:r,convert:function(e,t){if(this.eastingFirst)var i=e.y,r=e.x;else i=e.x,r=e.y;let a=this.southernHemisphere;i<0&&(a=!this.southernHemisphere,i=-i),a&&(i-=n),r-=o;const l=i/this.A,h=l+this.B*Math.sin(2*l)+this.C*Math.sin(4*l)+this.D*Math.sin(6*l),c=Math.pow(Math.sin(h),2),d=Math.cos(h),u=Math.tan(h),p=this.a/Math.sqrt(1-this.ecc2*c),_=Math.pow(u,2),g=Math.pow(u,8),w=this.EE*_,f=w*w,m=this.E/Math.pow(1-this.ecc2*c,1.5),O=r/(p*s),y=(5+3*_+10*w-4*f-this.E9)*Math.pow(O,4)/24,x=(61+90*_+298*w+45*g-this.E252-3*f)*Math.pow(O,6)/720,S=(5-2*w+28*_-3*f+this.E8+24*g)*Math.pow(O,5)/120,F=h-p*u/m*(O*O/2-y+x),C=this.longitude0+(O-(1+2*_+w)*Math.pow(O,3)/6+S)/d;return this.geodeticConverter.convertRadians(F,C,e.z,t)},apply:function(e,t){const i=this.geodeticConverter.applyRadians(e,t),r=i.x,a=i.y,l=Math.tan(r),h=Math.cos(r),c=this.EE,d=this.a/Math.sqrt(1-this.ecc2*Math.pow(Math.sin(r),2)),u=l*l,p=u*u*u,_=c*h*h,g=h*(a-this.longitude0),w=this.a*(this.W*r-this.X*Math.sin(2*r)+this.Y*Math.sin(4*r)-this.Z*Math.sin(6*r)),f=s*d*(g+(1-u+_)*Math.pow(g,3)/6+(5-18*p+72*_-58*c)*Math.pow(g,5)/120)+o;let m=s*(w+d*l*(g*g/2+(5-u+9*_+4*_*_)*Math.pow(g,4)/24+(61-58*p+600*_-330*c)*Math.pow(g,6)/720));return r<0?(m+=n,this.southernHemisphere||(m=-m)):this.southernHemisphere&&(m=-m),this.eastingFirst?t.set(f,m,i.z):t.set(m,f,i.z)}},r})),e("x_ite/Browser/Geospatial/Geocentric",["standard/Math/Numbers/Vector3","standard/Math/Algorithm"],(function(e,t){"use strict";function i(){}return i.prototype={constructor:i,convert:function(e,t){return t.assign(e)},apply:function(e,t){return t.assign(e)},slerp:function(e,i,n){const o=e.abs(),s=i.abs();return e.normalize(),i.normalize(),t.simpleSlerp(e,i,n).multiply(t.lerp(o,s,n))}},i})),e("x_ite/Browser/Geospatial/Geospatial",["standard/Geospatial/ReferenceEllipsoids","standard/Geospatial/Geodetic","standard/Geospatial/UniversalTransverseMercator","x_ite/Browser/Geospatial/Geocentric"],(function(e,t,i,n){"use strict";let o=0;const s=o++,r=o++,a=o++,l={GD:s,GDC:s,UTM:r,GC:a,GCC:a,GS:a},h=/^Z(\d+)$/;return{GD:s,UTM:r,GC:a,getReferenceFrame:function(o,l){switch(this.getCoordinateSystem(o)){case s:return new t(this.getEllipsoid(o),this.getLatitudeFirst(o),l);case r:return new i(this.getEllipsoid(o),this.getZone(o),this.getNorthernHemisphere(o),this.getNorthingFirst(o));case a:return new n}return new t(e.WE,!0,l)},getElevationFrame:function(e,i){return new t(this.getEllipsoid(e),!0,i)},getCoordinateSystem:function(e){for(const t of e){const e=l[t];if(void 0!==e)return e}return s},getEllipsoid:function(t){for(const i of t){const t=e[i];if(void 0!==t)return t}return e.WE},getEllipsoidString:function(t){for(const i of t){if(void 0!==e[i])return i}return"WE"},isStandardOrder:function(e){switch(this.getCoordinateSystem(e)){case s:return this.getLatitudeFirst(e);case r:return this.getNorthingFirst(e);case a:return!0}return this.getLatitudeFirst(e)},getLatitudeFirst:function(e){for(const t of e)if("longitude_first"===t)return!1;return!0},getNorthingFirst:function(e){for(const t of e)if("easting_first"===t)return!1;return!0},getZone:function(e){for(const t of e){const e=t.match(h);if(e)return parseInt(e[1])}return 1},getNorthernHemisphere:function(e){for(const t of e)if("S"===t)return!1;return!0}}})),e("x_ite/Components/Geospatial/X3DGeospatialObject",["x_ite/Base/X3DConstants","x_ite/Browser/Geospatial/Geospatial","x_ite/Base/X3DCast","standard/Math/Numbers/Vector3","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o){"use strict";var s=new n(0,0,0),r=new n(0,0,0),a=new n(0,0,0),l=new n(0,0,0),h=new n(0,0,0),c=new n(0,0,0);function d(t){this.addType(e.X3DGeospatialObject),this.radians=!1,this.origin=new n(0,0,0),this.originMatrix=new o,this.invOriginMatrix=new o}function u(e,t){return this.invOriginMatrix.multVecMatrix(this.referenceFrame.convert(e,t))}function p(e,t){return this.referenceFrame.apply(this.originMatrix.multVecMatrix(s.assign(e)),t)}function _(e,t){return this.invOriginMatrix.multDirMatrix(this.elevationFrame.normal(this.originMatrix.multVecMatrix(s.assign(e)),t))}function g(e,t){return w.call(this,e,t).multRight(this.invOriginMatrix)}function w(e,t){return this.referenceFrame.convert(e,a),this.elevationFrame.normal(a,h),l.set(0,0,1).cross(h),l.equals(n.Zero)&&l.set(1,0,0),c.assign(l).cross(h),l.normalize(),c.normalize(),t.set(l.x,l.y,l.z,0,h.x,h.y,h.z,0,c.x,c.y,c.z,0,a.x,a.y,a.z,1)}return d.prototype={constructor:d,initialize:function(){this._geoSystem.addInterest("set_geoSystem__",this),this._geoOrigin.addInterest("set_geoOrigin__",this),this.set_geoSystem__(),this.set_geoOrigin__()},set_geoSystem__:function(){this.coordinateSystem=t.getCoordinateSystem(this._geoSystem),this.referenceFrame=t.getReferenceFrame(this._geoSystem,this.radians),this.elevationFrame=t.getElevationFrame(this._geoSystem,this.radians),this.standardOrder=t.isStandardOrder(this._geoSystem)},set_geoOrigin__:function(){this.geoOriginNode&&(this.geoOriginNode.removeInterest("set_origin__",this),this.geoOriginNode.removeInterest("set_rotateYUp__",this),this.geoOriginNode.removeInterest("addNodeEvent",this)),this.geoOriginNode=i(e.GeoOrigin,this._geoOrigin),this.geoOriginNode&&(this.geoOriginNode.addInterest("set_origin__",this),this.geoOriginNode.addInterest("set_rotateYUp__",this),this.geoOriginNode.addInterest("addNodeEvent",this)),this.set_origin__(),this.set_rotateYUp__()},set_origin__:function(){this.geoOriginNode?this.geoOriginNode.getOrigin(this.origin):this.origin.set(0,0,0),this.set_originMatrix__()},set_originMatrix__:function(){try{if(this.geoOriginNode){var e=this.origin;this.elevationFrame.normal(e,h),l.set(0,0,1).cross(h),l.equals(n.Zero)&&l.set(1,0,0),c.assign(l).cross(h),l.normalize(),c.normalize(),this.originMatrix.set(l.x,l.y,l.z,0,h.x,h.y,h.z,0,c.x,c.y,c.z,0,e.x,e.y,e.z,1),this.invOriginMatrix.assign(this.originMatrix).inverse()}}catch(e){}},set_rotateYUp__:function(){this.geoOriginNode&&this.geoOriginNode._rotateYUp.getValue()?(this.getCoord=u,this.getGeoCoord=p,this.getGeoUpVector=_,this.getLocationMatrix=g):(delete this.getCoord,delete this.getGeoCoord,delete this.getGeoUpVector,delete this.getLocationMatrix)},getReferenceFrame:function(){return this.referenceFrame},getStandardOrder:function(){return this.standardOrder},getCoord:function(e,t){return this.referenceFrame.convert(e,t).subtract(this.origin)},getGeoCoord:function(e,t){return this.referenceFrame.apply(s.assign(e).add(this.origin),t)},getGeoElevation:function(e){return this.getGeoCoord(e,r).z},getGeoUpVector:function(e,t){return this.elevationFrame.normal(s.assign(e).add(this.origin),t)},getLocationMatrix:function(e,t){var i=this.origin,n=w.call(this,e,t);return n[12]-=i.x,n[13]-=i.y,n[14]-=i.z,n}},d})),e("x_ite/Components/Geospatial/GeoCoordinate",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DCoordinateNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Geometry/Triangle3","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";function l(e){n.call(this,e),o.call(this,e),this.addType(s.GeoCoordinate)}var h,c,d,u,p;return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"point",new e.MFVec3d)]),getTypeName:function(){return"GeoCoordinate"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"coord"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._point.addInterest("set_point__",this),this.set_point__()},set_point__:function(){this.point=this._point.getValue(),this.length=this._point.length},isEmpty:function(){return 0===this.length},getSize:function(){return this.length},set1Point:(p=new a(0,0,0),function(e,t){this._point[e]=this.getGeoCoord(t,p)}),get1Point:(u=new a(0,0,0),function(e,t){if(e<this.length){const i=this.point;return e*=3,this.getCoord(u.set(i[e],i[e+1],i[e+2]),t)}return t.set(0,0,0)}),addPoint:function(){var e=new a(0,0,0),t=new a(0,0,0);return function(i,n){if(i<this.length){const o=this.point;i*=3,this.getCoord(e.set(o[i],o[i+1],o[i+2]),t),n.push(t[0],t[1],t[2],1)}else n.push(0,0,0,1)}}(),addPoints:function(){var e=new a(0,0,0),t=new a(0,0,0);return function(i,n){const o=this.point;for(var s=0,r=3*this.length;s<r;s+=3)this.getCoord(e.set(o[s],o[s+1],o[s+2]),t),i.push(t[0],t[1],t[2],1);for(s=r,r=3*n;s<r;s+=3)i.push(0,0,0,1)}}(),getNormal:(h=new a(0,0,0),c=new a(0,0,0),d=new a(0,0,0),function(e,t,i){var n=this.length;return e<n&&t<n&&i<n?r.normal(this.get1Point(e,h),this.get1Point(t,c),this.get1Point(i,d),new a(0,0,0)):new a(0,0,0)}),getQuadNormal:function(){var e=new a(0,0,0),t=new a(0,0,0),i=new a(0,0,0),n=new a(0,0,0);return function(o,s,l,h){var c=this.length;return o<c&&s<c&&l<c&&h<c?r.quadNormal(this.get1Point(o,e),this.get1Point(s,t),this.get1Point(l,i),this.get1Point(h,n),new a(0,0,0)):new a(0,0,0)}}()}),l})),e("x_ite/Components/Geospatial/GeoElevationGrid",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DGeometryNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Geometry/Triangle3","standard/Math/Numbers/Vector2","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a,l,h){"use strict";function c(e){n.call(this,e),o.call(this,e),this.addType(s.GeoElevationGrid),this._creaseAngle.setUnit("angle"),this._height.setUnit("length"),this.colorNode=null,this.texCoordNode=null,this.normalNode=null}return c.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:c,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.initializeOnly,"geoGridOrigin",new e.SFVec3d),new t(s.initializeOnly,"xDimension",new e.SFInt32),new t(s.initializeOnly,"zDimension",new e.SFInt32),new t(s.initializeOnly,"xSpacing",new e.SFDouble(1)),new t(s.initializeOnly,"zSpacing",new e.SFDouble(1)),new t(s.inputOutput,"yScale",new e.SFFloat(1)),new t(s.initializeOnly,"solid",new e.SFBool(!0)),new t(s.initializeOnly,"ccw",new e.SFBool(!0)),new t(s.initializeOnly,"creaseAngle",new e.SFDouble),new t(s.initializeOnly,"colorPerVertex",new e.SFBool(!0)),new t(s.initializeOnly,"normalPerVertex",new e.SFBool(!0)),new t(s.inputOutput,"color",new e.SFNode),new t(s.inputOutput,"texCoord",new e.SFNode),new t(s.inputOutput,"normal",new e.SFNode),new t(s.inputOutput,"height",new e.MFDouble(0,0))]),getTypeName:function(){return"GeoElevationGrid"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"geometry"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._color.addInterest("set_color__",this),this._texCoord.addInterest("set_texCoord__",this),this._normal.addInterest("set_normal__",this),this.set_color__(),this.set_texCoord__(),this.set_normal__()},set_color__:function(){this.colorNode&&(this.colorNode.removeInterest("requestRebuild",this),this.colorNode._transparent.removeInterest("set_transparent__",this)),this.colorNode=r(s.X3DColorNode,this._color),this.colorNode?(this.colorNode.addInterest("requestRebuild",this),this.colorNode._transparent.addInterest("set_transparent__",this),this.set_transparent__()):this.setTransparent(!1)},set_transparent__:function(){this.setTransparent(this.colorNode.getTransparent())},set_texCoord__:function(){this.texCoordNode&&this.texCoordNode.removeInterest("requestRebuild",this),this.texCoordNode=r(s.X3DTextureCoordinateNode,this._texCoord),this.texCoordNode&&this.texCoordNode.addInterest("requestRebuild",this),this.setTextureCoordinate(this.texCoordNode)},set_normal__:function(){this.normalNode&&this.normalNode.removeInterest("requestRebuild",this),this.normalNode=r(s.X3DNormalNode,this._normal),this.normalNode&&this.normalNode.addInterest("requestRebuild",this)},getColor:function(){return this.colorNode},getTexCoord:function(){return this.texCoordNode},getNormal:function(){return this.normalNode},getHeight:function(e){return e<this._height.length?this._height[e]*this._yScale.getValue():0},createTexCoords:function(){for(var e=[],t=this._xDimension.getValue(),i=this._zDimension.getValue(),n=t-1,o=i-1,s=0;s<i;++s)for(var r=0;r<t;++r)e.push(new l(r/n,s/o));return e},createNormals:function(e,t,i){for(var n=!this._ccw.getValue(),o=[],s=[],r=0;r<e.length;++r)o[r]=[];for(var l=0;l<t.length;l+=3){var c=t[l],d=t[l+1],u=t[l+2];o[c].push(s.length),o[d].push(s.length+1),o[u].push(s.length+2);var p=a.normal(e[c],e[d],e[u],new h(0,0,0));n&&p.negate(),s.push(p),s.push(p),s.push(p)}return this.refineNormals(o,s,this._creaseAngle.getValue())},createCoordIndex:function(){for(var e=[],t=this._xDimension.getValue(),i=t-1,n=this._zDimension.getValue()-1,o=0;o<n;++o)for(var s=0;s<i;++s){var r=o*t+s,a=(o+1)*t+s,l=(o+1)*t+(s+1),h=o*t+(s+1);e.push(r),e.push(l),e.push(a),e.push(r),e.push(h),e.push(l)}return e},createPoints:function(){var e=[],t=this._xDimension.getValue(),i=this._zDimension.getValue(),n=this._xSpacing.getValue(),o=this._zSpacing.getValue();if(this.getStandardOrder())for(var s=0;s<i;++s)for(var r=0;r<t;++r){(a=new h(o*s,n*r,this.getHeight(r+s*t))).add(this._geoGridOrigin.getValue()),e.push(this.getCoord(a,a))}else for(s=0;s<i;++s)for(r=0;r<t;++r){var a;(a=new h(n*r,o*s,this.getHeight(r+s*t))).add(this._geoGridOrigin.getValue()),e.push(this.getCoord(a,a))}return e},build:function(){if(!(this._xDimension.getValue()<2||this._zDimension.getValue()<2)){var e=this._colorPerVertex.getValue(),t=this._normalPerVertex.getValue(),i=this.createCoordIndex(),n=this.getColor(),o=this.getTexCoord(),s=this.getNormal(),r=this.createPoints(),a=this.getColors(),l=this.getMultiTexCoords(),h=this.getNormals(),c=this.getVertices(),d=0;if(o)o.init(l);else{var u=this.createTexCoords(),p=this.getTexCoords();l.push(p)}for(var _=0;_<i.length;++d)for(var g=0;g<6;++g,++_){var w=i[_],f=r[w];if(n&&(e?n.addColor(w,a):n.addColor(d,a)),o)o.addTexCoord(w,l);else{var m=u[w];p.push(m.x,m.y,0,1)}s&&(t?s.addVector(w,h):s.addVector(d,h)),c.push(f.x,f.y,f.z,1)}if(!s)for(var O=this.createNormals(r,i),y=0;y<O.length;++y){var x=O[y];h.push(x.x,x.y,x.z)}this.setSolid(this._solid.getValue()),this.setCCW(this._ccw.getValue())}}}),c})),e("x_ite/Components/Geospatial/GeoLOD",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Components/Grouping/X3DBoundedObject","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","x_ite/Rendering/TraverseType","x_ite/Components/Grouping/Group","x_ite/Components/Networking/Inline","standard/Math/Numbers/Vector3","standard/Math/Numbers/Matrix4","standard/Math/Geometry/Box3"],(function(e,t,i,n,o,s,r,a,l,h,c,d,u){"use strict";var p=new c(0,0,0);function _(e){n.call(this,e),o.call(this,e),s.call(this,e),this.addType(r.GeoLOD),this._range.setUnit("length"),this.unload=!1,this.rootGroup=new l(this.getBrowser().getPrivateScene()),this.rootInline=new h(e),this.child1Inline=new h(e),this.child2Inline=new h(e),this.child3Inline=new h(e),this.child4Inline=new h(e),this.childrenLoaded=!1,this.childBBox=new u,this.keepCurrentLevel=!1,this.modelViewMatrix=new d}return _.prototype=Object.assign(Object.create(n.prototype),o.prototype,s.prototype,{constructor:_,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.initializeOnly,"rootUrl",new e.MFString),new t(r.initializeOnly,"child1Url",new e.MFString),new t(r.initializeOnly,"child2Url",new e.MFString),new t(r.initializeOnly,"child3Url",new e.MFString),new t(r.initializeOnly,"child4Url",new e.MFString),new t(r.initializeOnly,"center",new e.SFVec3d),new t(r.initializeOnly,"range",new e.SFFloat(10)),new t(r.outputOnly,"level_changed",new e.SFInt32(-1)),new t(r.inputOutput,"visible",new e.SFBool(!0)),new t(r.inputOutput,"bboxDisplay",new e.SFBool),new t(r.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(r.initializeOnly,"bboxCenter",new e.SFVec3f),new t(r.initializeOnly,"rootNode",new e.MFNode),new t(r.outputOnly,"children",new e.MFNode)]),getTypeName:function(){return"GeoLOD"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),s.prototype.initialize.call(this),this._rootNode.addFieldInterest(this.rootGroup._children),this.rootGroup._children=this._rootNode,this.rootGroup.setPrivate(!0),this.rootGroup.setup(),this.rootInline._loadState.addInterest("set_rootLoadState__",this),this.child1Inline._loadState.addInterest("set_childLoadState__",this),this.child2Inline._loadState.addInterest("set_childLoadState__",this),this.child3Inline._loadState.addInterest("set_childLoadState__",this),this.child4Inline._loadState.addInterest("set_childLoadState__",this),this._rootUrl.addFieldInterest(this.rootInline._url),this._child1Url.addFieldInterest(this.child1Inline._url),this._child2Url.addFieldInterest(this.child2Inline._url),this._child3Url.addFieldInterest(this.child3Inline._url),this._child4Url.addFieldInterest(this.child4Inline._url),this.rootInline._load=!0,this.child1Inline._load=!1,this.child2Inline._load=!1,this.child3Inline._load=!1,this.child4Inline._load=!1,this.rootInline._url=this._rootUrl,this.child1Inline._url=this._child1Url,this.child2Inline._url=this._child2Url,this.child3Inline._url=this._child3Url,this.child4Inline._url=this._child4Url,this.rootInline.setup(),this.child1Inline.setup(),this.child2Inline.setup(),this.child3Inline.setup(),this.child4Inline.setup()},getBBox:function(e,t){if(this._bboxSize.getValue().equals(this.getDefaultBBoxSize())){switch(this.childrenLoaded?this._level_changed.getValue():0){case 0:return this._rootNode.length?this.rootGroup.getBBox(e,t):this.rootInline.getBBox(e,t);case 1:{const i=this.childBBox;return e.set(),e.add(this.child1Inline.getBBox(i,t)),e.add(this.child2Inline.getBBox(i,t)),e.add(this.child3Inline.getBBox(i,t)),e.add(this.child4Inline.getBBox(i,t)),e}}return e.set()}return e.set(this._bboxSize.getValue(),this._bboxCenter.getValue())},set_rootLoadState__:function(){0===this._level_changed.getValue()&&(this._rootNode.length||this.rootInline.checkLoadState()===r.COMPLETE_STATE&&(this._children=this.rootInline.getInternalScene().getRootNodes(),this.childrenLoaded=!1))},set_childLoadState__:function(){if(1===this._level_changed.getValue()){var e=0;if(this.child1Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child1Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child2Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child2Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child3Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child3Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child4Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child4Inline.checkLoadState()!==r.FAILED_STATE||++e,4===e){this.childrenLoaded=!0;var t=this._children;t.length=0;for(var i=0,n=(o=this.child1Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);for(i=0,n=(o=this.child2Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);for(i=0,n=(o=this.child3Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);var o;for(i=0,n=(o=this.child4Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i])}}},set_childCameraObject__:function(){this.setCameraObject(this.child1Inline.getCameraObject()||this.child2Inline.getCameraObject()||this.child3Inline.getCameraObject()||this.child4Inline.getCameraObject())},set_childPickableObject__:function(){this.setPickableObject(this.child1Inline.getPickableObject()||this.child2Inline.getPickableObject()||this.child3Inline.getPickableObject()||this.child4Inline.getPickableObject())},getLevel:function(e){return this.getDistance(e)<this._range.getValue()?1:0},getDistance:function(e){return e.translate(this.getCoord(this._center.getValue(),p)),e.origin.abs()},traverse:function(e,t){switch(e){case a.PICKING:var i=t.getBrowser().getPickingHierarchy();return i.push(this),this.traverseChildren(e,t),void i.pop();case a.DISPLAY:var n=this.getLevel(this.modelViewMatrix.assign(t.getModelViewMatrix().get()));if(n!==this._level_changed.getValue())switch(this._level_changed=n,n){case 0:this.child1Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child2Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child3Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child4Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child1Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child2Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child3Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child4Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this._rootNode.length?(this.rootGroup._isCameraObject.addFieldInterest(this._isCameraObject),this.rootGroup._isPickableObject.addFieldInterest(this._isPickableObject),this.setCameraObject(this.rootGroup.getCameraObject()),this.setPickableObject(this.rootGroup.getPickableObject()),this._children=this._rootNode,this.childrenLoaded=!1):this.rootInline.checkLoadState()==r.COMPLETE_STATE&&(this.rootInline._isCameraObject.addFieldInterest(this._isCameraObject),this.rootInline._isPickableObject.addFieldInterest(this._isPickableObject),this.setCameraObject(this.rootInline.getCameraObject()),this.setPickableObject(this.rootInline.getPickableObject()),this._children=this.rootInline.getInternalScene().getRootNodes(),this.childrenLoaded=!1),this.unload&&(this.child1Inline._load=!1,this.child2Inline._load=!1,this.child3Inline._load=!1,this.child4Inline._load=!1);break;case 1:this._rootNode.length?(this.rootGroup._isCameraObject.removeFieldInterest(this._isCameraObject),this.rootGroup._isPickableObject.removeFieldInterest(this._isPickableObject)):(this.rootInline._isCameraObject.removeFieldInterest(this._isCameraObject),this.rootInline._isPickableObject.removeFieldInterest(this._isPickableObject)),this.child1Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child2Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child3Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child4Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child1Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child2Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child3Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child4Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.set_childCameraObject__(),this.set_childPickableObject__(),this.child1Inline._load.getValue()?this.set_childLoadState__():(this.child1Inline._load=!0,this.child2Inline._load=!0,this.child3Inline._load=!0,this.child4Inline._load=!0)}return void this.traverseChildren(e,t);default:return void this.traverseChildren(e,t)}},traverseChildren:function(e,t){switch(this.childrenLoaded?this._level_changed.getValue():0){case 0:this._rootNode.length?this.rootGroup.traverse(e,t):this.rootInline.traverse(e,t);break;case 1:this.child1Inline.traverse(e,t),this.child2Inline.traverse(e,t),this.child3Inline.traverse(e,t),this.child4Inline.traverse(e,t)}}}),_})),e("x_ite/Components/Geospatial/GeoLocation",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformMatrix3DNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r){"use strict";var a=new r;function l(e){n.call(this,e),o.call(this,e),this.addType(s.GeoLocation)}return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"geoCoords",new e.SFVec3d),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.inputOutput,"visible",new e.SFBool(!0)),new t(s.inputOutput,"bboxDisplay",new e.SFBool),new t(s.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(s.initializeOnly,"bboxCenter",new e.SFVec3f),new t(s.inputOnly,"addChildren",new e.MFNode),new t(s.inputOnly,"removeChildren",new e.MFNode),new t(s.inputOutput,"children",new e.MFNode)]),getTypeName:function(){return"GeoLocation"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this.addInterest("eventsProcessed",this),this.eventsProcessed()},eventsProcessed:function(){this.setMatrix(this.getLocationMatrix(this._geoCoords.getValue(),a))}}),l})),e("x_ite/Components/Geospatial/GeoMetadata",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DInfoNode","x_ite/Components/Networking/X3DUrlObject","x_ite/Base/X3DConstants"],(function(e,t,i,n,o,s){"use strict";function r(e){n.call(this,e),o.call(this,e),this.addType(s.GeoMetadata)}return r.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:r,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"url",new e.MFString),new t(s.inputOutput,"load",new e.SFBool(!0)),new t(s.inputOutput,"autoRefresh",new e.SFTime),new t(s.inputOutput,"autoRefreshTimeLimit",new e.SFTime(3600)),new t(s.inputOutput,"summary",new e.MFString),new t(s.inputOutput,"data",new e.MFNode)]),getTypeName:function(){return"GeoMetadata"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this)},requestImmediateLoad:function(e=!0){},requestUnload:function(){},set_load__:function(){},set_url__:function(){}}),r})),e("x_ite/Components/Geospatial/GeoOrigin",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DNode","x_ite/Base/X3DConstants","x_ite/Browser/Geospatial/Geospatial"],(function(e,t,i,n,o,s){"use strict";function r(e){n.call(this,e),this.addType(o.GeoOrigin),this.radians=!1}return r.prototype=Object.assign(Object.create(n.prototype),{constructor:r,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(o.inputOutput,"metadata",new e.SFNode),new t(o.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(o.inputOutput,"geoCoords",new e.SFVec3d),new t(o.initializeOnly,"rotateYUp",new e.SFBool)]),getTypeName:function(){return"GeoOrigin"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"geoOrigin"},initialize:function(){n.prototype.initialize.call(this),this._geoSystem.addInterest("set_geoSystem__",this),this.set_geoSystem__()},set_geoSystem__:function(){this.referenceFrame=s.getReferenceFrame(this._geoSystem,this.radians)},getOrigin:function(e){return this.referenceFrame.convert(this._geoCoords.getValue(),e)}}),r})),e("x_ite/Components/Geospatial/GeoPositionInterpolator",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Interpolation/X3DInterpolatorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Browser/Geospatial/Geocentric","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";function l(e){n.call(this,e),o.call(this,e),this.addType(r.GeoPositionInterpolator),this._value_changed.setUnit("length"),this.geocentric=new s}return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.inputOnly,"set_fraction",new e.SFFloat),new t(r.inputOutput,"key",new e.MFFloat),new t(r.inputOutput,"keyValue",new e.MFVec3d),new t(r.outputOnly,"value_changed",new e.SFVec3d),new t(r.outputOnly,"geovalue_changed",new e.SFVec3d)]),keyValue0:new a(0,0,0),keyValue1:new a(0,0,0),geovalue:new a(0,0,0),value:new a(0,0,0),getTypeName:function(){return"GeoPositionInterpolator"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},setup:function(){o.prototype.initialize.call(this),n.prototype.setup.call(this)},initialize:function(){n.prototype.initialize.call(this),this._keyValue.addInterest("set_keyValue__",this)},set_keyValue__:function(){var t=this._key,i=this._keyValue;i.length<t.length&&i.resize(t.length,i.length?i[i.length-1]:new e.SFVec3f)},interpolate:function(e,t,i){try{this.getCoord(this._keyValue[e].getValue(),this.keyValue0),this.getCoord(this._keyValue[t].getValue(),this.keyValue1);var n=this.geocentric.slerp(this.keyValue0,this.keyValue1,i);this._geovalue_changed=this.getGeoCoord(n,this.geovalue),this._value_changed=n}catch(e){}}}),l})),e("x_ite/Components/Geospatial/GeoProximitySensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/EnvironmentalSensor/X3DEnvironmentalSensorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Components/EnvironmentalSensor/ProximitySensor","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";var l=new a(0,0,0);function h(e){n.call(this,e),o.call(this,e),this.addType(r.GeoProximitySensor),this._position_changed.setUnit("length"),this._centerOfRotation_changed.setUnit("length"),this.proximitySensor=new s(e),this.setCameraObject(this.proximitySensor.getCameraObject()),this.setPickableObject(this.proximitySensor.getPickableObject())}return h.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:h,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.inputOutput,"enabled",new e.SFBool(!0)),new t(r.inputOutput,"size",new e.SFVec3f),new t(r.inputOutput,"center",new e.SFVec3f),new t(r.outputOnly,"isActive",new e.SFBool),new t(r.outputOnly,"enterTime",new e.SFTime),new t(r.outputOnly,"exitTime",new e.SFTime),new t(r.outputOnly,"geoCoord_changed",new e.SFVec3d),new t(r.outputOnly,"position_changed",new e.SFVec3f),new t(r.outputOnly,"orientation_changed",new e.SFRotation),new t(r.outputOnly,"centerOfRotation_changed",new e.SFVec3f)]),getTypeName:function(){return"GeoProximitySensor"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._enabled.addFieldInterest(this.proximitySensor._enabled),this._size.addFieldInterest(this.proximitySensor._size),this._center.addFieldInterest(this.proximitySensor._center),this.proximitySensor._isCameraObject.addFieldInterest(this._isCameraObject),this.proximitySensor._isPickableObject.addFieldInterest(this._isPickableObject),this.proximitySensor._isActive.addFieldInterest(this._isActive),this.proximitySensor._enterTime.addFieldInterest(this._enterTime),this.proximitySensor._exitTime.addFieldInterest(this._exitTime),this.proximitySensor._position_changed.addFieldInterest(this._position_changed),this.proximitySensor._orientation_changed.addFieldInterest(this._orientation_changed),this.proximitySensor._centerOfRotation_changed.addFieldInterest(this._centerOfRotation_changed),this.proximitySensor._position_changed.addInterest("set_position__",this),this.proximitySensor._enabled=this._enabled,this.proximitySensor._size=this._size,this.proximitySensor._center=this._center,this.proximitySensor.setup()},set_position__:function(e){this._geoCoord_changed=this.getGeoCoord(this.proximitySensor._position_changed.getValue(),l)},traverse:function(e,t){this.proximitySensor.traverse(e,t)}}),h})),e("x_ite/Components/Geospatial/GeoTouchSensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/PointingDeviceSensor/X3DTouchSensorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r,a){"use strict";var l=new a,h=new r(0,0,0);function c(e){n.call(this,e),o.call(this,e),this.addType(s.GeoTouchSensor),this._hitPoint_changed.setUnit("length")}return c.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:c,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"description",new e.SFString),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"enabled",new e.SFBool(!0)),new t(s.outputOnly,"hitTexCoord_changed",new e.SFVec2f),new t(s.outputOnly,"hitNormal_changed",new e.SFVec3f),new t(s.outputOnly,"hitPoint_changed",new e.SFVec3f),new t(s.outputOnly,"hitGeoCoord_changed",new e.SFVec3d),new t(s.outputOnly,"isOver",new e.SFBool),new t(s.outputOnly,"isActive",new e.SFBool),new t(s.outputOnly,"touchTime",new e.SFTime)]),getTypeName:function(){return"GeoTouchSensor"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this)},set_over__:function(e,t,i,o,s){try{if(n.prototype.set_over__.call(this,e,t,i,o,s),this._isOver.getValue()){var r=t.intersection;l.assign(i).inverse(),this._hitTexCoord_changed=r.texCoord,this._hitNormal_changed=i.multMatrixDir(r.normal.copy()).normalize(),this._hitPoint_changed=l.multVecMatrix(r.point.copy()),this._hitGeoCoord_changed=this.getGeoCoord(this._hitPoint_changed.getValue(),h)}}catch(e){console.error(e)}}}),c})),e("x_ite/Components/Geospatial/GeoTransform",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformMatrix3DNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r){"use strict";var a=new r,l=new r;function h(e){n.call(this,e),o.call(this,e),this.addType(s.GeoTransform),this._translation.setUnit("length")}return h.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:h,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"translation",new e.SFVec3f),new t(s.inputOutput,"rotation",new e.SFRotation),new t(s.inputOutput,"scale",new e.SFVec3f(1,1,1)),new t(s.inputOutput,"scaleOrientation",new e.SFRotation),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"geoCenter",new e.SFVec3d),new t(s.inputOutput,"visible",new e.SFBool(!0)),new t(s.inputOutput,"bboxDisplay",new e.SFBool),new t(s.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(s.initializeOnly,"bboxCenter",new e.SFVec3f),new t(s.inputOnly,"addChildren",new e.MFNode),new t(s.inputOnly,"removeChildren",new e.MFNode),new t(s.inputOutput,"children",new e.MFNode)]),getTypeName:function(){return"GeoTransform"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this.addInterest("eventsProcessed",this),this.eventsProcessed()},eventsProcessed:function(){try{this.setHidden(0===this._scale.x||0===this._scale.y||0===this._scale.z),this.getLocationMatrix(this._geoCenter.getValue(),l),a.set(this._translation.getValue(),this._rotation.getValue(),this._scale.getValue(),this._scaleOrientation.getValue()),this.setMatrix(a.multRight(l).multLeft(l.inverse()))}catch(e){this.setHidden(!0)}}}),h})),e("x_ite/Components/Geospatial/GeoViewpoint",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Navigation/X3DViewpointNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Components/Interpolation/ScalarInterpolator","x_ite/Components/Navigation/NavigationInfo","x_ite/Base/X3DConstants","standard/Math/Geometry/Camera","standard/Math/Numbers/Vector2","standard/Math/Numbers/Vector3","standard/Math/Numbers/Rotation4","standard/Math/Numbers/Matrix4","standard/Math/Algorithm"],(function(e,t,i,n,o,s,r,a,l,h,c,d,u,p){"use strict";function _(e,t){n.prototype.traverse.call(this,e,t),this.navigationInfoNode.traverse(e,t)}function g(e){switch(n.call(this,e),o.call(this,e),this.addType(a.GeoViewpoint),this._centerOfRotation.setUnit("length"),this._fieldOfView.setUnit("angle"),this.navigationInfoNode=new r(e),this.fieldOfViewInterpolator=new s(this.getBrowser().getPrivateScene()),this.projectionMatrix=new u,this.elevation=0,e.specificationVersion){case"2.0":case"3.0":case"3.1":case"3.2":this.traverse=_}}var w,f,m,O,y,x,S;return g.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:g,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(a.inputOutput,"metadata",new e.SFNode),new t(a.initializeOnly,"geoOrigin",new e.SFNode),new t(a.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(a.inputOnly,"set_bind",new e.SFBool),new t(a.inputOutput,"description",new e.SFString),new t(a.inputOutput,"position",new e.SFVec3d(0,0,1e5)),new t(a.inputOutput,"orientation",new e.SFRotation),new t(a.inputOutput,"centerOfRotation",new e.SFVec3d),new t(a.inputOutput,"fieldOfView",new e.SFFloat(.7854)),new t(a.inputOutput,"jump",new e.SFBool(!0)),new t(a.inputOutput,"retainUserOffsets",new e.SFBool),new t(a.inputOutput,"navType",new e.MFString("EXAMINE","ANY")),new t(a.inputOutput,"headlight",new e.SFBool(!0)),new t(a.initializeOnly,"speedFactor",new e.SFFloat(1)),new t(a.outputOnly,"isBound",new e.SFBool),new t(a.outputOnly,"bindTime",new e.SFTime)]),getTypeName:function(){return"GeoViewpoint"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._position.addInterest("set_position__",this),this._positionOffset.addInterest("set_position__",this),this._navType.addFieldInterest(this.navigationInfoNode._type),this._headlight.addFieldInterest(this.navigationInfoNode._headlight),this.navigationInfoNode.setup(),this.set_position__(),this.fieldOfViewInterpolator._key=[0,1],this.fieldOfViewInterpolator.setup(),this.getEaseInEaseOut()._modifiedFraction_changed.addFieldInterest(this.fieldOfViewInterpolator._set_fraction),this.fieldOfViewInterpolator._value_changed.addFieldInterest(this._fieldOfViewScale)},setInterpolators:function(t,i){if(t.getType().indexOf(a.Viewpoint)>=0){const n=t.getFieldOfView()/i.getFieldOfView();this.fieldOfViewInterpolator._keyValue=new e.MFFloat(n,i._fieldOfViewScale.getValue()),this._fieldOfViewScale=n}else this.fieldOfViewInterpolator._keyValue=new e.MFFloat(i._fieldOfViewScale.getValue(),i._fieldOfViewScale.getValue()),this._fieldOfViewScale=i._fieldOfViewScale.getValue()},setPosition:(S=new c(0,0,0),function(e){this._position.setValue(this.getGeoCoord(e,S))}),getPosition:(x=new c(0,0,0),function(){return this.getCoord(this._position.getValue(),x)}),set_position__:function(){var e=new c(0,0,0);return function(){this.getCoord(this._position.getValue(),e),this.elevation=this.getGeoElevation(e.add(this._positionOffset.getValue()))}}(),setOrientation:(O=new u,y=new d(0,0,1,0),function(e){var t=this.getLocationMatrix(this._position.getValue(),O).submatrix;y.setMatrix(t),this._orientation.setValue(y.inverse().multLeft(e))}),getOrientation:function(){var e=new u,t=new d(0,0,1,0);return function(){var i=this.getLocationMatrix(this._position.getValue(),e).submatrix;return t.setMatrix(i),t.multLeft(this._orientation.getValue())}}(),getCenterOfRotation:(m=new c(0,0,0),function(){return this.getCoord(this._centerOfRotation.getValue(),m)}),getFieldOfView:function(){var e=this._fieldOfView*this._fieldOfViewScale;return e>0&&e<Math.PI?e:Math.PI/4},getMaxFarValue:function(){return this.getBrowser().getRenderingProperty("LogarithmicDepthBuffer")?1e10:1e9},getUpVector:function(){var e=new c(0,0,0),t=new c(0,0,0);return function(){return this.getCoord(this._position.getValue(),e),this.getGeoUpVector.call(this,e.add(this._positionOffset.getValue()),t)}}(),getSpeedFactor:function(){return(Math.max(this.elevation,0)+10)/10*this._speedFactor.getValue()},getScreenScale:(f=new c(0,0,0),function(e,t){var i=t[2],n=t[3],o=Math.abs(e.z)*Math.tan(this.getFieldOfView()/2)*2;return o/=i>n?n:i,f.set(o,o,o)}),getViewportSize:(w=new h(0,0),function(e,t){var i=e[2],n=e[3],o=t*Math.tan(this.getFieldOfView()/2)*2,s=i/n;return s>1?w.set(o*s,o):w.set(o,o/s)}),getLookAtDistance:function(e){return e.size.abs()/2/Math.tan(this.getFieldOfView()/2)},getProjectionMatrixWithLimits:function(e,t,i,n){if(n||this.getBrowser().getRenderingProperty("LogarithmicDepthBuffer"))return l.perspective(this.getFieldOfView(),e,t,i[2],i[3],this.projectionMatrix);var o=Math.max(p.lerp(Math.min(e,1e4),1e4,this.elevation/1e7),1),s=Math.max(p.lerp(1e6,Math.max(t,1e6),this.elevation/1e7),1e6);return l.perspective(this.getFieldOfView(),o,s,i[2],i[3],this.projectionMatrix)}}),g})),e(t.getComponentUrl("geospatial"),["x_ite/Components","x_ite/Components/Geospatial/GeoCoordinate","x_ite/Components/Geospatial/GeoElevationGrid","x_ite/Components/Geospatial/GeoLOD","x_ite/Components/Geospatial/GeoLocation","x_ite/Components/Geospatial/GeoMetadata","x_ite/Components/Geospatial/GeoOrigin","x_ite/Components/Geospatial/GeoPositionInterpolator","x_ite/Components/Geospatial/GeoProximitySensor","x_ite/Components/Geospatial/GeoTouchSensor","x_ite/Components/Geospatial/GeoTransform","x_ite/Components/Geospatial/GeoViewpoint","x_ite/Components/Geospatial/X3DGeospatialObject"],(function(e,t,i,n,o,s,r,a,l,h,c,d,u){"use strict";e.addComponent({name:"Geospatial",types:{GeoCoordinate:t,GeoElevationGrid:i,GeoLOD:n,GeoLocation:o,GeoMetadata:s,GeoOrigin:r,GeoPositionInterpolator:a,GeoProximitySensor:l,GeoTouchSensor:h,GeoTransform:c,GeoViewpoint:d},abstractTypes:{X3DGeospatialObject:u}})}))}();
1
+ !function(){const e=window[Symbol.for("X_ITE.X3D-6.1.0")],t=e.define,i=e.require;t("x_ite/Components/Geospatial/GeoCoordinate",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DCoordinateNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Geometry/Triangle3","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";function l(e){n.call(this,e),o.call(this,e),this.addType(s.GeoCoordinate)}return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"point",new e.MFVec3d)]),getTypeName:function(){return"GeoCoordinate"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"coord"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this)},set1Point:function(){const e=new a(0,0,0);return function(t,i){this._point[t]=this.getGeoCoord(i,e)}}(),get1Point:function(){const e=new a(0,0,0);return function(t,i){if(t<this.length){const n=this.point;return t*=3,this.getCoord(e.set(n[t],n[t+1],n[t+2]),i)}return i.set(0,0,0)}}(),addPoint:function(){const e=new a(0,0,0),t=new a(0,0,0);return function(i,n){if(i<this.length){const o=this.point;i*=3,this.getCoord(e.set(o[i],o[i+1],o[i+2]),t),n.push(t[0],t[1],t[2],1)}else n.push(0,0,0,1)}}(),addPoints:function(){const e=new a(0,0,0),t=new a(0,0,0);return function(i,n){const o=this.point;for(let n=0,s=3*this.length;n<s;n+=3)this.getCoord(e.set(o[n],o[n+1],o[n+2]),t),i.push(t[0],t[1],t[2],1);for(let e=3*this.length,t=3*n;e<t;e+=3)i.push(0,0,0,1)}}(),getNormal:function(){const e=new a(0,0,0),t=new a(0,0,0),i=new a(0,0,0);return function(n,o,s){const l=this.length;return n<l&&o<l&&s<l?r.normal(this.get1Point(n,e),this.get1Point(o,t),this.get1Point(s,i),new a(0,0,0)):new a(0,0,0)}}(),getQuadNormal:function(){const e=new a(0,0,0),t=new a(0,0,0),i=new a(0,0,0),n=new a(0,0,0);return function(o,s,l,h){const d=this.length;return o<d&&s<d&&l<d&&h<d?r.quadNormal(this.get1Point(o,e),this.get1Point(s,t),this.get1Point(l,i),this.get1Point(h,n),new a(0,0,0)):new a(0,0,0)}}()}),l})),t("x_ite/Components/Geospatial/GeoElevationGrid",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DGeometryNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Geometry/Triangle3","standard/Math/Numbers/Vector2","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a,l,h){"use strict";function d(e){n.call(this,e),o.call(this,e),this.addType(s.GeoElevationGrid),this._creaseAngle.setUnit("angle"),this._height.setUnit("length"),this.colorNode=null,this.texCoordNode=null,this.normalNode=null}return d.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:d,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.initializeOnly,"geoGridOrigin",new e.SFVec3d),new t(s.initializeOnly,"xDimension",new e.SFInt32),new t(s.initializeOnly,"zDimension",new e.SFInt32),new t(s.initializeOnly,"xSpacing",new e.SFDouble(1)),new t(s.initializeOnly,"zSpacing",new e.SFDouble(1)),new t(s.inputOutput,"yScale",new e.SFFloat(1)),new t(s.initializeOnly,"solid",new e.SFBool(!0)),new t(s.initializeOnly,"ccw",new e.SFBool(!0)),new t(s.initializeOnly,"creaseAngle",new e.SFDouble),new t(s.initializeOnly,"colorPerVertex",new e.SFBool(!0)),new t(s.initializeOnly,"normalPerVertex",new e.SFBool(!0)),new t(s.inputOutput,"color",new e.SFNode),new t(s.inputOutput,"texCoord",new e.SFNode),new t(s.inputOutput,"normal",new e.SFNode),new t(s.inputOutput,"height",new e.MFDouble(0,0))]),getTypeName:function(){return"GeoElevationGrid"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"geometry"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._color.addInterest("set_color__",this),this._texCoord.addInterest("set_texCoord__",this),this._normal.addInterest("set_normal__",this),this.set_color__(),this.set_texCoord__(),this.set_normal__()},set_color__:function(){this.colorNode&&(this.colorNode.removeInterest("requestRebuild",this),this.colorNode._transparent.removeInterest("set_transparent__",this)),this.colorNode=r(s.X3DColorNode,this._color),this.colorNode?(this.colorNode.addInterest("requestRebuild",this),this.colorNode._transparent.addInterest("set_transparent__",this),this.set_transparent__()):this.setTransparent(!1)},set_transparent__:function(){this.setTransparent(this.colorNode.getTransparent())},set_texCoord__:function(){this.texCoordNode&&this.texCoordNode.removeInterest("requestRebuild",this),this.texCoordNode=r(s.X3DTextureCoordinateNode,this._texCoord),this.texCoordNode&&this.texCoordNode.addInterest("requestRebuild",this),this.setTextureCoordinate(this.texCoordNode)},set_normal__:function(){this.normalNode&&this.normalNode.removeInterest("requestRebuild",this),this.normalNode=r(s.X3DNormalNode,this._normal),this.normalNode&&this.normalNode.addInterest("requestRebuild",this)},getColor:function(){return this.colorNode},getTexCoord:function(){return this.texCoordNode},getNormal:function(){return this.normalNode},getHeight:function(e){return e<this._height.length?this._height[e]*this._yScale.getValue():0},createTexCoords:function(){for(var e=[],t=this._xDimension.getValue(),i=this._zDimension.getValue(),n=t-1,o=i-1,s=0;s<i;++s)for(var r=0;r<t;++r)e.push(new l(r/n,s/o));return e},createNormals:function(e,t,i){for(var n=!this._ccw.getValue(),o=[],s=[],r=0;r<e.length;++r)o[r]=[];for(var l=0;l<t.length;l+=3){var d=t[l],c=t[l+1],u=t[l+2];o[d].push(s.length),o[c].push(s.length+1),o[u].push(s.length+2);var _=a.normal(e[d],e[c],e[u],new h(0,0,0));n&&_.negate(),s.push(_),s.push(_),s.push(_)}return this.refineNormals(o,s,this._creaseAngle.getValue())},createCoordIndex:function(){for(var e=[],t=this._xDimension.getValue(),i=t-1,n=this._zDimension.getValue()-1,o=0;o<n;++o)for(var s=0;s<i;++s){var r=o*t+s,a=(o+1)*t+s,l=(o+1)*t+(s+1),h=o*t+(s+1);e.push(r),e.push(l),e.push(a),e.push(r),e.push(h),e.push(l)}return e},createPoints:function(){var e=[],t=this._xDimension.getValue(),i=this._zDimension.getValue(),n=this._xSpacing.getValue(),o=this._zSpacing.getValue();if(this.getStandardOrder())for(var s=0;s<i;++s)for(var r=0;r<t;++r){(a=new h(o*s,n*r,this.getHeight(r+s*t))).add(this._geoGridOrigin.getValue()),e.push(this.getCoord(a,a))}else for(s=0;s<i;++s)for(r=0;r<t;++r){var a;(a=new h(n*r,o*s,this.getHeight(r+s*t))).add(this._geoGridOrigin.getValue()),e.push(this.getCoord(a,a))}return e},build:function(){if(!(this._xDimension.getValue()<2||this._zDimension.getValue()<2)){var e=this._colorPerVertex.getValue(),t=this._normalPerVertex.getValue(),i=this.createCoordIndex(),n=this.getColor(),o=this.getTexCoord(),s=this.getNormal(),r=this.createPoints(),a=this.getColors(),l=this.getMultiTexCoords(),h=this.getNormals(),d=this.getVertices(),c=0;if(o)o.init(l);else{var u=this.createTexCoords(),_=this.getTexCoords();l.push(_)}for(var p=0;p<i.length;++c)for(var g=0;g<6;++g,++p){var m=i[p],w=r[m];if(n&&(e?n.addColor(m,a):n.addColor(c,a)),o)o.addTexCoord(m,l);else{var O=u[m];_.push(O.x,O.y,0,1)}s&&(t?s.addVector(m,h):s.addVector(c,h)),d.push(w.x,w.y,w.z,1)}if(!s)for(var y=this.createNormals(r,i),f=0;f<y.length;++f){var b=y[f];h.push(b.x,b.y,b.z)}this.setSolid(this._solid.getValue()),this.setCCW(this._ccw.getValue())}}}),d})),t("x_ite/Components/Geospatial/GeoLOD",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Components/Grouping/X3DBoundedObject","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","x_ite/Rendering/TraverseType","x_ite/Components/Grouping/Group","x_ite/Components/Networking/Inline","standard/Math/Numbers/Vector3","standard/Math/Numbers/Matrix4","standard/Math/Geometry/Box3"],(function(e,t,i,n,o,s,r,a,l,h,d,c,u){"use strict";var _=new d(0,0,0);function p(e){n.call(this,e),o.call(this,e),s.call(this,e),this.addType(r.GeoLOD),this._range.setUnit("length"),this.unload=!1,this.rootGroup=new l(this.getBrowser().getPrivateScene()),this.rootInline=new h(e),this.child1Inline=new h(e),this.child2Inline=new h(e),this.child3Inline=new h(e),this.child4Inline=new h(e),this.childrenLoaded=!1,this.childBBox=new u,this.keepCurrentLevel=!1,this.modelViewMatrix=new c}return p.prototype=Object.assign(Object.create(n.prototype),o.prototype,s.prototype,{constructor:p,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.initializeOnly,"rootUrl",new e.MFString),new t(r.initializeOnly,"child1Url",new e.MFString),new t(r.initializeOnly,"child2Url",new e.MFString),new t(r.initializeOnly,"child3Url",new e.MFString),new t(r.initializeOnly,"child4Url",new e.MFString),new t(r.initializeOnly,"center",new e.SFVec3d),new t(r.initializeOnly,"range",new e.SFFloat(10)),new t(r.outputOnly,"level_changed",new e.SFInt32(-1)),new t(r.inputOutput,"visible",new e.SFBool(!0)),new t(r.inputOutput,"bboxDisplay",new e.SFBool),new t(r.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(r.initializeOnly,"bboxCenter",new e.SFVec3f),new t(r.initializeOnly,"rootNode",new e.MFNode),new t(r.outputOnly,"children",new e.MFNode)]),getTypeName:function(){return"GeoLOD"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),s.prototype.initialize.call(this),this._rootNode.addFieldInterest(this.rootGroup._children),this.rootGroup._children=this._rootNode,this.rootGroup.setPrivate(!0),this.rootGroup.setup(),this.rootInline._loadState.addInterest("set_rootLoadState__",this),this.child1Inline._loadState.addInterest("set_childLoadState__",this),this.child2Inline._loadState.addInterest("set_childLoadState__",this),this.child3Inline._loadState.addInterest("set_childLoadState__",this),this.child4Inline._loadState.addInterest("set_childLoadState__",this),this._rootUrl.addFieldInterest(this.rootInline._url),this._child1Url.addFieldInterest(this.child1Inline._url),this._child2Url.addFieldInterest(this.child2Inline._url),this._child3Url.addFieldInterest(this.child3Inline._url),this._child4Url.addFieldInterest(this.child4Inline._url),this.rootInline._load=!0,this.child1Inline._load=!1,this.child2Inline._load=!1,this.child3Inline._load=!1,this.child4Inline._load=!1,this.rootInline._url=this._rootUrl,this.child1Inline._url=this._child1Url,this.child2Inline._url=this._child2Url,this.child3Inline._url=this._child3Url,this.child4Inline._url=this._child4Url,this.rootInline.setup(),this.child1Inline.setup(),this.child2Inline.setup(),this.child3Inline.setup(),this.child4Inline.setup()},getBBox:function(e,t){if(this._bboxSize.getValue().equals(this.getDefaultBBoxSize())){switch(this.childrenLoaded?this._level_changed.getValue():0){case 0:return this._rootNode.length?this.rootGroup.getBBox(e,t):this.rootInline.getBBox(e,t);case 1:{const i=this.childBBox;return e.set(),e.add(this.child1Inline.getBBox(i,t)),e.add(this.child2Inline.getBBox(i,t)),e.add(this.child3Inline.getBBox(i,t)),e.add(this.child4Inline.getBBox(i,t)),e}}return e.set()}return e.set(this._bboxSize.getValue(),this._bboxCenter.getValue())},set_rootLoadState__:function(){0===this._level_changed.getValue()&&(this._rootNode.length||this.rootInline.checkLoadState()===r.COMPLETE_STATE&&(this._children=this.rootInline.getInternalScene().getRootNodes(),this.childrenLoaded=!1))},set_childLoadState__:function(){if(1===this._level_changed.getValue()){var e=0;if(this.child1Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child1Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child2Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child2Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child3Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child3Inline.checkLoadState()!==r.FAILED_STATE||++e,this.child4Inline.checkLoadState()!==r.COMPLETE_STATE&&this.child4Inline.checkLoadState()!==r.FAILED_STATE||++e,4===e){this.childrenLoaded=!0;var t=this._children;t.length=0;for(var i=0,n=(o=this.child1Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);for(i=0,n=(o=this.child2Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);for(i=0,n=(o=this.child3Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i]);var o;for(i=0,n=(o=this.child4Inline.getInternalScene().getRootNodes()).length;i<n;++i)t.push(o[i])}}},set_childCameraObject__:function(){this.setCameraObject(this.child1Inline.getCameraObject()||this.child2Inline.getCameraObject()||this.child3Inline.getCameraObject()||this.child4Inline.getCameraObject())},set_childPickableObject__:function(){this.setPickableObject(this.child1Inline.getPickableObject()||this.child2Inline.getPickableObject()||this.child3Inline.getPickableObject()||this.child4Inline.getPickableObject())},getLevel:function(e){return this.getDistance(e)<this._range.getValue()?1:0},getDistance:function(e){return e.translate(this.getCoord(this._center.getValue(),_)),e.origin.magnitude()},traverse:function(e,t){switch(e){case a.PICKING:var i=t.getBrowser().getPickingHierarchy();return i.push(this),this.traverseChildren(e,t),void i.pop();case a.DISPLAY:var n=this.getLevel(this.modelViewMatrix.assign(t.getModelViewMatrix().get()));if(n!==this._level_changed.getValue())switch(this._level_changed=n,n){case 0:this.child1Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child2Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child3Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child4Inline._isCameraObject.removeInterest("set_childCameraObject__",this),this.child1Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child2Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child3Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this.child4Inline._isPickableObject.removeInterest("set_childPickableObject__",this),this._rootNode.length?(this.rootGroup._isCameraObject.addFieldInterest(this._isCameraObject),this.rootGroup._isPickableObject.addFieldInterest(this._isPickableObject),this.setCameraObject(this.rootGroup.getCameraObject()),this.setPickableObject(this.rootGroup.getPickableObject()),this._children=this._rootNode,this.childrenLoaded=!1):this.rootInline.checkLoadState()==r.COMPLETE_STATE&&(this.rootInline._isCameraObject.addFieldInterest(this._isCameraObject),this.rootInline._isPickableObject.addFieldInterest(this._isPickableObject),this.setCameraObject(this.rootInline.getCameraObject()),this.setPickableObject(this.rootInline.getPickableObject()),this._children=this.rootInline.getInternalScene().getRootNodes(),this.childrenLoaded=!1),this.unload&&(this.child1Inline._load=!1,this.child2Inline._load=!1,this.child3Inline._load=!1,this.child4Inline._load=!1);break;case 1:this._rootNode.length?(this.rootGroup._isCameraObject.removeFieldInterest(this._isCameraObject),this.rootGroup._isPickableObject.removeFieldInterest(this._isPickableObject)):(this.rootInline._isCameraObject.removeFieldInterest(this._isCameraObject),this.rootInline._isPickableObject.removeFieldInterest(this._isPickableObject)),this.child1Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child2Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child3Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child4Inline._isCameraObject.addInterest("set_childCameraObject__",this),this.child1Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child2Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child3Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.child4Inline._isPickableObject.addInterest("set_childPickableObject__",this),this.set_childCameraObject__(),this.set_childPickableObject__(),this.child1Inline._load.getValue()?this.set_childLoadState__():(this.child1Inline._load=!0,this.child2Inline._load=!0,this.child3Inline._load=!0,this.child4Inline._load=!0)}return void this.traverseChildren(e,t);default:return void this.traverseChildren(e,t)}},traverseChildren:function(e,t){switch(this.childrenLoaded?this._level_changed.getValue():0){case 0:this._rootNode.length?this.rootGroup.traverse(e,t):this.rootInline.traverse(e,t);break;case 1:this.child1Inline.traverse(e,t),this.child2Inline.traverse(e,t),this.child3Inline.traverse(e,t),this.child4Inline.traverse(e,t)}}}),p})),t("x_ite/Components/Geospatial/GeoLocation",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformMatrix3DNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r){"use strict";var a=new r;function l(e){n.call(this,e),o.call(this,e),this.addType(s.GeoLocation)}return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"geoCoords",new e.SFVec3d),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.inputOutput,"visible",new e.SFBool(!0)),new t(s.inputOutput,"bboxDisplay",new e.SFBool),new t(s.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(s.initializeOnly,"bboxCenter",new e.SFVec3f),new t(s.inputOnly,"addChildren",new e.MFNode),new t(s.inputOnly,"removeChildren",new e.MFNode),new t(s.inputOutput,"children",new e.MFNode)]),getTypeName:function(){return"GeoLocation"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this.addInterest("eventsProcessed",this),this.eventsProcessed()},eventsProcessed:function(){this.setMatrix(this.getLocationMatrix(this._geoCoords.getValue(),a))}}),l})),t("x_ite/Components/Geospatial/GeoMetadata",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DInfoNode","x_ite/Components/Networking/X3DUrlObject","x_ite/Base/X3DConstants"],(function(e,t,i,n,o,s){"use strict";function r(e){n.call(this,e),o.call(this,e),this.addType(s.GeoMetadata)}return r.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:r,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"url",new e.MFString),new t(s.inputOutput,"load",new e.SFBool(!0)),new t(s.inputOutput,"autoRefresh",new e.SFTime),new t(s.inputOutput,"autoRefreshTimeLimit",new e.SFTime(3600)),new t(s.inputOutput,"summary",new e.MFString),new t(s.inputOutput,"data",new e.MFNode)]),getTypeName:function(){return"GeoMetadata"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this)},requestImmediateLoad:function(e=!0){},requestUnload:function(){},set_load__:function(){},set_url__:function(){}}),r})),t("x_ite/Components/Geospatial/GeoOrigin",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DNode","x_ite/Base/X3DConstants","x_ite/Browser/Geospatial/Geospatial"],(function(e,t,i,n,o,s){"use strict";function r(e){n.call(this,e),this.addType(o.GeoOrigin),this.radians=!1}return r.prototype=Object.assign(Object.create(n.prototype),{constructor:r,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(o.inputOutput,"metadata",new e.SFNode),new t(o.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(o.inputOutput,"geoCoords",new e.SFVec3d),new t(o.initializeOnly,"rotateYUp",new e.SFBool)]),getTypeName:function(){return"GeoOrigin"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"geoOrigin"},initialize:function(){n.prototype.initialize.call(this),this._geoSystem.addInterest("set_geoSystem__",this),this.set_geoSystem__()},set_geoSystem__:function(){this.referenceFrame=s.getReferenceFrame(this._geoSystem,this.radians)},getOrigin:function(e){return this.referenceFrame.convert(this._geoCoords.getValue(),e)}}),r})),t("x_ite/Components/Geospatial/GeoPositionInterpolator",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Interpolation/X3DInterpolatorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Browser/Geospatial/Geocentric","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";function l(e){n.call(this,e),o.call(this,e),this.addType(r.GeoPositionInterpolator),this._value_changed.setUnit("length"),this.geocentric=new s}return l.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:l,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.inputOnly,"set_fraction",new e.SFFloat),new t(r.inputOutput,"key",new e.MFFloat),new t(r.inputOutput,"keyValue",new e.MFVec3d),new t(r.outputOnly,"value_changed",new e.SFVec3d),new t(r.outputOnly,"geovalue_changed",new e.SFVec3d)]),keyValue0:new a(0,0,0),keyValue1:new a(0,0,0),geovalue:new a(0,0,0),value:new a(0,0,0),getTypeName:function(){return"GeoPositionInterpolator"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},setup:function(){o.prototype.initialize.call(this),n.prototype.setup.call(this)},initialize:function(){n.prototype.initialize.call(this),this._keyValue.addInterest("set_keyValue__",this)},set_keyValue__:function(){var t=this._key,i=this._keyValue;i.length<t.length&&i.resize(t.length,i.length?i[i.length-1]:new e.SFVec3f)},interpolate:function(e,t,i){this.getCoord(this._keyValue[e].getValue(),this.keyValue0),this.getCoord(this._keyValue[t].getValue(),this.keyValue1);var n=this.geocentric.slerp(this.keyValue0,this.keyValue1,i);this._geovalue_changed=this.getGeoCoord(n,this.geovalue),this._value_changed=n}}),l})),t("x_ite/Components/Geospatial/GeoProximitySensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/EnvironmentalSensor/X3DEnvironmentalSensorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Components/EnvironmentalSensor/ProximitySensor","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3"],(function(e,t,i,n,o,s,r,a){"use strict";var l=new a(0,0,0);function h(e){n.call(this,e),o.call(this,e),this.addType(r.GeoProximitySensor),this._position_changed.setUnit("length"),this._centerOfRotation_changed.setUnit("length"),this.proximitySensor=new s(e),this.setCameraObject(this.proximitySensor.getCameraObject()),this.setPickableObject(this.proximitySensor.getPickableObject())}return h.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:h,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(r.inputOutput,"metadata",new e.SFNode),new t(r.initializeOnly,"geoOrigin",new e.SFNode),new t(r.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(r.inputOutput,"enabled",new e.SFBool(!0)),new t(r.inputOutput,"size",new e.SFVec3f),new t(r.inputOutput,"center",new e.SFVec3f),new t(r.outputOnly,"isActive",new e.SFBool),new t(r.outputOnly,"enterTime",new e.SFTime),new t(r.outputOnly,"exitTime",new e.SFTime),new t(r.outputOnly,"geoCoord_changed",new e.SFVec3d),new t(r.outputOnly,"position_changed",new e.SFVec3f),new t(r.outputOnly,"orientation_changed",new e.SFRotation),new t(r.outputOnly,"centerOfRotation_changed",new e.SFVec3f)]),getTypeName:function(){return"GeoProximitySensor"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this._enabled.addFieldInterest(this.proximitySensor._enabled),this._size.addFieldInterest(this.proximitySensor._size),this._center.addFieldInterest(this.proximitySensor._center),this.proximitySensor._isCameraObject.addFieldInterest(this._isCameraObject),this.proximitySensor._isPickableObject.addFieldInterest(this._isPickableObject),this.proximitySensor._isActive.addFieldInterest(this._isActive),this.proximitySensor._enterTime.addFieldInterest(this._enterTime),this.proximitySensor._exitTime.addFieldInterest(this._exitTime),this.proximitySensor._position_changed.addFieldInterest(this._position_changed),this.proximitySensor._orientation_changed.addFieldInterest(this._orientation_changed),this.proximitySensor._centerOfRotation_changed.addFieldInterest(this._centerOfRotation_changed),this.proximitySensor._position_changed.addInterest("set_position__",this),this.proximitySensor._enabled=this._enabled,this.proximitySensor._size=this._size,this.proximitySensor._center=this._center,this.proximitySensor.setup()},set_position__:function(e){this._geoCoord_changed=this.getGeoCoord(this.proximitySensor._position_changed.getValue(),l)},traverse:function(e,t){this.proximitySensor.traverse(e,t)}}),h})),t("x_ite/Components/Geospatial/GeoTouchSensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/PointingDeviceSensor/X3DTouchSensorNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Vector3","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r,a){"use strict";var l=new a,h=new r(0,0,0);function d(e){n.call(this,e),o.call(this,e),this.addType(s.GeoTouchSensor),this._hitPoint_changed.setUnit("length")}return d.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:d,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"description",new e.SFString),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"enabled",new e.SFBool(!0)),new t(s.outputOnly,"hitTexCoord_changed",new e.SFVec2f),new t(s.outputOnly,"hitNormal_changed",new e.SFVec3f),new t(s.outputOnly,"hitPoint_changed",new e.SFVec3f),new t(s.outputOnly,"hitGeoCoord_changed",new e.SFVec3d),new t(s.outputOnly,"isOver",new e.SFBool),new t(s.outputOnly,"isActive",new e.SFBool),new t(s.outputOnly,"touchTime",new e.SFTime)]),getTypeName:function(){return"GeoTouchSensor"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this)},set_over__:function(e,t,i,o,s){if(n.prototype.set_over__.call(this,e,t,i,o,s),this._isOver.getValue()){var r=t.intersection;l.assign(i).inverse(),this._hitTexCoord_changed=r.texCoord,this._hitNormal_changed=i.multMatrixDir(r.normal.copy()).normalize(),this._hitPoint_changed=l.multVecMatrix(r.point.copy()),this._hitGeoCoord_changed=this.getGeoCoord(this._hitPoint_changed.getValue(),h)}}}),d})),t("x_ite/Components/Geospatial/GeoTransform",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformMatrix3DNode","x_ite/Components/Geospatial/X3DGeospatialObject","x_ite/Base/X3DConstants","standard/Math/Numbers/Matrix4"],(function(e,t,i,n,o,s,r){"use strict";var a=new r,l=new r;function h(e){n.call(this,e),o.call(this,e),this.addType(s.GeoTransform),this._translation.setUnit("length")}return h.prototype=Object.assign(Object.create(n.prototype),o.prototype,{constructor:h,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new i([new t(s.inputOutput,"metadata",new e.SFNode),new t(s.inputOutput,"translation",new e.SFVec3f),new t(s.inputOutput,"rotation",new e.SFRotation),new t(s.inputOutput,"scale",new e.SFVec3f(1,1,1)),new t(s.inputOutput,"scaleOrientation",new e.SFRotation),new t(s.initializeOnly,"geoOrigin",new e.SFNode),new t(s.initializeOnly,"geoSystem",new e.MFString("GD","WE")),new t(s.inputOutput,"geoCenter",new e.SFVec3d),new t(s.inputOutput,"visible",new e.SFBool(!0)),new t(s.inputOutput,"bboxDisplay",new e.SFBool),new t(s.initializeOnly,"bboxSize",new e.SFVec3f(-1,-1,-1)),new t(s.initializeOnly,"bboxCenter",new e.SFVec3f),new t(s.inputOnly,"addChildren",new e.MFNode),new t(s.inputOnly,"removeChildren",new e.MFNode),new t(s.inputOutput,"children",new e.MFNode)]),getTypeName:function(){return"GeoTransform"},getComponentName:function(){return"Geospatial"},getContainerField:function(){return"children"},initialize:function(){n.prototype.initialize.call(this),o.prototype.initialize.call(this),this.addInterest("eventsProcessed",this),this.eventsProcessed()},eventsProcessed:function(){this.getLocationMatrix(this._geoCenter.getValue(),l),a.set(this._translation.getValue(),this._rotation.getValue(),this._scale.getValue(),this._scaleOrientation.getValue()),this.setMatrix(a.multRight(l).multLeft(l.inverse()))}}),h})),t(i.getComponentUrl("geospatial"),["x_ite/Components","x_ite/Components/Geospatial/GeoCoordinate","x_ite/Components/Geospatial/GeoElevationGrid","x_ite/Components/Geospatial/GeoLOD","x_ite/Components/Geospatial/GeoLocation","x_ite/Components/Geospatial/GeoMetadata","x_ite/Components/Geospatial/GeoOrigin","x_ite/Components/Geospatial/GeoPositionInterpolator","x_ite/Components/Geospatial/GeoProximitySensor","x_ite/Components/Geospatial/GeoTouchSensor","x_ite/Components/Geospatial/GeoTransform","x_ite/Components/Geospatial/GeoViewpoint","x_ite/Components/Geospatial/X3DGeospatialObject"],(function(e,t,i,n,o,s,r,a,l,h,d,c,u){"use strict";e.addComponent({name:"Geospatial",types:{GeoCoordinate:t,GeoElevationGrid:i,GeoLOD:n,GeoLocation:o,GeoMetadata:s,GeoOrigin:r,GeoPositionInterpolator:a,GeoProximitySensor:l,GeoTouchSensor:h,GeoTransform:d,GeoViewpoint:c},abstractTypes:{X3DGeospatialObject:u}})}))}();
@@ -4,8 +4,9 @@
4
4
  var module = { }, exports, process;
5
5
 
6
6
  const
7
- define = window [Symbol .for ("X_ITE.X3D-5.0.3")] .define,
8
- require = window [Symbol .for ("X_ITE.X3D-5.0.3")] .require;
7
+ X3D = window [Symbol .for ("X_ITE.X3D-6.1.0")],
8
+ define = X3D .define,
9
+ require = X3D .require;
9
10
  /* -*- Mode: JavaScript; coding: utf-8; tab-width: 3; indent-tabs-mode: tab; c-basic-offset: 3 -*-
10
11
  *******************************************************************************
11
12
  *
@@ -363,103 +364,96 @@ function (Fields,
363
364
 
364
365
  return function (type, renderObject)
365
366
  {
366
- try
367
- {
368
- if (type !== TraverseType .CAMERA)
369
- return;
367
+ if (type !== TraverseType .CAMERA)
368
+ return;
370
369
 
371
- if (! this .skinCoordNode)
372
- return;
370
+ if (! this .skinCoordNode)
371
+ return;
373
372
 
374
- var
375
- jointNodes = this .jointNodes,
376
- skinNormalNode = this .skinNormalNode,
377
- skinCoordNode = this .skinCoordNode,
378
- restNormalNode = this .restNormalNode,
379
- restCoordNode = this .restCoordNode;
373
+ var
374
+ jointNodes = this .jointNodes,
375
+ skinNormalNode = this .skinNormalNode,
376
+ skinCoordNode = this .skinCoordNode,
377
+ restNormalNode = this .restNormalNode,
378
+ restCoordNode = this .restCoordNode;
380
379
 
381
- // Reset skin normals and coords.
380
+ // Reset skin normals and coords.
382
381
 
383
- if (skinNormalNode)
384
- skinNormalNode ._vector .assign (restNormalNode ._vector);
382
+ if (skinNormalNode)
383
+ skinNormalNode ._vector .assign (restNormalNode ._vector);
385
384
 
386
- skinCoordNode ._point .assign (restCoordNode ._point);
385
+ skinCoordNode ._point .assign (restCoordNode ._point);
387
386
 
388
- // Determine inverse model matrix of humanoid.
387
+ // Determine inverse model matrix of humanoid.
389
388
 
390
- invModelMatrix .assign (this .transformNode .getMatrix ()) .multRight (renderObject .getModelViewMatrix () .get ()) .inverse ();
389
+ invModelMatrix .assign (this .transformNode .getMatrix ()) .multRight (renderObject .getModelViewMatrix () .get ()) .inverse ();
391
390
 
392
- // Apply joint transformations.
391
+ // Apply joint transformations.
393
392
 
394
- for (var j = 0, jointNodesLength = jointNodes .length; j < jointNodesLength; ++ j)
395
- {
396
- var
397
- jointNode = jointNodes [j],
398
- skinCoordIndexLength = jointNode ._skinCoordIndex .length;
393
+ for (var j = 0, jointNodesLength = jointNodes .length; j < jointNodesLength; ++ j)
394
+ {
395
+ var
396
+ jointNode = jointNodes [j],
397
+ skinCoordIndexLength = jointNode ._skinCoordIndex .length;
399
398
 
400
- if (skinCoordIndexLength === 0)
401
- continue;
399
+ if (skinCoordIndexLength === 0)
400
+ continue;
402
401
 
403
- var
404
- jointMatrix = jointNode .getModelMatrix () .multRight (invModelMatrix),
405
- displacerNodes = jointNode .getDisplacers ();
402
+ var
403
+ jointMatrix = jointNode .getModelMatrix () .multRight (invModelMatrix),
404
+ displacerNodes = jointNode .getDisplacers ();
406
405
 
407
- for (var d = 0, displacerNodesLength = displacerNodes .length; d < displacerNodesLength; ++ d)
406
+ for (var d = 0, displacerNodesLength = displacerNodes .length; d < displacerNodesLength; ++ d)
407
+ {
408
+ var
409
+ displacerNode = displacerNodes [d],
410
+ coordIndex = displacerNode ._coordIndex .getValue (),
411
+ coordIndexLength = displacerNode ._coordIndex .length,
412
+ weight = displacerNode ._weight .getValue (),
413
+ displacements = displacerNode ._displacements .getValue (),
414
+ displacementsLength = displacerNode ._displacements .length;
415
+
416
+ for (var i = 0; i < coordIndexLength; ++ i)
408
417
  {
409
418
  var
410
- displacerNode = displacerNodes [d],
411
- coordIndex = displacerNode ._coordIndex .getValue (),
412
- coordIndexLength = displacerNode ._coordIndex .length,
413
- weight = displacerNode ._weight .getValue (),
414
- displacements = displacerNode ._displacements .getValue (),
415
- displacementsLength = displacerNode ._displacements .length;
416
-
417
- for (var i = 0; i < coordIndexLength; ++ i)
418
- {
419
- var
420
- i3 = i * 3,
421
- index = coordIndex [i],
422
- displacement = i < displacementsLength ? point .set (displacements [i3], displacements [i3 + 1], displacements [i3 + 2]) : point .assign (Vector3 .Zero);
423
-
424
- skinCoordNode .get1Point (index, skin);
425
- jointMatrix .multDirMatrix (displacement) .multiply (weight) .add (skin);
426
- skinCoordNode .set1Point (index, displacement);
427
- }
419
+ i3 = i * 3,
420
+ index = coordIndex [i],
421
+ displacement = i < displacementsLength ? point .set (displacements [i3], displacements [i3 + 1], displacements [i3 + 2]) : point .assign (Vector3 .Zero);
422
+
423
+ skinCoordNode .get1Point (index, skin);
424
+ jointMatrix .multDirMatrix (displacement) .multiply (weight) .add (skin);
425
+ skinCoordNode .set1Point (index, displacement);
428
426
  }
427
+ }
429
428
 
429
+ var
430
+ normalMatrix = skinNormalNode ? jointMatrix .submatrix .transpose () .inverse () : null,
431
+ skinCoordIndex = jointNode ._skinCoordIndex .getValue (),
432
+ skinCoordWeight = jointNode ._skinCoordWeight .getValue (),
433
+ skinCoordWeightLength = jointNode ._skinCoordWeight .length;
434
+
435
+ for (var i = 0; i < skinCoordIndexLength; ++ i)
436
+ {
430
437
  var
431
- normalMatrix = skinNormalNode ? jointMatrix .submatrix .transpose () .inverse () : null,
432
- skinCoordIndex = jointNode ._skinCoordIndex .getValue (),
433
- skinCoordWeight = jointNode ._skinCoordWeight .getValue (),
434
- skinCoordWeightLength = jointNode ._skinCoordWeight .length;
438
+ index = skinCoordIndex [i],
439
+ weight = i < skinCoordWeightLength ? skinCoordWeight [i] : 1;
435
440
 
436
- for (var i = 0; i < skinCoordIndexLength; ++ i)
441
+ if (skinNormalNode)
437
442
  {
438
- var
439
- index = skinCoordIndex [i],
440
- weight = i < skinCoordWeightLength ? skinCoordWeight [i] : 1;
441
-
442
- if (skinNormalNode)
443
- {
444
- rest .assign (restNormalNode .get1Vector (index, vector));
445
- skinNormalNode .get1Vector (index, skin);
446
- normalMatrix .multVecMatrix (vector) .subtract (rest) .multiply (weight) .add (skin);
447
- skinNormalNode .set1Vector (index, vector);
448
- // Should the normals be normalzed at end, or let it the shader do?
449
- }
450
-
451
- //skin += (rest * J - rest) * weight
452
- rest .assign (restCoordNode .get1Point (index, point));
453
- skinCoordNode .get1Point (index, skin);
454
- jointMatrix .multVecMatrix (point) .subtract (rest) .multiply (weight) .add (skin);
455
- skinCoordNode .set1Point (index, point);
443
+ rest .assign (restNormalNode .get1Vector (index, vector));
444
+ skinNormalNode .get1Vector (index, skin);
445
+ normalMatrix .multVecMatrix (vector) .subtract (rest) .multiply (weight) .add (skin);
446
+ skinNormalNode .set1Vector (index, vector);
447
+ // Should the normals be normalized at end, or let it the shader do?
456
448
  }
449
+
450
+ //skin += (rest * J - rest) * weight
451
+ rest .assign (restCoordNode .get1Point (index, point));
452
+ skinCoordNode .get1Point (index, skin);
453
+ jointMatrix .multVecMatrix (point) .subtract (rest) .multiply (weight) .add (skin);
454
+ skinCoordNode .set1Point (index, point);
457
455
  }
458
456
  }
459
- catch (error)
460
- {
461
- console .error (error);
462
- }
463
457
  };
464
458
  })(),
465
459
  });
@@ -1 +1 @@
1
- !function(){const t=window[Symbol.for("X_ITE.X3D-5.0.3")].define,e=window[Symbol.for("X_ITE.X3D-5.0.3")].require;t("x_ite/Components/HAnim/HAnimDisplacer",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DGeometricPropertyNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimDisplacer),this._displacements.setUnit("length")}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"coordIndex",new t.MFInt32),new e(o.inputOutput,"weight",new t.SFFloat),new e(o.inputOutput,"displacements",new t.MFVec3f)]),getTypeName:function(){return"HAnimDisplacer"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"displacers"}}),s})),t("x_ite/Components/HAnim/HAnimHumanoid",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Components/Grouping/Group","x_ite/Components/Grouping/Transform","x_ite/Components/Grouping/X3DBoundedObject","x_ite/Rendering/TraverseType","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Numbers/Matrix4","standard/Math/Numbers/Vector3"],(function(t,e,n,i,o,s,r,a,u,d,l,p){"use strict";function c(t){i.call(this,t),r.call(this,t),this.addType(u.HAnimHumanoid),this._translation.setUnit("length"),this._center.setUnit("length"),this._bboxSize.setUnit("length"),this._bboxCenter.setUnit("length"),this.viewpointsNode=new o(t),this.skeletonNode=new o(t),this.skinNode=new o(t),this.transformNode=new s(t),this.jointNodes=[],this.skinNormalNode=null,this.skinCoordNode=null,this.restNormalNode=null,this.restCoordNode=null}var m,w,h,_,f;return c.prototype=Object.assign(Object.create(i.prototype),r.prototype,{constructor:c,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(u.inputOutput,"metadata",new t.SFNode),new e(u.inputOutput,"name",new t.SFString),new e(u.inputOutput,"version",new t.SFString),new e(u.inputOutput,"info",new t.MFString),new e(u.inputOutput,"translation",new t.SFVec3f),new e(u.inputOutput,"rotation",new t.SFRotation),new e(u.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(u.inputOutput,"scaleOrientation",new t.SFRotation),new e(u.inputOutput,"center",new t.SFVec3f),new e(u.inputOutput,"visible",new t.SFBool(!0)),new e(u.inputOutput,"bboxDisplay",new t.SFBool),new e(u.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(u.initializeOnly,"bboxCenter",new t.SFVec3f),new e(u.inputOutput,"viewpoints",new t.MFNode),new e(u.inputOutput,"sites",new t.MFNode),new e(u.inputOutput,"joints",new t.MFNode),new e(u.inputOutput,"segments",new t.MFNode),new e(u.inputOutput,"motions",new t.MFNode),new e(u.inputOutput,"skeleton",new t.MFNode),new e(u.inputOutput,"skinNormal",new t.SFNode),new e(u.inputOutput,"skinCoord",new t.SFNode),new e(u.inputOutput,"skin",new t.MFNode)]),getTypeName:function(){return"HAnimHumanoid"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this),r.prototype.initialize.call(this),this.viewpointsNode.setAllowedTypes(u.HAnimSite),this.skeletonNode.setAllowedTypes(u.HAnimJoint,u.HAnimSite),this._viewpoints.addFieldInterest(this.viewpointsNode._children),this._skeleton.addFieldInterest(this.skeletonNode._children),this._skin.addFieldInterest(this.skinNode._children),this.viewpointsNode._children=this._viewpoints,this.skeletonNode._children=this._skeleton,this.skinNode._children=this._skin,this.viewpointsNode.setPrivate(!0),this.skeletonNode.setPrivate(!0),this.skinNode.setPrivate(!0),this._translation.addFieldInterest(this.transformNode._translation),this._rotation.addFieldInterest(this.transformNode._rotation),this._scale.addFieldInterest(this.transformNode._scale),this._scaleOrientation.addFieldInterest(this.transformNode._scaleOrientation),this._center.addFieldInterest(this.transformNode._center),this._bboxSize.addFieldInterest(this.transformNode._bboxSize),this._bboxCenter.addFieldInterest(this.transformNode._bboxCenter),this.transformNode._translation=this._translation,this.transformNode._rotation=this._rotation,this.transformNode._scale=this._scale,this.transformNode._scaleOrientation=this._scaleOrientation,this.transformNode._center=this._center,this.transformNode._bboxSize=this._bboxSize,this.transformNode._bboxCenter=this._bboxCenter,this.transformNode._children=[this.viewpointsNode,this.skeletonNode,this.skinNode],this.transformNode._isCameraObject.addFieldInterest(this._isCameraObject),this.transformNode._isPickableObject.addFieldInterest(this._isPickableObject),this.viewpointsNode.setup(),this.skeletonNode.setup(),this.skinNode.setup(),this.transformNode.setup(),this.setCameraObject(this.transformNode.getCameraObject()),this.setPickableObject(this.transformNode.getPickableObject()),this._joints.addInterest("set_joints__",this),this._skinNormal.addInterest("set_skinNormal__",this),this._skinCoord.addInterest("set_skinCoord__",this),this.set_joints__(),this.set_skinNormal__(),this.set_skinCoord__()},getBBox:function(t,e){return this.transformNode.getBBox(t,e)},set_joints__:function(){var t=this.jointNodes;t.length=0;for(var e=0,n=this._joints.length;e<n;++e){var i=d(u.HAnimJoint,this._joints[e]);i&&t.push(i)}},set_skinNormal__:function(){this.restNormalNode=null,this.skinNormalNode=d(u.X3DNormalNode,this._skinNormal),this.skinNormalNode&&(this.restNormalNode=this.skinNormalNode.copy())},set_skinCoord__:function(){this.restCoordNode=null,this.skinCoordNode=d(u.X3DCoordinateNode,this._skinCoord),this.skinCoordNode&&(this.restCoordNode=this.skinCoordNode.copy())},traverse:function(t,e){this.transformNode.traverse(t,e),this.skinning(t,e)},skinning:(m=new l,w=new p(0,0,0),h=new p(0,0,0),_=new p(0,0,0),f=new p(0,0,0),function(t,e){try{if(t!==a.CAMERA)return;if(!this.skinCoordNode)return;var n=this.jointNodes,i=this.skinNormalNode,o=this.skinCoordNode,s=this.restNormalNode,r=this.restCoordNode;i&&i._vector.assign(s._vector),o._point.assign(r._point),m.assign(this.transformNode.getMatrix()).multRight(e.getModelViewMatrix().get()).inverse();for(var u=0,d=n.length;u<d;++u){var l=n[u],c=l._skinCoordIndex.length;if(0!==c){for(var N=l.getModelMatrix().multRight(m),F=l.getDisplacers(),O=0,g=F.length;O<g;++O)for(var S=F[O],x=S._coordIndex.getValue(),C=S._coordIndex.length,b=S._weight.getValue(),y=S._displacements.getValue(),A=S._displacements.length,D=0;D<C;++D){var M=3*D,H=x[D],k=D<A?f.set(y[M],y[M+1],y[M+2]):f.assign(p.Zero);o.get1Point(H,_),N.multDirMatrix(k).multiply(b).add(_),o.set1Point(H,k)}var v=i?N.submatrix.transpose().inverse():null,B=l._skinCoordIndex.getValue(),I=l._skinCoordWeight.getValue(),T=l._skinCoordWeight.length;for(D=0;D<c;++D)H=B[D],b=D<T?I[D]:1,i&&(h.assign(s.get1Vector(H,w)),i.get1Vector(H,_),v.multVecMatrix(w).subtract(h).multiply(b).add(_),i.set1Vector(H,w)),h.assign(r.get1Point(H,f)),o.get1Point(H,_),N.multVecMatrix(f).subtract(h).multiply(b).add(_),o.set1Point(H,f)}}}catch(t){console.error(t)}})}),c})),t("x_ite/Components/HAnim/HAnimJoint",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformNode","x_ite/Rendering/TraverseType","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Numbers/Matrix4"],(function(t,e,n,i,o,s,r,a){"use strict";function u(t){i.call(this,t),this.addType(s.HAnimJoint),this.setAllowedTypes(s.HAnimJoint,s.HAnimSegment,s.HAnimSite),this.displacerNodes=[],this.modelMatrix=new a}return u.prototype=Object.assign(Object.create(i.prototype),{constructor:u,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(s.inputOutput,"metadata",new t.SFNode),new e(s.inputOutput,"name",new t.SFString),new e(s.inputOutput,"translation",new t.SFVec3f),new e(s.inputOutput,"rotation",new t.SFRotation),new e(s.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(s.inputOutput,"scaleOrientation",new t.SFRotation),new e(s.inputOutput,"center",new t.SFVec3f),new e(s.inputOutput,"llimit",new t.MFFloat),new e(s.inputOutput,"ulimit",new t.MFFloat),new e(s.inputOutput,"limitOrientation",new t.SFRotation),new e(s.inputOutput,"stiffness",new t.MFFloat(0,0,0)),new e(s.inputOutput,"skinCoordIndex",new t.MFInt32),new e(s.inputOutput,"skinCoordWeight",new t.MFFloat),new e(s.inputOutput,"displacers",new t.MFNode),new e(s.inputOutput,"visible",new t.SFBool(!0)),new e(s.inputOutput,"bboxDisplay",new t.SFBool),new e(s.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(s.initializeOnly,"bboxCenter",new t.SFVec3f),new e(s.inputOnly,"addChildren",new t.MFNode),new e(s.inputOnly,"removeChildren",new t.MFNode),new e(s.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimJoint"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this),this._displacers.addInterest("set_displacers__",this),this.set_displacers__()},setCameraObject:function(t){i.prototype.setCameraObject.call(this,t||!!this._skinCoordIndex.length)},getModelMatrix:function(){return this.modelMatrix},getDisplacers:function(){return this.displacerNodes},set_displacers__:function(){const t=this.displacerNodes;t.length=0;for(var e=0,n=this._displacers.length;e<n;++e){const n=r(s.HAnimDisplacer,this._displacers[e]);n&&t.push(n)}},getTraverse:function(){const t=i.prototype.getTraverse();function e(e,n){e===o.CAMERA&&this.modelMatrix.assign(this.getMatrix()).multRight(n.getModelViewMatrix().get()),t.call(this,e,n)}return function(){return this._skinCoordIndex.length?e:t}}(),getGroupTraverse:function(){const t=i.prototype.getGroupTraverse();function e(e,n){e===o.CAMERA&&this.modelMatrix.assign(n.getModelViewMatrix().get()),t.call(this,e,n)}return function(){return this._skinCoordIndex.length?e:t}}()}),u})),t("x_ite/Components/HAnim/HAnimMotion",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimMotion)}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"description",new t.SFString),new e(o.inputOutput,"enabled",new t.SFBool(!0)),new e(o.inputOnly,"next",new t.SFBool),new e(o.inputOnly,"previous",new t.SFBool),new e(o.inputOutput,"frameDuration",new t.SFTime(.1)),new e(o.inputOutput,"frameIncrement",new t.SFInt32(1)),new e(o.inputOutput,"frameIndex",new t.SFInt32(0)),new e(o.inputOutput,"loop",new t.SFBool(!1)),new e(o.inputOutput,"channels",new t.SFString),new e(o.inputOutput,"channelsEnabled",new t.MFBool),new e(o.inputOutput,"joints",new t.MFString),new e(o.inputOutput,"loa",new t.SFInt32(-1)),new e(o.inputOutput,"values",new t.MFFloat),new e(o.outputOnly,"cycleTime",new t.SFTime),new e(o.outputOnly,"elapsedTime",new t.SFTime),new e(o.outputOnly,"frameCount",new t.SFInt32)]),getTypeName:function(){return"HAnimMotion"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this)}}),s})),t("x_ite/Components/HAnim/HAnimSegment",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DGroupingNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimSegment),this._mass.setUnit("mass")}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"mass",new t.SFFloat),new e(o.inputOutput,"centerOfMass",new t.SFVec3f),new e(o.inputOutput,"momentsOfInertia",new t.MFFloat(0,0,0,0,0,0,0,0,0)),new e(o.inputOutput,"displacers",new t.MFNode),new e(o.inputOutput,"coord",new t.SFNode),new e(o.inputOutput,"visible",new t.SFBool(!0)),new e(o.inputOutput,"bboxDisplay",new t.SFBool),new e(o.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(o.initializeOnly,"bboxCenter",new t.SFVec3f),new e(o.inputOnly,"addChildren",new t.MFNode),new e(o.inputOnly,"removeChildren",new t.MFNode),new e(o.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimSegment"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"}}),s})),t("x_ite/Components/HAnim/HAnimSite",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimSite)}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"translation",new t.SFVec3f),new e(o.inputOutput,"rotation",new t.SFRotation),new e(o.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(o.inputOutput,"scaleOrientation",new t.SFRotation),new e(o.inputOutput,"center",new t.SFVec3f),new e(o.inputOutput,"visible",new t.SFBool(!0)),new e(o.inputOutput,"bboxDisplay",new t.SFBool),new e(o.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(o.initializeOnly,"bboxCenter",new t.SFVec3f),new e(o.inputOnly,"addChildren",new t.MFNode),new e(o.inputOnly,"removeChildren",new t.MFNode),new e(o.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimSite"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"}}),s})),t(e.getComponentUrl("h-anim"),["x_ite/Components","x_ite/Components/HAnim/HAnimDisplacer","x_ite/Components/HAnim/HAnimHumanoid","x_ite/Components/HAnim/HAnimJoint","x_ite/Components/HAnim/HAnimMotion","x_ite/Components/HAnim/HAnimSegment","x_ite/Components/HAnim/HAnimSite"],(function(t,e,n,i,o,s,r){"use strict";t.addComponent({name:"HAnim",types:{HAnimDisplacer:e,HAnimHumanoid:n,HAnimJoint:i,HAnimMotion:o,HAnimSegment:s,HAnimSite:r},abstractTypes:{}})}))}();
1
+ !function(){const t=window[Symbol.for("X_ITE.X3D-6.1.0")],e=t.define,n=t.require;e("x_ite/Components/HAnim/HAnimDisplacer",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Rendering/X3DGeometricPropertyNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimDisplacer),this._displacements.setUnit("length")}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"coordIndex",new t.MFInt32),new e(o.inputOutput,"weight",new t.SFFloat),new e(o.inputOutput,"displacements",new t.MFVec3f)]),getTypeName:function(){return"HAnimDisplacer"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"displacers"}}),s})),e("x_ite/Components/HAnim/HAnimHumanoid",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Components/Grouping/Group","x_ite/Components/Grouping/Transform","x_ite/Components/Grouping/X3DBoundedObject","x_ite/Rendering/TraverseType","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Numbers/Matrix4","standard/Math/Numbers/Vector3"],(function(t,e,n,i,o,s,r,a,u,d,l,p){"use strict";function c(t){i.call(this,t),r.call(this,t),this.addType(u.HAnimHumanoid),this._translation.setUnit("length"),this._center.setUnit("length"),this._bboxSize.setUnit("length"),this._bboxCenter.setUnit("length"),this.viewpointsNode=new o(t),this.skeletonNode=new o(t),this.skinNode=new o(t),this.transformNode=new s(t),this.jointNodes=[],this.skinNormalNode=null,this.skinCoordNode=null,this.restNormalNode=null,this.restCoordNode=null}var m,w,h,_,f;return c.prototype=Object.assign(Object.create(i.prototype),r.prototype,{constructor:c,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(u.inputOutput,"metadata",new t.SFNode),new e(u.inputOutput,"name",new t.SFString),new e(u.inputOutput,"version",new t.SFString),new e(u.inputOutput,"info",new t.MFString),new e(u.inputOutput,"translation",new t.SFVec3f),new e(u.inputOutput,"rotation",new t.SFRotation),new e(u.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(u.inputOutput,"scaleOrientation",new t.SFRotation),new e(u.inputOutput,"center",new t.SFVec3f),new e(u.inputOutput,"visible",new t.SFBool(!0)),new e(u.inputOutput,"bboxDisplay",new t.SFBool),new e(u.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(u.initializeOnly,"bboxCenter",new t.SFVec3f),new e(u.inputOutput,"viewpoints",new t.MFNode),new e(u.inputOutput,"sites",new t.MFNode),new e(u.inputOutput,"joints",new t.MFNode),new e(u.inputOutput,"segments",new t.MFNode),new e(u.inputOutput,"motions",new t.MFNode),new e(u.inputOutput,"skeleton",new t.MFNode),new e(u.inputOutput,"skinNormal",new t.SFNode),new e(u.inputOutput,"skinCoord",new t.SFNode),new e(u.inputOutput,"skin",new t.MFNode)]),getTypeName:function(){return"HAnimHumanoid"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this),r.prototype.initialize.call(this),this.viewpointsNode.setAllowedTypes(u.HAnimSite),this.skeletonNode.setAllowedTypes(u.HAnimJoint,u.HAnimSite),this._viewpoints.addFieldInterest(this.viewpointsNode._children),this._skeleton.addFieldInterest(this.skeletonNode._children),this._skin.addFieldInterest(this.skinNode._children),this.viewpointsNode._children=this._viewpoints,this.skeletonNode._children=this._skeleton,this.skinNode._children=this._skin,this.viewpointsNode.setPrivate(!0),this.skeletonNode.setPrivate(!0),this.skinNode.setPrivate(!0),this._translation.addFieldInterest(this.transformNode._translation),this._rotation.addFieldInterest(this.transformNode._rotation),this._scale.addFieldInterest(this.transformNode._scale),this._scaleOrientation.addFieldInterest(this.transformNode._scaleOrientation),this._center.addFieldInterest(this.transformNode._center),this._bboxSize.addFieldInterest(this.transformNode._bboxSize),this._bboxCenter.addFieldInterest(this.transformNode._bboxCenter),this.transformNode._translation=this._translation,this.transformNode._rotation=this._rotation,this.transformNode._scale=this._scale,this.transformNode._scaleOrientation=this._scaleOrientation,this.transformNode._center=this._center,this.transformNode._bboxSize=this._bboxSize,this.transformNode._bboxCenter=this._bboxCenter,this.transformNode._children=[this.viewpointsNode,this.skeletonNode,this.skinNode],this.transformNode._isCameraObject.addFieldInterest(this._isCameraObject),this.transformNode._isPickableObject.addFieldInterest(this._isPickableObject),this.viewpointsNode.setup(),this.skeletonNode.setup(),this.skinNode.setup(),this.transformNode.setup(),this.setCameraObject(this.transformNode.getCameraObject()),this.setPickableObject(this.transformNode.getPickableObject()),this._joints.addInterest("set_joints__",this),this._skinNormal.addInterest("set_skinNormal__",this),this._skinCoord.addInterest("set_skinCoord__",this),this.set_joints__(),this.set_skinNormal__(),this.set_skinCoord__()},getBBox:function(t,e){return this.transformNode.getBBox(t,e)},set_joints__:function(){var t=this.jointNodes;t.length=0;for(var e=0,n=this._joints.length;e<n;++e){var i=d(u.HAnimJoint,this._joints[e]);i&&t.push(i)}},set_skinNormal__:function(){this.restNormalNode=null,this.skinNormalNode=d(u.X3DNormalNode,this._skinNormal),this.skinNormalNode&&(this.restNormalNode=this.skinNormalNode.copy())},set_skinCoord__:function(){this.restCoordNode=null,this.skinCoordNode=d(u.X3DCoordinateNode,this._skinCoord),this.skinCoordNode&&(this.restCoordNode=this.skinCoordNode.copy())},traverse:function(t,e){this.transformNode.traverse(t,e),this.skinning(t,e)},skinning:(m=new l,w=new p(0,0,0),h=new p(0,0,0),_=new p(0,0,0),f=new p(0,0,0),function(t,e){if(t===a.CAMERA&&this.skinCoordNode){var n=this.jointNodes,i=this.skinNormalNode,o=this.skinCoordNode,s=this.restNormalNode,r=this.restCoordNode;i&&i._vector.assign(s._vector),o._point.assign(r._point),m.assign(this.transformNode.getMatrix()).multRight(e.getModelViewMatrix().get()).inverse();for(var u=0,d=n.length;u<d;++u){var l=n[u],c=l._skinCoordIndex.length;if(0!==c){for(var N=l.getModelMatrix().multRight(m),F=l.getDisplacers(),O=0,g=F.length;O<g;++O)for(var S=F[O],x=S._coordIndex.getValue(),C=S._coordIndex.length,b=S._weight.getValue(),y=S._displacements.getValue(),A=S._displacements.length,M=0;M<C;++M){var D=3*M,H=x[M],k=M<A?f.set(y[D],y[D+1],y[D+2]):f.assign(p.Zero);o.get1Point(H,_),N.multDirMatrix(k).multiply(b).add(_),o.set1Point(H,k)}var v=i?N.submatrix.transpose().inverse():null,B=l._skinCoordIndex.getValue(),I=l._skinCoordWeight.getValue(),T=l._skinCoordWeight.length;for(M=0;M<c;++M)H=B[M],b=M<T?I[M]:1,i&&(h.assign(s.get1Vector(H,w)),i.get1Vector(H,_),v.multVecMatrix(w).subtract(h).multiply(b).add(_),i.set1Vector(H,w)),h.assign(r.get1Point(H,f)),o.get1Point(H,_),N.multVecMatrix(f).subtract(h).multiply(b).add(_),o.set1Point(H,f)}}}})}),c})),e("x_ite/Components/HAnim/HAnimJoint",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformNode","x_ite/Rendering/TraverseType","x_ite/Base/X3DConstants","x_ite/Base/X3DCast","standard/Math/Numbers/Matrix4"],(function(t,e,n,i,o,s,r,a){"use strict";function u(t){i.call(this,t),this.addType(s.HAnimJoint),this.setAllowedTypes(s.HAnimJoint,s.HAnimSegment,s.HAnimSite),this.displacerNodes=[],this.modelMatrix=new a}return u.prototype=Object.assign(Object.create(i.prototype),{constructor:u,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(s.inputOutput,"metadata",new t.SFNode),new e(s.inputOutput,"name",new t.SFString),new e(s.inputOutput,"translation",new t.SFVec3f),new e(s.inputOutput,"rotation",new t.SFRotation),new e(s.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(s.inputOutput,"scaleOrientation",new t.SFRotation),new e(s.inputOutput,"center",new t.SFVec3f),new e(s.inputOutput,"llimit",new t.MFFloat),new e(s.inputOutput,"ulimit",new t.MFFloat),new e(s.inputOutput,"limitOrientation",new t.SFRotation),new e(s.inputOutput,"stiffness",new t.MFFloat(0,0,0)),new e(s.inputOutput,"skinCoordIndex",new t.MFInt32),new e(s.inputOutput,"skinCoordWeight",new t.MFFloat),new e(s.inputOutput,"displacers",new t.MFNode),new e(s.inputOutput,"visible",new t.SFBool(!0)),new e(s.inputOutput,"bboxDisplay",new t.SFBool),new e(s.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(s.initializeOnly,"bboxCenter",new t.SFVec3f),new e(s.inputOnly,"addChildren",new t.MFNode),new e(s.inputOnly,"removeChildren",new t.MFNode),new e(s.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimJoint"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this),this._displacers.addInterest("set_displacers__",this),this.set_displacers__()},setCameraObject:function(t){i.prototype.setCameraObject.call(this,t||!!this._skinCoordIndex.length)},getModelMatrix:function(){return this.modelMatrix},getDisplacers:function(){return this.displacerNodes},set_displacers__:function(){const t=this.displacerNodes;t.length=0;for(var e=0,n=this._displacers.length;e<n;++e){const n=r(s.HAnimDisplacer,this._displacers[e]);n&&t.push(n)}},getTraverse:function(){const t=i.prototype.getTraverse();function e(e,n){e===o.CAMERA&&this.modelMatrix.assign(this.getMatrix()).multRight(n.getModelViewMatrix().get()),t.call(this,e,n)}return function(){return this._skinCoordIndex.length?e:t}}(),getGroupTraverse:function(){const t=i.prototype.getGroupTraverse();function e(e,n){e===o.CAMERA&&this.modelMatrix.assign(n.getModelViewMatrix().get()),t.call(this,e,n)}return function(){return this._skinCoordIndex.length?e:t}}()}),u})),e("x_ite/Components/HAnim/HAnimMotion",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Core/X3DChildNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimMotion)}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"description",new t.SFString),new e(o.inputOutput,"enabled",new t.SFBool(!0)),new e(o.inputOnly,"next",new t.SFBool),new e(o.inputOnly,"previous",new t.SFBool),new e(o.inputOutput,"frameDuration",new t.SFTime(.1)),new e(o.inputOutput,"frameIncrement",new t.SFInt32(1)),new e(o.inputOutput,"frameIndex",new t.SFInt32(0)),new e(o.inputOutput,"loop",new t.SFBool(!1)),new e(o.inputOutput,"channels",new t.SFString),new e(o.inputOutput,"channelsEnabled",new t.MFBool),new e(o.inputOutput,"joints",new t.MFString),new e(o.inputOutput,"loa",new t.SFInt32(-1)),new e(o.inputOutput,"values",new t.MFFloat),new e(o.outputOnly,"cycleTime",new t.SFTime),new e(o.outputOnly,"elapsedTime",new t.SFTime),new e(o.outputOnly,"frameCount",new t.SFInt32)]),getTypeName:function(){return"HAnimMotion"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"},initialize:function(){i.prototype.initialize.call(this)}}),s})),e("x_ite/Components/HAnim/HAnimSegment",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DGroupingNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimSegment),this._mass.setUnit("mass")}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"mass",new t.SFFloat),new e(o.inputOutput,"centerOfMass",new t.SFVec3f),new e(o.inputOutput,"momentsOfInertia",new t.MFFloat(0,0,0,0,0,0,0,0,0)),new e(o.inputOutput,"displacers",new t.MFNode),new e(o.inputOutput,"coord",new t.SFNode),new e(o.inputOutput,"visible",new t.SFBool(!0)),new e(o.inputOutput,"bboxDisplay",new t.SFBool),new e(o.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(o.initializeOnly,"bboxCenter",new t.SFVec3f),new e(o.inputOnly,"addChildren",new t.MFNode),new e(o.inputOnly,"removeChildren",new t.MFNode),new e(o.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimSegment"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"}}),s})),e("x_ite/Components/HAnim/HAnimSite",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/Grouping/X3DTransformNode","x_ite/Base/X3DConstants"],(function(t,e,n,i,o){"use strict";function s(t){i.call(this,t),this.addType(o.HAnimSite)}return s.prototype=Object.assign(Object.create(i.prototype),{constructor:s,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new n([new e(o.inputOutput,"metadata",new t.SFNode),new e(o.inputOutput,"name",new t.SFString),new e(o.inputOutput,"translation",new t.SFVec3f),new e(o.inputOutput,"rotation",new t.SFRotation),new e(o.inputOutput,"scale",new t.SFVec3f(1,1,1)),new e(o.inputOutput,"scaleOrientation",new t.SFRotation),new e(o.inputOutput,"center",new t.SFVec3f),new e(o.inputOutput,"visible",new t.SFBool(!0)),new e(o.inputOutput,"bboxDisplay",new t.SFBool),new e(o.initializeOnly,"bboxSize",new t.SFVec3f(-1,-1,-1)),new e(o.initializeOnly,"bboxCenter",new t.SFVec3f),new e(o.inputOnly,"addChildren",new t.MFNode),new e(o.inputOnly,"removeChildren",new t.MFNode),new e(o.inputOutput,"children",new t.MFNode)]),getTypeName:function(){return"HAnimSite"},getComponentName:function(){return"HAnim"},getContainerField:function(){return"children"}}),s})),e(n.getComponentUrl("h-anim"),["x_ite/Components","x_ite/Components/HAnim/HAnimDisplacer","x_ite/Components/HAnim/HAnimHumanoid","x_ite/Components/HAnim/HAnimJoint","x_ite/Components/HAnim/HAnimMotion","x_ite/Components/HAnim/HAnimSegment","x_ite/Components/HAnim/HAnimSite"],(function(t,e,n,i,o,s,r){"use strict";t.addComponent({name:"HAnim",types:{HAnimDisplacer:e,HAnimHumanoid:n,HAnimJoint:i,HAnimMotion:o,HAnimSegment:s,HAnimSite:r},abstractTypes:{}})}))}();
@@ -4,8 +4,9 @@
4
4
  var module = { }, exports, process;
5
5
 
6
6
  const
7
- define = window [Symbol .for ("X_ITE.X3D-5.0.3")] .define,
8
- require = window [Symbol .for ("X_ITE.X3D-5.0.3")] .require;
7
+ X3D = window [Symbol .for ("X_ITE.X3D-6.1.0")],
8
+ define = X3D .define,
9
+ require = X3D .require;
9
10
  /* -*- Mode: JavaScript; coding: utf-8; tab-width: 3; indent-tabs-mode: tab; c-basic-offset: 3 -*-
10
11
  *******************************************************************************
11
12
  *
@@ -842,7 +843,7 @@ function (Components,
842
843
  {
843
844
  X3DKeyDeviceSensorNode: X3DKeyDeviceSensorNode,
844
845
  },
845
- browser: X3DKeyDeviceSensorContext,
846
+ context: X3DKeyDeviceSensorContext,
846
847
  });
847
848
  });
848
849
 
@@ -1 +1 @@
1
- !function(){const e=window[Symbol.for("X_ITE.X3D-5.0.3")].define,t=window[Symbol.for("X_ITE.X3D-5.0.3")].require;e("x_ite/Browser/KeyDeviceSensor/X3DKeyDeviceSensorContext",["x_ite/Fields"],(function(e){"use strict";const t=Symbol(),s=Symbol(),i=Symbol();function n(){this[t]=new Set}return n.prototype={initialize:function(){const e=this.getElement();e.bind("keydown.X3DKeyDeviceSensorContext",this[s].bind(this)),e.bind("keyup.X3DKeyDeviceSensorContext",this[i].bind(this))},addKeyDeviceSensorNode:function(e){this[t].add(e)},removeKeyDeviceSensorNode:function(e){this[t].delete(e)},getKeyDeviceSensorNodes:function(){return this[t]},[s]:function(e){for(const s of this[t])s.keydown(e)},[i]:function(e){for(const s of this[t])s.keyup(e)}},n})),e("x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode",["x_ite/Components/Core/X3DSensorNode","x_ite/Base/X3DConstants"],(function(e,t){"use strict";function s(s){e.call(this,s),this.addType(t.X3DKeyDeviceSensorNode)}return s.prototype=Object.assign(Object.create(e.prototype),{constructor:s,initialize:function(){e.prototype.initialize.call(this),this.isLive().addInterest("set_live__",this),this.set_live__()},set_live__:function(){this.isLive().getValue()?(this._enabled.addInterest("set_enabled__",this),this._enabled.getValue()&&this.enable()):(this._enabled.removeInterest("set_enabled__",this),this.disable())},set_enabled__:function(){this._enabled.getValue()?this.enable():this.disable()},enable:function(){this.getBrowser().addKeyDeviceSensorNode(this)},disable:function(){this.getBrowser().removeKeyDeviceSensorNode(this),this.release()},keydown:function(){},keyup:function(){},release:function(){}}),s})),e("x_ite/Components/KeyDeviceSensor/KeySensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode","x_ite/Base/X3DConstants"],(function(e,t,s,i,n){"use strict";function a(e){i.call(this,e),this.addType(n.KeySensor)}return a.prototype=Object.assign(Object.create(i.prototype),{constructor:a,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new s([new t(n.inputOutput,"metadata",new e.SFNode),new t(n.inputOutput,"enabled",new e.SFBool(!0)),new t(n.outputOnly,"controlKey",new e.SFBool),new t(n.outputOnly,"shiftKey",new e.SFBool),new t(n.outputOnly,"altKey",new e.SFBool),new t(n.outputOnly,"actionKeyPress",new e.SFInt32),new t(n.outputOnly,"actionKeyRelease",new e.SFInt32),new t(n.outputOnly,"keyPress",new e.SFString),new t(n.outputOnly,"keyRelease",new e.SFString),new t(n.outputOnly,"isActive",new e.SFBool)]),getTypeName:function(){return"KeySensor"},getComponentName:function(){return"KeyDeviceSensor"},getContainerField:function(){return"children"},keydown:function(e){switch(e.preventDefault(),this._isActive.getValue()||(this._isActive=!0),e.which){case 16:this._shiftKey=!0;break;case 17:this._controlKey=!0;break;case 18:this._altKey=!0;break;case 112:this._actionKeyPress=1;break;case 113:this._actionKeyPress=2;break;case 114:this._actionKeyPress=3;break;case 115:this._actionKeyPress=4;break;case 116:this._actionKeyPress=5;break;case 117:this._actionKeyPress=6;break;case 118:this._actionKeyPress=7;break;case 119:this._actionKeyPress=8;break;case 120:this._actionKeyPress=9;break;case 121:this._actionKeyPress=10;break;case 122:this._actionKeyPress=11;break;case 123:this._actionKeyPress=12;break;case 36:this._actionKeyPress=13;break;case 35:this._actionKeyPress=14;break;case 33:this._actionKeyPress=15;break;case 34:this._actionKeyPress=16;break;case 38:this._actionKeyPress=17;break;case 40:this._actionKeyPress=18;break;case 37:this._actionKeyPress=19;break;case 39:this._actionKeyPress=20;break;default:if(e.charCode||e.keyCode)switch(e.key){case"AltGraph":case"CapsLock":case"Insert":break;case"Backspace":this._keyPress=String.fromCharCode(8);break;case"Delete":this._keyPress=String.fromCharCode(127);break;case"Enter":this._keyPress="\n";break;case"Escape":this._keyPress=String.fromCharCode(27);break;case"Tab":this._keyPress="\t";break;default:1===e.key.length&&(this._keyPress=e.key)}}},keyup:function(e){switch(e.preventDefault(),e.which){case 16:this._shiftKey=!1;break;case 17:this._controlKey=!1;break;case 18:this._altKey=!1;break;case 112:this._actionKeyRelease=1;break;case 113:this._actionKeyRelease=2;break;case 114:this._actionKeyRelease=3;break;case 115:this._actionKeyRelease=4;break;case 116:this._actionKeyRelease=5;break;case 117:this._actionKeyRelease=6;break;case 118:this._actionKeyRelease=7;break;case 119:this._actionKeyRelease=8;break;case 120:this._actionKeyRelease=9;break;case 121:this._actionKeyRelease=10;break;case 122:this._actionKeyRelease=11;break;case 123:this._actionKeyRelease=12;break;case 36:this._actionKeyRelease=13;break;case 35:this._actionKeyRelease=14;break;case 33:this._actionKeyRelease=15;break;case 34:this._actionKeyRelease=16;break;case 38:this._actionKeyRelease=17;break;case 40:this._actionKeyRelease=18;break;case 37:this._actionKeyRelease=19;break;case 39:this._actionKeyRelease=20;break;default:if(e.charCode||e.keyCode)switch(e.key){case"AltGraph":case"CapsLock":case"Insert":break;case"Backspace":this._keyRelease=String.fromCharCode(8);break;case"Delete":this._keyRelease=String.fromCharCode(127);break;case"Enter":this._keyRelease="\n";break;case"Escape":this._keyRelease=String.fromCharCode(27);break;case"Tab":this._keyRelease="\t";break;default:1===e.key.length&&(this._keyRelease=e.key)}}this._isActive.getValue()&&(this._isActive=!1)},release:function(){this._shiftKey.getValue()&&(this._shiftKey=!1),this._controlKey.getValue()&&(this._controlKey=!1),this._altKey.getValue()&&(this._altKey=!1)}}),a})),e("x_ite/Components/KeyDeviceSensor/StringSensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode","x_ite/Base/X3DConstants"],(function(e,t,s,i,n){"use strict";function a(e){i.call(this,e),this.addType(n.StringSensor)}return a.prototype=Object.assign(Object.create(i.prototype),{constructor:a,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new s([new t(n.inputOutput,"metadata",new e.SFNode),new t(n.inputOutput,"enabled",new e.SFBool(!0)),new t(n.inputOutput,"deletionAllowed",new e.SFBool(!0)),new t(n.outputOnly,"enteredText",new e.SFString),new t(n.outputOnly,"finalText",new e.SFString),new t(n.outputOnly,"isActive",new e.SFBool)]),getTypeName:function(){return"StringSensor"},getComponentName:function(){return"KeyDeviceSensor"},getContainerField:function(){return"children"},keydown:function(e){switch(e.preventDefault(),e.key){case"Backspace":this._isActive.getValue()&&this._deletionAllowed.getValue()&&this._enteredText.length&&(this._enteredText=this._enteredText.getValue().substr(0,this._enteredText.length-1));break;case"Enter":this._finalText=this._enteredText,this._enteredText.set(""),this._isActive.getValue()&&(this._isActive=!1);break;case"Escape":this._enteredText.set(""),this._isActive.getValue()&&(this._isActive=!1);break;case"Tab":break;default:(e.charCode||e.keyCode)&&1===e.key.length&&(this._isActive.getValue()||(this._isActive=!0,this._enteredText=""),this._enteredText=this._enteredText.getValue()+e.key)}}}),a})),e(t.getComponentUrl("key-device-sensor"),["x_ite/Components","x_ite/Browser/KeyDeviceSensor/X3DKeyDeviceSensorContext","x_ite/Components/KeyDeviceSensor/KeySensor","x_ite/Components/KeyDeviceSensor/StringSensor","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode"],(function(e,t,s,i,n){"use strict";e.addComponent({name:"KeyDeviceSensor",types:{KeySensor:s,StringSensor:i},abstractTypes:{X3DKeyDeviceSensorNode:n},browser:t})}))}();
1
+ !function(){const e=window[Symbol.for("X_ITE.X3D-6.1.0")],t=e.define,s=e.require;t("x_ite/Browser/KeyDeviceSensor/X3DKeyDeviceSensorContext",["x_ite/Fields"],(function(e){"use strict";const t=Symbol(),s=Symbol(),i=Symbol();function n(){this[t]=new Set}return n.prototype={initialize:function(){const e=this.getElement();e.bind("keydown.X3DKeyDeviceSensorContext",this[s].bind(this)),e.bind("keyup.X3DKeyDeviceSensorContext",this[i].bind(this))},addKeyDeviceSensorNode:function(e){this[t].add(e)},removeKeyDeviceSensorNode:function(e){this[t].delete(e)},getKeyDeviceSensorNodes:function(){return this[t]},[s]:function(e){for(const s of this[t])s.keydown(e)},[i]:function(e){for(const s of this[t])s.keyup(e)}},n})),t("x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode",["x_ite/Components/Core/X3DSensorNode","x_ite/Base/X3DConstants"],(function(e,t){"use strict";function s(s){e.call(this,s),this.addType(t.X3DKeyDeviceSensorNode)}return s.prototype=Object.assign(Object.create(e.prototype),{constructor:s,initialize:function(){e.prototype.initialize.call(this),this.isLive().addInterest("set_live__",this),this.set_live__()},set_live__:function(){this.isLive().getValue()?(this._enabled.addInterest("set_enabled__",this),this._enabled.getValue()&&this.enable()):(this._enabled.removeInterest("set_enabled__",this),this.disable())},set_enabled__:function(){this._enabled.getValue()?this.enable():this.disable()},enable:function(){this.getBrowser().addKeyDeviceSensorNode(this)},disable:function(){this.getBrowser().removeKeyDeviceSensorNode(this),this.release()},keydown:function(){},keyup:function(){},release:function(){}}),s})),t("x_ite/Components/KeyDeviceSensor/KeySensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode","x_ite/Base/X3DConstants"],(function(e,t,s,i,n){"use strict";function a(e){i.call(this,e),this.addType(n.KeySensor)}return a.prototype=Object.assign(Object.create(i.prototype),{constructor:a,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new s([new t(n.inputOutput,"metadata",new e.SFNode),new t(n.inputOutput,"enabled",new e.SFBool(!0)),new t(n.outputOnly,"controlKey",new e.SFBool),new t(n.outputOnly,"shiftKey",new e.SFBool),new t(n.outputOnly,"altKey",new e.SFBool),new t(n.outputOnly,"actionKeyPress",new e.SFInt32),new t(n.outputOnly,"actionKeyRelease",new e.SFInt32),new t(n.outputOnly,"keyPress",new e.SFString),new t(n.outputOnly,"keyRelease",new e.SFString),new t(n.outputOnly,"isActive",new e.SFBool)]),getTypeName:function(){return"KeySensor"},getComponentName:function(){return"KeyDeviceSensor"},getContainerField:function(){return"children"},keydown:function(e){switch(e.preventDefault(),this._isActive.getValue()||(this._isActive=!0),e.which){case 16:this._shiftKey=!0;break;case 17:this._controlKey=!0;break;case 18:this._altKey=!0;break;case 112:this._actionKeyPress=1;break;case 113:this._actionKeyPress=2;break;case 114:this._actionKeyPress=3;break;case 115:this._actionKeyPress=4;break;case 116:this._actionKeyPress=5;break;case 117:this._actionKeyPress=6;break;case 118:this._actionKeyPress=7;break;case 119:this._actionKeyPress=8;break;case 120:this._actionKeyPress=9;break;case 121:this._actionKeyPress=10;break;case 122:this._actionKeyPress=11;break;case 123:this._actionKeyPress=12;break;case 36:this._actionKeyPress=13;break;case 35:this._actionKeyPress=14;break;case 33:this._actionKeyPress=15;break;case 34:this._actionKeyPress=16;break;case 38:this._actionKeyPress=17;break;case 40:this._actionKeyPress=18;break;case 37:this._actionKeyPress=19;break;case 39:this._actionKeyPress=20;break;default:if(e.charCode||e.keyCode)switch(e.key){case"AltGraph":case"CapsLock":case"Insert":break;case"Backspace":this._keyPress=String.fromCharCode(8);break;case"Delete":this._keyPress=String.fromCharCode(127);break;case"Enter":this._keyPress="\n";break;case"Escape":this._keyPress=String.fromCharCode(27);break;case"Tab":this._keyPress="\t";break;default:1===e.key.length&&(this._keyPress=e.key)}}},keyup:function(e){switch(e.preventDefault(),e.which){case 16:this._shiftKey=!1;break;case 17:this._controlKey=!1;break;case 18:this._altKey=!1;break;case 112:this._actionKeyRelease=1;break;case 113:this._actionKeyRelease=2;break;case 114:this._actionKeyRelease=3;break;case 115:this._actionKeyRelease=4;break;case 116:this._actionKeyRelease=5;break;case 117:this._actionKeyRelease=6;break;case 118:this._actionKeyRelease=7;break;case 119:this._actionKeyRelease=8;break;case 120:this._actionKeyRelease=9;break;case 121:this._actionKeyRelease=10;break;case 122:this._actionKeyRelease=11;break;case 123:this._actionKeyRelease=12;break;case 36:this._actionKeyRelease=13;break;case 35:this._actionKeyRelease=14;break;case 33:this._actionKeyRelease=15;break;case 34:this._actionKeyRelease=16;break;case 38:this._actionKeyRelease=17;break;case 40:this._actionKeyRelease=18;break;case 37:this._actionKeyRelease=19;break;case 39:this._actionKeyRelease=20;break;default:if(e.charCode||e.keyCode)switch(e.key){case"AltGraph":case"CapsLock":case"Insert":break;case"Backspace":this._keyRelease=String.fromCharCode(8);break;case"Delete":this._keyRelease=String.fromCharCode(127);break;case"Enter":this._keyRelease="\n";break;case"Escape":this._keyRelease=String.fromCharCode(27);break;case"Tab":this._keyRelease="\t";break;default:1===e.key.length&&(this._keyRelease=e.key)}}this._isActive.getValue()&&(this._isActive=!1)},release:function(){this._shiftKey.getValue()&&(this._shiftKey=!1),this._controlKey.getValue()&&(this._controlKey=!1),this._altKey.getValue()&&(this._altKey=!1)}}),a})),t("x_ite/Components/KeyDeviceSensor/StringSensor",["x_ite/Fields","x_ite/Base/X3DFieldDefinition","x_ite/Base/FieldDefinitionArray","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode","x_ite/Base/X3DConstants"],(function(e,t,s,i,n){"use strict";function a(e){i.call(this,e),this.addType(n.StringSensor)}return a.prototype=Object.assign(Object.create(i.prototype),{constructor:a,[Symbol.for("X_ITE.X3DBaseNode.fieldDefinitions")]:new s([new t(n.inputOutput,"metadata",new e.SFNode),new t(n.inputOutput,"enabled",new e.SFBool(!0)),new t(n.inputOutput,"deletionAllowed",new e.SFBool(!0)),new t(n.outputOnly,"enteredText",new e.SFString),new t(n.outputOnly,"finalText",new e.SFString),new t(n.outputOnly,"isActive",new e.SFBool)]),getTypeName:function(){return"StringSensor"},getComponentName:function(){return"KeyDeviceSensor"},getContainerField:function(){return"children"},keydown:function(e){switch(e.preventDefault(),e.key){case"Backspace":this._isActive.getValue()&&this._deletionAllowed.getValue()&&this._enteredText.length&&(this._enteredText=this._enteredText.getValue().substr(0,this._enteredText.length-1));break;case"Enter":this._finalText=this._enteredText,this._enteredText.set(""),this._isActive.getValue()&&(this._isActive=!1);break;case"Escape":this._enteredText.set(""),this._isActive.getValue()&&(this._isActive=!1);break;case"Tab":break;default:(e.charCode||e.keyCode)&&1===e.key.length&&(this._isActive.getValue()||(this._isActive=!0,this._enteredText=""),this._enteredText=this._enteredText.getValue()+e.key)}}}),a})),t(s.getComponentUrl("key-device-sensor"),["x_ite/Components","x_ite/Browser/KeyDeviceSensor/X3DKeyDeviceSensorContext","x_ite/Components/KeyDeviceSensor/KeySensor","x_ite/Components/KeyDeviceSensor/StringSensor","x_ite/Components/KeyDeviceSensor/X3DKeyDeviceSensorNode"],(function(e,t,s,i,n){"use strict";e.addComponent({name:"KeyDeviceSensor",types:{KeySensor:s,StringSensor:i},abstractTypes:{X3DKeyDeviceSensorNode:n},context:t})}))}();