x_ite 8.6.20 → 8.6.22

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 (100) hide show
  1. package/Makefile +1 -4
  2. package/build/bin/components.js +45 -0
  3. package/dist/assets/components/Annotation.js +13 -13
  4. package/dist/assets/components/Annotation.min.js +1 -1
  5. package/dist/assets/components/CADGeometry.js +13 -13
  6. package/dist/assets/components/CADGeometry.min.js +1 -1
  7. package/dist/assets/components/CubeMapTexturing.js +25 -25
  8. package/dist/assets/components/CubeMapTexturing.min.js +1 -1
  9. package/dist/assets/components/DIS.js +13 -13
  10. package/dist/assets/components/DIS.min.js +1 -1
  11. package/dist/assets/components/EventUtilities.js +9 -9
  12. package/dist/assets/components/EventUtilities.min.js +1 -1
  13. package/dist/assets/components/Geometry2D.js +19 -19
  14. package/dist/assets/components/Geometry2D.min.js +1 -1
  15. package/dist/assets/components/Geospatial.js +33 -33
  16. package/dist/assets/components/Geospatial.min.js +1 -1
  17. package/dist/assets/components/HAnim.js +18 -18
  18. package/dist/assets/components/HAnim.min.js +1 -1
  19. package/dist/assets/components/KeyDeviceSensor.js +8 -8
  20. package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
  21. package/dist/assets/components/Layout.js +27 -27
  22. package/dist/assets/components/Layout.min.js +1 -1
  23. package/dist/assets/components/NURBS.js +24 -24
  24. package/dist/assets/components/NURBS.min.js +1 -1
  25. package/dist/assets/components/ParticleSystems.js +22 -22
  26. package/dist/assets/components/ParticleSystems.min.js +1 -1
  27. package/dist/assets/components/Picking.js +18 -18
  28. package/dist/assets/components/Picking.min.js +1 -1
  29. package/dist/assets/components/RigidBodyPhysics.js +18 -18
  30. package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
  31. package/dist/assets/components/Scripting.js +28 -28
  32. package/dist/assets/components/Scripting.min.js +1 -1
  33. package/dist/assets/components/Text.js +24 -24
  34. package/dist/assets/components/Text.min.js +1 -1
  35. package/dist/assets/components/TextureProjector.js +14 -14
  36. package/dist/assets/components/TextureProjector.min.js +1 -1
  37. package/dist/assets/components/Texturing3D.js +30 -30
  38. package/dist/assets/components/Texturing3D.min.js +1 -1
  39. package/dist/assets/components/VolumeRendering.js +19 -19
  40. package/dist/assets/components/VolumeRendering.min.js +1 -1
  41. package/dist/assets/components/X_ITE.js +9 -9
  42. package/dist/assets/components/X_ITE.min.js +1 -1
  43. package/dist/x_ite.css +1 -1
  44. package/dist/x_ite.js +746 -613
  45. package/dist/x_ite.min.js +1 -1
  46. package/dist/x_ite.zip +0 -0
  47. package/docs/_config.yml +2 -2
  48. package/docs/_posts/dom-integration.md +14 -12
  49. package/docs/_posts/getting-started.md +13 -11
  50. package/docs/_posts/reference/ecmascript-object-and-function-definitions.md +1 -1
  51. package/docs/_posts/reference/scene-services.md +6 -3
  52. package/docs/_posts/report-a-bug.md +5 -3
  53. package/docs/_posts/setup-a-localhost-server.md +7 -7
  54. package/docs/_posts/tutorials/writing-program-scripts-with-ecmascript.md +1 -1
  55. package/docs/_tabs/playground.html +8 -12
  56. package/package.json +1 -1
  57. package/src/locale/de.po.js +9 -0
  58. package/src/locale/fr.po.js +31 -25
  59. package/src/tests.js +1 -0
  60. package/src/x_ite/Base/X3DBaseNode.js +2 -12
  61. package/src/x_ite/Base/X3DInfoArray.js +0 -2
  62. package/src/x_ite/Base/X3DObjectArrayField.js +0 -2
  63. package/src/x_ite/Base/X3DTypedArrayField.js +0 -2
  64. package/src/x_ite/Browser/Core/BrowserTimings.js +147 -67
  65. package/src/x_ite/Browser/Core/ContextMenu.js +2 -2
  66. package/src/x_ite/Browser/Core/X3DCoreContext.js +6 -2
  67. package/src/x_ite/Browser/Networking/X3DNetworkingContext.js +7 -3
  68. package/src/x_ite/Browser/VERSION.js +1 -1
  69. package/src/x_ite/Browser/X3DBrowser.js +0 -10
  70. package/src/x_ite/Browser/X3DBrowserContext.js +0 -1
  71. package/src/x_ite/Components/Core/X3DNode.js +40 -9
  72. package/src/x_ite/Components/Core/X3DPrototypeInstance.js +5 -5
  73. package/src/x_ite/Configuration/ComponentInfo.js +2 -1
  74. package/src/x_ite/Configuration/ProfileInfo.js +1 -0
  75. package/src/x_ite/Configuration/UnitInfo.js +3 -5
  76. package/src/x_ite/Execution/BindableList.js +34 -27
  77. package/src/x_ite/Execution/BindableStack.js +15 -17
  78. package/src/x_ite/Execution/X3DExecutionContext.js +7 -17
  79. package/src/x_ite/Execution/X3DExportedNode.js +1 -3
  80. package/src/x_ite/Execution/X3DImportedNode.js +2 -6
  81. package/src/x_ite/Execution/X3DScene.js +30 -28
  82. package/src/x_ite/Fields/ArrayFields.js +4 -4
  83. package/src/x_ite/Fields/SFColor.js +0 -3
  84. package/src/x_ite/Fields/SFColorRGBA.js +0 -4
  85. package/src/x_ite/Fields/SFImage.js +0 -4
  86. package/src/x_ite/Fields/SFMatrix3.js +0 -1
  87. package/src/x_ite/Fields/SFMatrix4.js +0 -1
  88. package/src/x_ite/Fields/SFRotation.js +0 -4
  89. package/src/x_ite/Fields/SFString.js +7 -4
  90. package/src/x_ite/Fields/SFVec2.js +0 -2
  91. package/src/x_ite/Fields/SFVec3.js +0 -3
  92. package/src/x_ite/Fields/SFVec4.js +0 -4
  93. package/src/x_ite/InputOutput/Generator.js +86 -16
  94. package/src/x_ite/Prototype/X3DExternProtoDeclaration.js +2 -8
  95. package/src/x_ite/Prototype/X3DProtoDeclaration.js +2 -6
  96. package/src/x_ite/Routing/X3DRoute.js +1 -5
  97. package/src/x_ite/X3DCanvasElement.js +2 -0
  98. package/src/x_ite.css +5 -1
  99. package/src/x_ite.html +4 -36
  100. package/x_ite.min.html +4 -36
package/dist/x_ite.zip CHANGED
Binary file
package/docs/_config.yml CHANGED
@@ -20,8 +20,8 @@ timezone:
20
20
  # ↓ --------------------------
21
21
 
22
22
  title: X_ITE X3D Browser # the main title
23
- version: 8.6.20 # x_ite latest version
24
- size: 290 # size in kb
23
+ version: 8.6.22 # x_ite latest version
24
+ size: 291 # size in kb
25
25
  x3d_latest_version: 4.0 # x3d latest version
26
26
 
27
27
  tagline: Step Into The Future # it will display as the sub-title
@@ -3,19 +3,21 @@ title: DOM Integration
3
3
  date: 2022-11-28
4
4
  nav: main
5
5
  categories: []
6
- tags: [DOM, Integration, XHTML]
6
+ tags: [DOM, Integration, XHTML, HTML]
7
7
  ---
8
8
  ## Overview
9
9
 
10
- DOM integration allows you to integrate 3D content seamlessly into your web page, with just a JavaScript file included the scene can be written directly into the XHTML or HTML markup.
10
+ DOM integration allows you to integrate 3D content seamlessly into your web page, with just a JavaScript file included, the scene can be written directly into the XHTML or HTML markup.
11
11
 
12
- Andreas Plesch wrote a nice plug-in for X3D DOM integration. This enables JavaScript authors to use X3D content as if it would be HTML. It links the X3D DOM nodes to the X3D scene graph and thereby allows for control of the X3D scene using regular DOM manipulation methods.
12
+ Andreas Plesch has written a nice plugin for X3D DOM integration. It allows JavaScript authors to use X3D content as if it were HTML. It links the X3D DOM nodes to the X3D scene graph, allowing control of the X3D scene using regular DOM manipulation methods.
13
13
 
14
14
  **HTML DOM integration is now an integral part of X_ITE.**
15
15
 
16
16
  ## How to Use With X_ITE
17
17
 
18
- Create an HTML or XHTML page and save it, include the »x_ite.min.js«. Now, X3D content can directly be written within the \<x3d-canvas\> element and regular DOM manipulation methods can be used to manipulate the scene graph. This gives X3D authors the ability to combine HTML with X3D. The example below will show a simple Box node in the \<x3d-canvas\> element.
18
+ Create an HTML or XHTML page, and save it and include the »x_ite.min.js«. Now, X3D content can be written directly into the \<x3d-canvas\> element, and regular DOM manipulation methods can be used to manipulate the scene graph, and you can combine HTML with X3D.
19
+
20
+ The example below shows a simple Box node inside the \<x3d-canvas\> element.
19
21
 
20
22
  ```html
21
23
  <!DOCTYPE html>
@@ -82,7 +84,7 @@ window .addEventListener ("load", function ()
82
84
  </html>
83
85
  ```
84
86
 
85
- >**Attention:** Make sure you use **closing tags** for all X3D elements. This is needed, because the web browser does not know the X3D elements, and therefor does not know if the tag is self-closing, unless you use XHTML.
87
+ >**Attention:** Make sure you use **closing tags** for all X3D elements. This is necessary because the web browser does not know about X3D elements and therefore does not know if the tag is self-closing unless you are using XHTML.
86
88
  {: .prompt-danger }
87
89
 
88
90
  ### Example
@@ -91,7 +93,7 @@ window .addEventListener ("load", function ()
91
93
 
92
94
  ## Attributes
93
95
 
94
- If you change an attribute of an X3D element, then the internal state of the node will also change.
96
+ When you change an attribute of an X3D element, the internal state of the node also changes.
95
97
 
96
98
  ```js
97
99
  const material = document .querySelector ("Material");
@@ -101,7 +103,7 @@ material .setAttribute ("diffuseColor", "1 0 0"); // Set diffuse color to red.
101
103
 
102
104
  ## Events
103
105
 
104
- You can add an event listener to any X3D element with the name of the output field you want to listen to. If the field has changed, an event will occur.
106
+ You can add an event listener to any X3D element with the name of the output field you want to listen on. If the field has changed, an event will fire.
105
107
 
106
108
  Events sent from a node are of type CustomEvent and have the following properties:
107
109
 
@@ -118,7 +120,7 @@ CustomEvent: {
118
120
 
119
121
  ## Add and Remove Nodes
120
122
 
121
- The content of the X3D scene can be modified with DOM manipulation methods to change the scene. You can add and remove nodes to build your own scene.
123
+ The contents of the X3D scene can be modified using DOM manipulation methods to change the scene. You can add and remove nodes to create your own scene.
122
124
 
123
125
  ```js
124
126
  function addBlueBox ()
@@ -183,7 +185,7 @@ function removeRoute ()
183
185
 
184
186
  ## Inline Nodes
185
187
 
186
- Even the content of Inline nodes can be accessed and modified. The internal scene of the Inline node is attached to the Inline element as child every time the Inline node is completely loaded. To check if an Inline node is loaded use a LoadSensor node.
188
+ Even the contents of Inline nodes can be accessed and modified. The internal scene of the Inline node is attached to the Inline element as a child each time the Inline node is fully loaded. To check whether an Inline node is loaded, use a LoadSensor node.
187
189
 
188
190
  ```html
189
191
  <x3d-canvas>
@@ -201,7 +203,7 @@ Even the content of Inline nodes can be accessed and modified. The internal scen
201
203
  </x3d-canvas>
202
204
  ```
203
205
 
204
- Assuming there is a Transform node with DEF name »Deer« inside the loaded scene »Deer.x3d«, the Transform node can be accessed when the Inline node is loaded. You should listen to the LoadSensor node's *loadTime* or *isLoaded* field to get informed when this will happen.
206
+ Assuming there is a Transform node with the DEF name »Deer« inside the loaded scene »Deer.x3d«, the Transform node can be accessed when the Inline node is loaded. You should listen to the LoadSensor node's *loadTime* or *isLoaded* field to be informed when this happens.
205
207
 
206
208
  ```js
207
209
  const transform = document .querySelector ("[DEF='DeerInline'] [DEF='Deer']");
@@ -209,7 +211,7 @@ const transform = document .querySelector ("[DEF='DeerInline'] [DEF='Deer']");
209
211
 
210
212
  ### Events of Inline Element
211
213
 
212
- Every Inline element sends a `load` or `error` event when the content of the Inline is loaded or failed loading.
214
+ Each Inline element sends a `load` or `error` event when the content of the Inline is loaded or fails to load.
213
215
 
214
216
  ```js
215
217
  const inline = document .querySelector ("[DEF='DeerInline']");
@@ -219,7 +221,7 @@ inline .addEventListener ("load", () => console .log ("Deer loaded!"));
219
221
 
220
222
  ## Script Element
221
223
 
222
- If you use a HTML instead of a XHTML page then there is already a \<script\> element, as you know. To avoid collisions you must add a different type. A proper type is `model/x3d+xml`, which prevents the web browser from interpreting the content as JavaScript, and X_ITE can take over the content.
224
+ If you are using an HTML page instead of an XHTML page, you will already have a \<script\> element. To avoid collisions, you need to add a different type. A proper type is `model/x3d+xml`, which prevents the web browser from interpreting the content as JavaScript, and allows X_ITE to take over the content.
223
225
 
224
226
  ```html
225
227
  <Script type='model/x3d+xml' DEF='ChangeColorScript'>
@@ -13,7 +13,8 @@ x_ite: true
13
13
  splashScreen="false"
14
14
  contextMenu="false"
15
15
  notifications="false"
16
- timings="false">
16
+ timings="false"
17
+ contentScale="auto">
17
18
  </x3d-canvas>
18
19
 
19
20
  ## Overview
@@ -27,7 +28,7 @@ X_ITE supports custom shaders, clip planes, reflection mapping, script nodes, pr
27
28
  >**Tip:** X_ITE runs best in fresh installs of Google Chrome, Chromium, Firefox, Safari, Opera, and Microsoft Edge. X_ITE uses the latest JavaScript standard, but is also compatible with older browser, and is available both on your desktop computer and on your modern smart-phone.
28
29
  {: .prompt-tip }
29
30
 
30
- If you ever get in trouble, please [report a bug](report-a-bug).
31
+ If you ever get into trouble, please [report a bug](report-a-bug). If you have any questions or need help [open a new issue](report-a-bug).
31
32
 
32
33
  ## X3D Examples
33
34
 
@@ -621,12 +622,9 @@ x3d-canvas {
621
622
  </html>
622
623
  ```
623
624
 
624
- To get X_ITE working you need to include the JavaScript file »x_ite.min.js«. Once x_ite has loaded successfully, a new HTML element \<x3d-canvas\> will be available on your page.
625
+ To get X_ITE working you need to include the JavaScript file »x_ite.min.js«. Once X_ITE has loaded successfully, a new HTML element \<x3d-canvas\> will be available on your page. You can style the \<x3d-canvas\> element with CSS just like any other HTML element, and you can place it anywhere in the DOM tree.
625
626
 
626
- >**Attention:** If you test a page locally on your desktop computer, you must setup a **localhost** server if you want to load a file via *src* attribute or Inline node, see [Setup a localhost Server](setup-a-localhost-server). Or use [DOM Integration](dom-integration) methods to directly combine HTML with X3D.
627
- {: .prompt-danger }
628
-
629
- >**Tip:** You can style the \<x3d-canvas\> element with CSS like any other HTML element, and you can place it anywhere in the DOM tree.
627
+ >**Tip:** To test a page locally on your desktop computer, setup a **localhost** server to load files via *src* attribute or Inline node, see [setup a localhost server](setup-a-localhost-server), or [directly combine HTML with X3D](dom-integration).
630
628
  {: .prompt-tip }
631
629
 
632
630
  ### Supported File Formats
@@ -647,7 +645,7 @@ X_ITE can load several file formats, either directly as the source of the \<x3d-
647
645
  >**Tip:** All files can be compressed using GZip compression. This saves bandwidth and speeds up download time.
648
646
  {: .prompt-tip }
649
647
 
650
- If you have an own web-server see [How to Configure Your Web Server](how-to-configure-your-web-server). If you are looking for an online X3D file format converter [see here](laboratory/x3d-file-converter).
648
+ If you have an own web-server see [how to configure your web server](how-to-configure-your-web-server). If you are looking for an online X3D file format converter [see here](laboratory/x3d-file-converter).
651
649
 
652
650
  ### Fallback Content
653
651
 
@@ -680,13 +678,17 @@ A Boolean value (`true` or `false`) to indicate whether rendering should use har
680
678
  >**Tip:** Set CSS property »image-rendering« of \<x3d-canvas\> element to »pixelated«, if no filtering is desired in addition.
681
679
  {: .prompt-tip }
682
680
 
681
+ ### baseURL
682
+
683
+ A String value containing the URL against which relative URLs are resolved. By default, this is the address of the web page itself. Although this feature is rarely needed, it can be useful when loading a `data:` URL with the *src* attribute, or with `Browser.loadURL` when using the external browser.
684
+
683
685
  ### cache
684
686
 
685
687
  A Boolean value (`true` or `false`) to indicate whether files transferred over the internet should be cached on the local computer. The default value for the *cache* attribute is `true`. It works by appending "_={timestamp}" to the GET parameters of every request.
686
688
 
687
689
  ### contentScale
688
690
 
689
- A Float value that determines how much higher he physical resolution of the internal \<canvas\> element is. The default value for the *contentScale* attribute is `1.0`, which is sufficient for most cases. A higher value, will increase the resolution of the internal \<canvas\> element and can be uses to increase the antialiasing effect, thus making the rendered image sharper. If the value is set to `auto`, then contentScale will match »window.devicePixelRatio«, which is useful for HiDPI or Retina displays. A value between `0.0` and `1.0` will result in a pixelated image, see also [antialiased](#antialiased) attribute.
691
+ A Float value that specifies how much higher the physical resolution of the internal \<canvas\> element is. The default value for the *contentScale* attribute is `1.0`, which is sufficient for most cases. A higher value increases the resolution of the internal \<canvas\> element and can be used to increase the anti-aliasing effect, making the rendered image sharper. If set to `auto`, contentScale will match »window.devicePixelRatio«, which is useful for HiDPI or Retina displays. A value between `0.0` and `1.0` will result in a pixelated image, see also the [antialiased](#antialiased) attribute.
690
692
 
691
693
  ### contextMenu
692
694
 
@@ -698,7 +700,7 @@ A Boolean value (`true` or `false`) to indicate whether additional debug message
698
700
 
699
701
  ### multisampling
700
702
 
701
- A Integer value that sets the number of samples used by multisampling. The default value is 4, which is sufficient for most cases. A higher value increases the effect of antialiasing. Check [rendering property](reference/browser-services#rendering-properties) »MaxSamples«, which is browser dependent.
703
+ An Integer value that specifies the number of samples used by multisampling. The default value is 4, which is sufficient for most cases. A higher value increases the effect of anti-aliasing. Check the [rendering property](reference/browser-services#rendering-properties) »MaxSamples«, which is browser dependent.
702
704
 
703
705
  ### notifications
704
706
 
@@ -734,7 +736,7 @@ A Boolean value (`true` or `false`) to indicate whether the Timings Panel should
734
736
 
735
737
  ### url
736
738
 
737
- A MFString value of URLs to load on page load. If no *url* attribute is specified or the attribute is empty, an empty scene will be displayed. If both src and *url* attributes are specified, the *src* attribute takes precedence.
739
+ An MFString value of URLs to load on page load. If no *url* attribute is specified or the attribute is empty, an empty scene will be displayed. If both *src* and *url* attributes are given, the last given attribute takes precedence.
738
740
 
739
741
  ### Example
740
742
 
@@ -3,7 +3,7 @@ title: ECMAScript Object and Function Definitions
3
3
  date: 2022-11-28
4
4
  nav: reference
5
5
  categories: [Reference]
6
- tags: [Ecmascript, Object, Function, Definitions]
6
+ tags: [ECMAScript, Object, Function, Definitions]
7
7
  ---
8
8
  ## Overview
9
9
 
@@ -160,9 +160,12 @@ Returns the X3D VRML-encoded string that, if parsed as the value of createX3DFro
160
160
 
161
161
  An object with one or more of these properties:
162
162
 
163
- * **style:** string, output style, one of: **"TIDY"**, "COMPACT", "SMALL", "CLEAN"
164
- * **precision:** integer, float precision, default: 7
165
- * **doublePrecision:** integer, double precision, default: 15
163
+ * **style:** String, output style, one of: **"TIDY"**, "COMPACT", "SMALL", "CLEAN"
164
+ * **indent:** String, initial indent, default: ""
165
+ * **precision:** Integer, float precision, default: 7
166
+ * **doublePrecision:** Integer, double precision, default: 15
167
+ * **html:** Boolean, HTML style, default: false
168
+ * **closingTags:** Boolean, use closing tags, default: false
166
169
 
167
170
  #### String **toXMLString** (\[options\])
168
171
 
@@ -1,9 +1,9 @@
1
1
  ---
2
- title: Report a Bug
2
+ title: Report a Bug or Ask a Question
3
3
  date: 2022-12-02
4
4
  nav: main
5
5
  categories: []
6
- tags: [Bug, Report, Issue]
6
+ tags: [Bug, Report, Issue, Question]
7
7
  ---
8
8
  If you run into any bugs or encounter any other abnormal issues with X_ITE, let us know!
9
9
 
@@ -12,4 +12,6 @@ Here's an example of a helpful bug report:
12
12
  >*I fell through a hole on the Resistance map. I was running along the wall near the pool of water and fell through a black hole in the wall. I got stuck and had to leave the match. This happened while playing Search and Destroy.*
13
13
  {: .prompt-danger }
14
14
 
15
- [X_ITE Feedback Survey and Bug Report](https://github.com/create3000/x_ite/issues){:target="_blank"}
15
+ You can also use the Issue Tracker if you have a question or if you need help with something.
16
+
17
+ Go ahead and visit the [X_ITE Issue Tracker](https://github.com/create3000/x_ite/issues){:target="_blank"} to post your concern.
@@ -7,21 +7,21 @@ tags: [Setup, Localhost, Server, XHR]
7
7
  ---
8
8
  ## Overview
9
9
 
10
- X_ITE makes use of the XMLHttpRequest object to load files and there's no way round that. But that means files loading using the file:// scheme protocol are subject to the same origin policy and are handled as cross origin requests (CORS) and cross origin requests are only supported for protocol schemes: https, http and data. **That means X_ITE cannot have access to this files.**
10
+ X_ITE uses the `fetch` function to load files and there's no way around it. However, this means that files loaded using the **file://** scheme protocol are subject to the same origin policy and are treated as cross-origin requests (CORS), and cross-origin requests are only supported for protocol schemes: https, http and data. **This means that X_ITE cannot access these files.**
11
11
 
12
- To work around this problem you must set up a localhost server, then you can access your local files under the web address http://**localhost**/...
12
+ To work around this problem, you will need to set up a localhost server, then you will be able to access your local files at the web address http://**localhost**/...
13
13
 
14
- ### Using a Browser Extension
14
+ ## Using a Browser Extension
15
15
 
16
- You can use this [Browser Extension](https://webextension.org/listing/access-control.html) to unlock the CORS restrictions imposed by your browser. This is useful if you are in development mode and is easy to use.
16
+ You can use this [browser extension for Chrome and Edge](https://chrome.google.com/webstore/detail/web-server-for-chrome/ofhbbkphhbklhfoeikjpcbhemlocgigb/){:target="_blank"} to create a web server and serve your local files via HTTP. Very easy to use.
17
17
 
18
18
  ## Using an Application
19
19
 
20
- There are several applications on the Internet which can make a localhost server. Here I would like to recommend you two of them:
20
+ There are several applications on the Internet that can create a localhost server. I would like to recommend two of them:
21
21
 
22
- MacOS users can use [Personal Web Server](https://apps.apple.com/de/app/personal-web-server/id1486323797?mt=12), which can serves files through a web server, and is very easy to use.
22
+ MacOS users can use [Personal Web Server](https://apps.apple.com/de/app/personal-web-server/id1486323797?mt=12){:target="_blank"}, which can serve files through a web server, and is very easy to use.
23
23
 
24
- Another application is [XAMPP](https://www.apachefriends.org/index.html), which runs on several operating systems and is very popular.
24
+ Another application is [XAMPP](https://www.apachefriends.org/index.html){:target="_blank"}, which runs on several operating systems and is very popular.
25
25
 
26
26
  ## Using Python
27
27
 
@@ -3,7 +3,7 @@ title: Writing Program Scripts with ECMAScript
3
3
  date: 2022-11-28
4
4
  nav: tutorials-scripts-and-prototypes
5
5
  categories: [Tutorials]
6
- tags: [Program, Scripts, Ecmascript, Javascript]
6
+ tags: [Program, Scripts, ECMAScript, Javascript]
7
7
  ---
8
8
  ## Motivation
9
9
 
@@ -137,25 +137,21 @@ $(function ()
137
137
  const
138
138
  Browser = X3D .getBrowser (),
139
139
  text = editor .getValue (),
140
- url = "data:," + encodeURIComponent (text);
140
+ url = `data:,${encodeURIComponent (text)}`;
141
141
 
142
142
  if (Browser .getActiveViewpoint ())
143
143
  {
144
- const
144
+ var
145
145
  positionOffset = Browser .getActiveViewpoint () ._positionOffset .copy (),
146
146
  orientationOffset = Browser .getActiveViewpoint () ._orientationOffset .copy ();
147
+ }
147
148
 
148
- await Browser .loadURL (new X3D .MFString (url)) .catch (Function .prototype);
149
+ await Browser .loadURL (new X3D .MFString (url)) .catch (Function .prototype);
149
150
 
150
- if (Browser .getActiveViewpoint ())
151
- {
152
- Browser .getActiveViewpoint () ._positionOffset = positionOffset;
153
- Browser .getActiveViewpoint () ._orientationOffset = orientationOffset;
154
- }
155
- }
156
- else
151
+ if (Browser .getActiveViewpoint ())
157
152
  {
158
- await Browser .loadURL (new X3D .MFString (url)) .catch (Function .prototype);
153
+ Browser .getActiveViewpoint () ._positionOffset = positionOffset;
154
+ Browser .getActiveViewpoint () ._orientationOffset = orientationOffset;
159
155
  }
160
156
 
161
157
  monaco .editor .setModelLanguage (editor .getModel (), Browser .currentScene .encoding .toLowerCase ());
@@ -181,7 +177,7 @@ $(function ()
181
177
  text = args .join ("") + "\n",
182
178
  element = $("<span></span>") .addClass (classes) .text (text);
183
179
 
184
- if (text .match (/No suitable/))
180
+ if (text .match (/No suitable|of an UNKNOWN touch/))
185
181
  return;
186
182
 
187
183
  log .apply (this, args);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "x_ite",
3
- "version": "8.6.20",
3
+ "version": "8.6.22",
4
4
  "description": "X_ITE X3D Browser, view and manipulate X3D and VRML scenes in HTML.",
5
5
  "homepage": "https://create3000.github.io/x_ite/",
6
6
  "author": "Holger Seelig <holger.seelig@gmail.com>",
@@ -153,6 +153,15 @@ msgstr "Auf Objekte zielen"
153
153
  msgid "None Viewer"
154
154
  msgstr "Kein Betrachter"
155
155
 
156
+ msgid "Points"
157
+ msgstr "Punkte"
158
+
159
+ msgid "Flat"
160
+ msgstr "Flach"
161
+
162
+ msgid "Wireframe"
163
+ msgstr "Drahtgittermodel"
164
+
156
165
  msgid "Loading %1 file"
157
166
  msgstr "Lade %1 Datei"
158
167
 
@@ -16,13 +16,13 @@ msgstr ""
16
16
  "X-Poedit-SearchPath-0: .\n"
17
17
 
18
18
  msgid "Less Properties"
19
- msgstr "Moins de propriétés"
19
+ msgstr "Moins de Propriétés"
20
20
 
21
21
  msgid "More Properties"
22
- msgstr "Plus de propriétés"
22
+ msgstr "Plus de Propriétés"
23
23
 
24
24
  msgid "Frame rate"
25
- msgstr "Fréquence"
25
+ msgstr "Fréquence d'Images"
26
26
 
27
27
  msgid "fps"
28
28
  msgstr "fps"
@@ -45,8 +45,8 @@ msgstr ""
45
45
  msgid "X3D total"
46
46
  msgstr "X3D total"
47
47
 
48
- msgid "Traitement des événements"
49
- msgstr "Routes"
48
+ msgid "Event Processing"
49
+ msgstr "Traitement des Événements"
50
50
 
51
51
  msgid "Pointer"
52
52
  msgstr "Pointeur"
@@ -55,34 +55,34 @@ msgid "Camera"
55
55
  msgstr "Caméra"
56
56
 
57
57
  msgid "Collision Detection"
58
- msgstr "Détection des collisions"
58
+ msgstr "Détection des Collisions"
59
59
 
60
60
  msgid "Rendering"
61
61
  msgstr "Rendement"
62
62
 
63
63
  msgid "Number of Shapes"
64
- msgstr "Nombre de formes"
64
+ msgstr "Nombre de Formes"
65
65
 
66
66
  msgid "Number of Sensors"
67
- msgstr "Nombre de senseurs"
67
+ msgstr "Nombre de Senseurs"
68
68
 
69
69
  msgid "Browser Timings"
70
- msgstr "Calcul du temps"
70
+ msgstr "Calcul du Temps"
71
71
 
72
72
  msgid "X_ITE Browser"
73
73
  msgstr "X_ITE Navigateur"
74
74
 
75
75
  msgid "Viewpoints"
76
- msgstr "Points de vue"
76
+ msgstr "Points de Vue"
77
77
 
78
78
  msgid "Available Viewers"
79
79
  msgstr "Visionneurs disponibles"
80
80
 
81
81
  msgid "Straighten Horizon"
82
- msgstr "Redresser l'horizon"
82
+ msgstr "Redresser l'Horizon"
83
83
 
84
84
  msgid "Primitive Quality"
85
- msgstr "Qualité des objets simples"
85
+ msgstr "Qualité des Objets simples"
86
86
 
87
87
  msgid "High"
88
88
  msgstr "Haut"
@@ -103,10 +103,10 @@ msgid "low"
103
103
  msgstr "faible"
104
104
 
105
105
  msgid "Texture Quality"
106
- msgstr "Qualité des textures"
106
+ msgstr "Qualité des Textures"
107
107
 
108
108
  msgid "Display Rubberband"
109
- msgstr "Présenter le bande élastique"
109
+ msgstr "Présenter le Bande élastique"
110
110
 
111
111
  msgid "Rubberband"
112
112
  msgstr "Bande élastique"
@@ -118,19 +118,19 @@ msgid "off"
118
118
  msgstr "arrêt"
119
119
 
120
120
  msgid "Mute Browser"
121
- msgstr "Rendre navigateur muet"
121
+ msgstr "Rendre Navigateur muet"
122
122
 
123
123
  msgid "Browser muted"
124
124
  msgstr "Navigateur muet"
125
125
 
126
126
  msgid "Browser unmuted"
127
- msgstr "Son de navigateur réactivé"
127
+ msgstr "Son de Navigateur réactivé"
128
128
 
129
129
  msgid "Leave Fullscreen"
130
- msgstr "Sortie en plein écran"
130
+ msgstr "Laisser le plein Écran"
131
131
 
132
132
  msgid "Fullscreen"
133
- msgstr "Plein écran"
133
+ msgstr "Plein Écran"
134
134
 
135
135
  msgid "About X_ITE"
136
136
  msgstr "À propos de X_ITE"
@@ -145,29 +145,35 @@ msgid "Fly Viewer"
145
145
  msgstr "Voler"
146
146
 
147
147
  msgid "Plane Viewer"
148
- msgstr "Visionneur de la plaine"
148
+ msgstr "Visionneur de la Plaine"
149
149
 
150
150
  msgid "Look At Viewer"
151
- msgstr "Regarder un objet de près"
151
+ msgstr "Regarder un Objet de près"
152
152
 
153
153
  msgid "None Viewer"
154
- msgstr "Pas de visionneur"
154
+ msgstr "Pas de Visionneur"
155
+
156
+ msgid "Flat"
157
+ msgstr "Plat"
158
+
159
+ msgid "Wireframe"
160
+ msgstr "Image filaire"
155
161
 
156
162
  msgid "Loading %1 file"
157
- msgstr "Télécharger %1 fichier"
163
+ msgstr "Télécharger %1 Fichier"
158
164
 
159
165
  msgid "Loading %1 files"
160
- msgstr "Télécharger %1 fichiers"
166
+ msgstr "Télécharger %1 Fichiers"
161
167
 
162
168
  msgid "Loading done"
163
169
  msgstr "Téléchargement fini"
164
170
 
165
171
  msgid "Failed loading world."
166
- msgstr "Le chargement des fichiers a échoué."
172
+ msgstr "Le chargement des Fichiers a échoué."
167
173
 
168
174
  msgid "Show World Info"
169
175
  msgstr "Afficher World Info"
170
176
 
171
177
  msgid "Viewpoint is copied to clipboard."
172
- msgstr "Le point de vue est copié dans le presse-papiers."
178
+ msgstr "Le point de Vue est copié dans le Presse-Papiers."
173
179
  `;
package/src/tests.js CHANGED
@@ -148,6 +148,7 @@ const X_ITE_TESTS = [
148
148
  { path: "Navigation/DifferentViewpoints.x3dv" },
149
149
  { path: "Navigation/Gravitation.x3d" },
150
150
  { path: "Navigation/ScreenScale.x3d" },
151
+ { path: "Navigation/ViewpointGroup.x3d" },
151
152
  { path: "Navigation/ViewpointJump.x3d" },
152
153
  { path: "Navigation/ViewpointLayers.x3d" },
153
154
  { path: "Navigation/WalkViewer.x3d" },
@@ -178,12 +178,7 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
178
178
 
179
179
  // Change function.
180
180
 
181
- Object .defineProperty (this, "getLive",
182
- {
183
- value: getLive,
184
- enumerable: false,
185
- configurable: true,
186
- });
181
+ Object .defineProperty (this, "getLive", { value: getLive });
187
182
 
188
183
  // Add isLive event.
189
184
 
@@ -194,7 +189,7 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
194
189
 
195
190
  // Connect to execution context.
196
191
 
197
- if (this .getOuterNode && this .getOuterNode ())
192
+ if (this .getOuterNode ?.())
198
193
  this .getOuterNode () .getLive () .addInterest (_set_live__, this);
199
194
 
200
195
  else if (this [_executionContext] !== this)
@@ -298,8 +293,6 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
298
293
  {
299
294
  get: function () { return field; },
300
295
  set: function (value) { field .setValue (value); },
301
- enumerable: false,
302
- configurable: false,
303
296
  });
304
297
  },
305
298
  getFieldDefinitions: function ()
@@ -325,8 +318,6 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
325
318
  {
326
319
  get: function () { return field; },
327
320
  set: function (value) { field .setValue (value); },
328
- enumerable: false,
329
- configurable: true, // false : non deletable
330
321
  });
331
322
 
332
323
  if (!this .isPrivate ())
@@ -382,7 +373,6 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
382
373
  get: function () { return field; },
383
374
  set: function (value) { field .setValue (value); },
384
375
  enumerable: true,
385
- configurable: false,
386
376
  });
387
377
 
388
378
  if (field .isInitializable ())
@@ -307,8 +307,6 @@ for (const key of Reflect .ownKeys (X3DInfoArray .prototype))
307
307
  Object .defineProperty (X3DInfoArray .prototype, "length",
308
308
  {
309
309
  get: function () { return this [_array] .length; },
310
- enumerable: false,
311
- configurable: false,
312
310
  });
313
311
 
314
312
  export default X3DInfoArray;
@@ -620,8 +620,6 @@ Object .defineProperty (X3DObjectArrayField .prototype, "length",
620
620
  {
621
621
  get: function () { return this [_target] .getValue () .length; },
622
622
  set: function (value) { this [_target] .resize (value); },
623
- enumerable: false,
624
- configurable: false,
625
623
  });
626
624
 
627
625
  export default X3DObjectArrayField;
@@ -1076,8 +1076,6 @@ Object .defineProperty (X3DTypedArrayField .prototype, "length",
1076
1076
  {
1077
1077
  get: function () { return this [_length]; },
1078
1078
  set: function (value) { this [_target] .resize (value); },
1079
- enumerable: false,
1080
- configurable: false,
1081
1079
  });
1082
1080
 
1083
1081
  // Getter/Setter functions to reference a value for a given index.