x_ite 8.6.11 → 8.6.12
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.
- package/dist/assets/components/Annotation.js +13 -13
- package/dist/assets/components/Annotation.min.js +1 -1
- package/dist/assets/components/CADGeometry.js +21 -45
- package/dist/assets/components/CADGeometry.min.js +1 -1
- package/dist/assets/components/CubeMapTexturing.js +25 -25
- package/dist/assets/components/CubeMapTexturing.min.js +1 -1
- package/dist/assets/components/DIS.js +13 -13
- package/dist/assets/components/DIS.min.js +1 -1
- package/dist/assets/components/EventUtilities.js +9 -9
- package/dist/assets/components/EventUtilities.min.js +1 -1
- package/dist/assets/components/Geometry2D.js +19 -19
- package/dist/assets/components/Geometry2D.min.js +1 -1
- package/dist/assets/components/Geospatial.js +33 -33
- package/dist/assets/components/Geospatial.min.js +1 -1
- package/dist/assets/components/HAnim.js +18 -18
- package/dist/assets/components/HAnim.min.js +1 -1
- package/dist/assets/components/KeyDeviceSensor.js +8 -8
- package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
- package/dist/assets/components/Layout.js +48 -42
- package/dist/assets/components/Layout.min.js +1 -1
- package/dist/assets/components/NURBS.js +24 -24
- package/dist/assets/components/NURBS.min.js +1 -1
- package/dist/assets/components/ParticleSystems.js +136 -26
- package/dist/assets/components/ParticleSystems.min.js +1 -1
- package/dist/assets/components/Picking.js +132 -22
- package/dist/assets/components/Picking.min.js +1 -1
- package/dist/assets/components/RigidBodyPhysics.js +32 -76
- package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
- package/dist/assets/components/Scripting.js +28 -28
- package/dist/assets/components/Scripting.min.js +1 -1
- package/dist/assets/components/Text.js +24 -24
- package/dist/assets/components/Text.min.js +1 -1
- package/dist/assets/components/TextureProjector.js +14 -14
- package/dist/assets/components/TextureProjector.min.js +1 -1
- package/dist/assets/components/Texturing3D.js +30 -30
- package/dist/assets/components/Texturing3D.min.js +1 -1
- package/dist/assets/components/VolumeRendering.js +19 -19
- package/dist/assets/components/VolumeRendering.min.js +1 -1
- package/dist/assets/components/X_ITE.js +9 -9
- package/dist/assets/components/X_ITE.min.js +1 -1
- package/dist/x_ite.css +1 -1
- package/dist/x_ite.js +284 -359
- package/dist/x_ite.min.js +1 -1
- package/dist/x_ite.zip +0 -0
- package/docs/_config.yml +1 -1
- package/docs/_posts/components/Geometry3D/IndexedFaceSet.md +1 -1
- package/docs/_posts/components/Lighting/DirectionalLight.md +4 -4
- package/docs/_posts/components/Lighting/EnvironmentLight.md +4 -4
- package/docs/_posts/components/Lighting/PointLight.md +4 -4
- package/docs/_posts/components/Lighting/SpotLight.md +4 -4
- package/docs/_posts/components/Rendering/IndexedLineSet.md +1 -1
- package/docs/_posts/components/Rendering/IndexedTriangleFanSet.md +1 -1
- package/docs/_posts/components/RigidBodyPhysics/RigidBody.md +1 -1
- package/docs/_posts/components/RigidBodyPhysics/RigidBodyCollection.md +1 -1
- package/docs/_posts/components/RigidBodyPhysics/SingleAxisHingeJoint.md +1 -1
- package/docs/_posts/components/RigidBodyPhysics/SliderJoint.md +3 -3
- package/docs/_posts/components/X_ITE/BlendMode.md +1 -1
- package/docs/_posts/getting-started.md +8 -3
- package/docs/_posts/reference/browser-services.md +1 -1
- package/docs/_posts/reference/ecmascript-object-and-function-definitions.md +16 -99
- package/docs/_posts/what's-new.md +1 -1
- package/package.json +3 -3
- package/src/lib/jquery.js +6 -1
- package/src/standard/Math/Geometry/Box3.js +2 -5
- package/src/x_ite/Base/X3DBaseNode.js +8 -0
- package/src/x_ite/Base/X3DObject.js +14 -1
- package/src/x_ite/Browser/Core/BrowserOptions.js +27 -29
- package/src/x_ite/Browser/Core/BrowserTimings.js +2 -16
- package/src/x_ite/Browser/Core/X3DCoreContext.js +5 -0
- package/src/x_ite/Browser/Navigation/X3DFlyViewer.js +3 -3
- package/src/x_ite/Browser/Networking/X3DNetworkingContext.js +20 -15
- package/src/x_ite/Browser/PointingDeviceSensor/PointingDevice.js +3 -3
- package/src/x_ite/Browser/VERSION.js +1 -1
- package/src/x_ite/Browser/X3DBrowser.js +2 -2
- package/src/x_ite/Browser/X3DBrowserContext.js +21 -12
- package/src/x_ite/Components/CADGeometry/CADFace.js +8 -32
- package/src/x_ite/Components/Core/X3DNode.js +1 -1
- package/src/x_ite/Components/Core/X3DPrototypeInstance.js +1 -1
- package/src/x_ite/Components/Grouping/StaticGroup.js +19 -0
- package/src/x_ite/Components/Grouping/Switch.js +7 -25
- package/src/x_ite/Components/Grouping/X3DBoundedObject.js +0 -1
- package/src/x_ite/Components/Layout/Layout.js +12 -10
- package/src/x_ite/Components/Layout/LayoutGroup.js +9 -5
- package/src/x_ite/Components/Navigation/LOD.js +7 -25
- package/src/x_ite/Components/Navigation/X3DViewpointNode.js +1 -1
- package/src/x_ite/Components/Rendering/X3DLineGeometryNode.js +15 -8
- package/src/x_ite/Components/RigidBodyPhysics/CollidableOffset.js +7 -29
- package/src/x_ite/Components/RigidBodyPhysics/CollidableShape.js +7 -29
- package/src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js +3 -8
- package/src/x_ite/Components/Shape/Shape.js +0 -5
- package/src/x_ite/Components/Shape/X3DShapeNode.js +21 -17
- package/src/x_ite/Fields/SFNode.js +8 -0
- package/src/x_ite/{X3DCanvas.js → X3DCanvasElement.js} +23 -4
- package/src/x_ite.js +4 -4
package/dist/x_ite.zip
CHANGED
|
Binary file
|
package/docs/_config.yml
CHANGED
|
@@ -61,7 +61,7 @@ List of texture-coordinate indices mapping attached texture to corresponding coo
|
|
|
61
61
|
- If normalPerVertex='true' then a matching set of indices is provided, each separated by sentinel -1, that exactly corresponds to individual values in the coordIndex array polygon definitions.
|
|
62
62
|
- If no child Normal node is provided, the X3D browser shall automatically generate normals, using creaseAngle to determine smoothed shading across shared vertices.
|
|
63
63
|
|
|
64
|
-
### MFInt32 [in] **set_coordIndex** <small
|
|
64
|
+
### MFInt32 [in] **set_coordIndex** <small>[0,∞) or -1</small>
|
|
65
65
|
|
|
66
66
|
**colorIndex** values define the order in which Color|ColorRGBA values are applied to polygons (or vertices).
|
|
67
67
|
|
|
@@ -68,19 +68,19 @@ Orientation vector of light relative to local coordinate system.
|
|
|
68
68
|
|
|
69
69
|
*shadows* field indicates whether or not this light casts a shadow behind illuminated X3DShapeNode geometry.
|
|
70
70
|
|
|
71
|
-
### SFColor [in, out] **shadowColor** 0 0 0 <small
|
|
71
|
+
### SFColor [in, out] **shadowColor** 0 0 0 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
72
72
|
|
|
73
73
|
Color of shadow, applied to colors of objects.
|
|
74
74
|
|
|
75
|
-
### SFFloat [in, out] **shadowIntensity** 0 <small
|
|
75
|
+
### SFFloat [in, out] **shadowIntensity** 0 <small>[0,1]</small>
|
|
76
76
|
|
|
77
77
|
*shadowIntensity* field defines how much light is obscured by shapes that cast shadows, ranging from 0 (light not obscured, no visible shadows) to 1 (light completely obscured, full-intensity shadows).
|
|
78
78
|
|
|
79
|
-
### SFFloat [in, out] **shadowBias** 0.005 <small
|
|
79
|
+
### SFFloat [in, out] **shadowBias** 0.005 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
80
80
|
|
|
81
81
|
The shadowBias value controls the visibility of *shadow acne*.
|
|
82
82
|
|
|
83
|
-
### SFInt32 [ ] **shadowMapSize** 1024 <small
|
|
83
|
+
### SFInt32 [ ] **shadowMapSize** 1024 <small>[0,∞) <span class="yellow">non standard</span></small>
|
|
84
84
|
|
|
85
85
|
Size of the shadow map in pixels, must be power of two.
|
|
86
86
|
|
|
@@ -70,19 +70,19 @@ Brightness of ambient (nondirectional background) emission from the light.
|
|
|
70
70
|
|
|
71
71
|
*shadows* field indicates whether or not this light casts a shadow behind illuminated X3DShapeNode geometry.
|
|
72
72
|
|
|
73
|
-
### SFColor [in, out] **shadowColor** 0 0 0 <small
|
|
73
|
+
### SFColor [in, out] **shadowColor** 0 0 0 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
74
74
|
|
|
75
75
|
Color of shadow, applied to colors of objects.
|
|
76
76
|
|
|
77
|
-
### SFFloat [in, out] **shadowIntensity** 0 <small
|
|
77
|
+
### SFFloat [in, out] **shadowIntensity** 0 <small>[0,1]</small>
|
|
78
78
|
|
|
79
79
|
*shadowIntensity* field defines how much light is obscured by shapes that cast shadows, ranging from 0 (light not obscured, no visible shadows) to 1 (light completely obscured, full-intensity shadows).
|
|
80
80
|
|
|
81
|
-
### SFFloat [in, out] **shadowBias** 0.005 <small
|
|
81
|
+
### SFFloat [in, out] **shadowBias** 0.005 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
82
82
|
|
|
83
83
|
The shadowBias value controls the visibility of *shadow acne*.
|
|
84
84
|
|
|
85
|
-
### SFInt32 [ ] **shadowMapSize** 1024 <small
|
|
85
|
+
### SFInt32 [ ] **shadowMapSize** 1024 <small>[0,∞) <span class="yellow">non standard</span></small>
|
|
86
86
|
|
|
87
87
|
Size of the shadow map in pixels, must be power of two.
|
|
88
88
|
|
|
@@ -72,19 +72,19 @@ Maximum effective distance of light relative to local light position, affected b
|
|
|
72
72
|
|
|
73
73
|
*shadows* field indicates whether or not this light casts a shadow behind illuminated X3DShapeNode geometry.
|
|
74
74
|
|
|
75
|
-
### SFColor [in, out] **shadowColor** 0 0 0 <small
|
|
75
|
+
### SFColor [in, out] **shadowColor** 0 0 0 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
76
76
|
|
|
77
77
|
Color of shadow, applied to colors of objects.
|
|
78
78
|
|
|
79
|
-
### SFFloat [in, out] **shadowIntensity** 0 <small
|
|
79
|
+
### SFFloat [in, out] **shadowIntensity** 0 <small>[0,1]</small>
|
|
80
80
|
|
|
81
81
|
*shadowIntensity* field defines how much light is obscured by shapes that cast shadows, ranging from 0 (light not obscured, no visible shadows) to 1 (light completely obscured, full-intensity shadows).
|
|
82
82
|
|
|
83
|
-
### SFFloat [in, out] **shadowBias** 0.005 <small
|
|
83
|
+
### SFFloat [in, out] **shadowBias** 0.005 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
84
84
|
|
|
85
85
|
The shadowBias value controls the visibility of *shadow acne*.
|
|
86
86
|
|
|
87
|
-
### SFInt32 [ ] **shadowMapSize** 1024 <small
|
|
87
|
+
### SFInt32 [ ] **shadowMapSize** 1024 <small>[0,∞) <span class="yellow">non standard</span></small>
|
|
88
88
|
|
|
89
89
|
Size of the shadow map in pixels, must be power of two.
|
|
90
90
|
|
|
@@ -101,19 +101,19 @@ Outer conical solid angle (in radians) where light source intensity becomes zero
|
|
|
101
101
|
|
|
102
102
|
*shadows* field indicates whether or not this light casts a shadow behind illuminated X3DShapeNode geometry.
|
|
103
103
|
|
|
104
|
-
### SFColor [in, out] **shadowColor** 0 0 0 <small
|
|
104
|
+
### SFColor [in, out] **shadowColor** 0 0 0 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
105
105
|
|
|
106
106
|
Color of shadow, applied to colors of objects.
|
|
107
107
|
|
|
108
|
-
### SFFloat [in, out] **shadowIntensity** 0 <small
|
|
108
|
+
### SFFloat [in, out] **shadowIntensity** 0 <small>[0,1]</small>
|
|
109
109
|
|
|
110
110
|
*shadowIntensity* field defines how much light is obscured by shapes that cast shadows, ranging from 0 (light not obscured, no visible shadows) to 1 (light completely obscured, full-intensity shadows).
|
|
111
111
|
|
|
112
|
-
### SFFloat [in, out] **shadowBias** 0.005 <small
|
|
112
|
+
### SFFloat [in, out] **shadowBias** 0.005 <small>[0,1] <span class="yellow">non standard</span></small>
|
|
113
113
|
|
|
114
114
|
The shadowBias value controls the visibility of *shadow acne*.
|
|
115
115
|
|
|
116
|
-
### SFInt32 [ ] **shadowMapSize** 1024 <small
|
|
116
|
+
### SFInt32 [ ] **shadowMapSize** 1024 <small>[0,∞) <span class="yellow">non standard</span></small>
|
|
117
117
|
|
|
118
118
|
Size of the shadow map in pixels, must be power of two.
|
|
119
119
|
|
|
@@ -41,7 +41,7 @@ Metadata are not part of the X3D world and not interpreted by the X3D browser, b
|
|
|
41
41
|
- If colorPerVertex='false' then one index is provided for each polygon defined by the coordIndex array. No sentinel -1 values are included.
|
|
42
42
|
- If colorPerVertex='true' then a matching set of indices is provided, each separated by sentinel -1, that exactly corresponds to individual
|
|
43
43
|
|
|
44
|
-
### MFInt32 [in] **set_coordIndex** <small
|
|
44
|
+
### MFInt32 [in] **set_coordIndex** <small>[0,∞) or -1</small>
|
|
45
45
|
|
|
46
46
|
**colorIndex** values define the order in which Color|ColorRGBA values are applied to polygons (or vertices).
|
|
47
47
|
|
|
@@ -32,7 +32,7 @@ The IndexedTriangleFanSet node belongs to the **Rendering** component and its de
|
|
|
32
32
|
|
|
33
33
|
Metadata are not part of the X3D world and not interpreted by the X3D browser, but they can be accessed via the ECMAScript interface.
|
|
34
34
|
|
|
35
|
-
### MFInt32 [in] **set_index** <small
|
|
35
|
+
### MFInt32 [in] **set_index** <small>[0,∞) or -1</small>
|
|
36
36
|
|
|
37
37
|
*index* list specifies triangles by connecting Coordinate vertices, each individual fan separated by -1 sentinel value.
|
|
38
38
|
|
|
@@ -114,7 +114,7 @@ Enables/disables node operation.
|
|
|
114
114
|
|
|
115
115
|
*centerOfMass* defines local center of mass for physics calculations.
|
|
116
116
|
|
|
117
|
-
### SFNode [in, out] **massDensityModel** NULL <small
|
|
117
|
+
### SFNode [in, out] **massDensityModel** NULL <small><span class="red">not supported</span></small>
|
|
118
118
|
|
|
119
119
|
Input/Output field massDensityModel.
|
|
120
120
|
|
|
@@ -35,7 +35,7 @@ Metadata are not part of the X3D world and not interpreted by the X3D browser, b
|
|
|
35
35
|
|
|
36
36
|
Enables/disables node operation.
|
|
37
37
|
|
|
38
|
-
### MFNode [in] **set_contacts**<span class="red"><small
|
|
38
|
+
### MFNode [in] **set_contacts**<span class="red"><small> not supported</small></span>
|
|
39
39
|
|
|
40
40
|
*set_contacts* input field for Contact nodes provides per-frame information about contacts between bodies.
|
|
41
41
|
|
|
@@ -47,7 +47,7 @@ Metadata are not part of the X3D world and not interpreted by the X3D browser, b
|
|
|
47
47
|
|
|
48
48
|
*minAngle* is minimum rotation angle for hinge.
|
|
49
49
|
|
|
50
|
-
### SFFloat [in, out] **maxAngle** [-π,π) <small
|
|
50
|
+
### SFFloat [in, out] **maxAngle** [-π,π) <small><span class="red">not supported</span></small>
|
|
51
51
|
|
|
52
52
|
*maxAngle* is maximum rotation angle for hinge.
|
|
53
53
|
|
|
@@ -55,7 +55,7 @@ Metadata are not part of the X3D world and not interpreted by the X3D browser, b
|
|
|
55
55
|
|
|
56
56
|
- If (minSeparation is less than maxSeparation) then no stop is effective.
|
|
57
57
|
|
|
58
|
-
### SFFLoat [in, out] **sliderForce** 0 <span class="red"><small
|
|
58
|
+
### SFFLoat [in, out] **sliderForce** 0 <span class="red"><small>not supported</small></span>
|
|
59
59
|
|
|
60
60
|
Input/Output field sliderForce.
|
|
61
61
|
|
|
@@ -75,11 +75,11 @@ Input/Output field sliderForce.
|
|
|
75
75
|
|
|
76
76
|
- 0 means no error correction, 1 means all error corrected in single step.
|
|
77
77
|
|
|
78
|
-
### SFFloat [out] **separation** <span class="red"><small
|
|
78
|
+
### SFFloat [out] **separation** <span class="red"><small>not supported</small></span>
|
|
79
79
|
|
|
80
80
|
*separation* indicates final separation distance between the two bodies.
|
|
81
81
|
|
|
82
|
-
### SFFloat [out] **separationRate** <span class="red"><small
|
|
82
|
+
### SFFloat [out] **separationRate** <span class="red"><small>not supported</small></span>
|
|
83
83
|
|
|
84
84
|
*separationRate* indicates change in separation distance over time between the two bodies.
|
|
85
85
|
|
|
@@ -32,7 +32,7 @@ The BlendMode node belongs to the **X_ITE** component and its default container
|
|
|
32
32
|
|
|
33
33
|
Metadata are not part of the X3D world and not interpreted by the X3D browser, but they can be accessed via the ECMAScript interface.
|
|
34
34
|
|
|
35
|
-
### SFColorRGBA [in, out] **blendColor** 0 0 0 0 <small
|
|
35
|
+
### SFColorRGBA [in, out] **blendColor** 0 0 0 0 <small>[0,1]</small><small></small>
|
|
36
36
|
|
|
37
37
|
The *blendColor* may be used to calculate the source and destination blending factors.
|
|
38
38
|
|
|
@@ -12,7 +12,8 @@ x_ite: true
|
|
|
12
12
|
src="/x_ite/assets/X3D/teaser/teaser.x3d"
|
|
13
13
|
splashScreen="false"
|
|
14
14
|
contextMenu="false"
|
|
15
|
-
notifications="false"
|
|
15
|
+
notifications="false"
|
|
16
|
+
timings="false">
|
|
16
17
|
</x3d-canvas>
|
|
17
18
|
|
|
18
19
|
## Overview
|
|
@@ -724,11 +725,15 @@ A Boolean value (`true` or `false`) to indicate whether the splash screen should
|
|
|
724
725
|
|
|
725
726
|
### src
|
|
726
727
|
|
|
727
|
-
A String value
|
|
728
|
+
A String value containing the URL to load on page load. If no *src* attribute is specified or the *src* attribute is empty, an empty scene will be displayed.
|
|
729
|
+
|
|
730
|
+
### timings
|
|
731
|
+
|
|
732
|
+
A Boolean value (`true` or `false`) to indicate whether the Timings Panel should be displayed. The default value for the *timings* attribute is restored from the previous session, otherwise it is `false`.
|
|
728
733
|
|
|
729
734
|
### url
|
|
730
735
|
|
|
731
|
-
A MFString value
|
|
736
|
+
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.
|
|
732
737
|
|
|
733
738
|
### Example
|
|
734
739
|
|
|
@@ -363,7 +363,7 @@ Adds a browser *callback* function associated with *key,* where *key* can be of
|
|
|
363
363
|
|
|
364
364
|
Removes a browser callback function associated with *key*.
|
|
365
365
|
|
|
366
|
-
#### void **viewAll** (*[SFNode layerNode]*)
|
|
366
|
+
#### void **viewAll** (*[SFNode layerNode]*) <small><span class="yellow">non standard</span></small>
|
|
367
367
|
|
|
368
368
|
Modifies the current view to show the entire visible scene. If *layerNode* is omitted, the active layer is used.
|
|
369
369
|
|
|
@@ -9,6 +9,7 @@ tags: [Ecmascript, Object, Function, Definitions]
|
|
|
9
9
|
|
|
10
10
|
There are a fixed set of objects in ECMAScript, each of which have a fixed set of properties (i.e. values) and methods (i.e. functions). For all object types except Math, there are functions to create an instance of the object. The supported set of objects are:
|
|
11
11
|
|
|
12
|
+
* [X3DCanvasElement](#x3dcanvaselement)
|
|
12
13
|
* [Browser Services](browser-services)
|
|
13
14
|
* [Scene Services](scene-services)
|
|
14
15
|
* [Field Services and Objects](field-services-and-objects)
|
|
@@ -16,118 +17,34 @@ There are a fixed set of objects in ECMAScript, each of which have a fixed set o
|
|
|
16
17
|
* [Prototype Services](prototype-services)
|
|
17
18
|
* [Constants Services](constants-services)
|
|
18
19
|
|
|
19
|
-
|
|
20
|
+
## X3DCanvasElement
|
|
20
21
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
#### Number **parseInt** (*s, [radix]*)
|
|
24
|
-
|
|
25
|
-
Converts the passed String, 's', to an integer valued number, using the optional passed numeric 'radix' as the base. If the radix is omitted base 10 is assumed. Numbers can be in decimal (123), hexadecimal (0x5C) or octal (0177) notation and may be preceded by a minus sign ('-'). Conversion stops at the first unrecognized character. If the string begins with an unrecognized character, 0 is returned.
|
|
26
|
-
|
|
27
|
-
#### Number **parseFloat** (*s*)
|
|
28
|
-
|
|
29
|
-
Converts the passed String, 's', to a floating point valued number. Numbers can be in fixed (1.23) or exponential (12E3) notation and both the mantissa and exponent may be preceded by a minus sign ('-'). Conversion stops at the first unrecognized character. If the string begins with an unrecognized character, 0 is returned.
|
|
30
|
-
|
|
31
|
-
## Math Object
|
|
32
|
-
|
|
33
|
-
The Math object is unique in ECMAScript in that there is exactly one globally available instance of the object, named Math. Properties can be accessed using the syntax Math.\<property-name\>. Methods can be invoked using the syntax Math.\<function-name\> ( \<argument-list\> ).
|
|
22
|
+
The X3DCanvasElement, \<x3d-canvas\>, is the main element that displays the X3D content. It defines some functions to be used with this object.
|
|
34
23
|
|
|
35
24
|
### Instance Creation Method\(s\)
|
|
36
25
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
### Properties
|
|
40
|
-
|
|
41
|
-
#### **E**
|
|
42
|
-
|
|
43
|
-
Euler's constant, e, approximately 2.718.
|
|
44
|
-
|
|
45
|
-
#### **LN10**
|
|
46
|
-
|
|
47
|
-
Natural logarithm of 10, approximately 2.302.
|
|
26
|
+
An \<x3d-canvas\> can be created with the `document.createElement` function to get a reference to an X3DCanvasElement.
|
|
48
27
|
|
|
49
|
-
|
|
28
|
+
```js
|
|
29
|
+
const canvas = document .createElement ("x3d-canvas")
|
|
30
|
+
```
|
|
50
31
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
#### **PI**
|
|
54
|
-
|
|
55
|
-
Ratio of the circumference of a circle to its diameter, approximately 3.1415.
|
|
56
|
-
|
|
57
|
-
#### **SQRT1_2**
|
|
58
|
-
|
|
59
|
-
Square root of ½, approximately 0.707.
|
|
32
|
+
### Properties
|
|
60
33
|
|
|
61
|
-
#### **
|
|
34
|
+
#### **browser**
|
|
62
35
|
|
|
63
|
-
|
|
36
|
+
A reference to the X3DBrowser object that is associated with this element.
|
|
64
37
|
|
|
65
38
|
### Methods
|
|
66
39
|
|
|
67
|
-
#### **
|
|
68
|
-
|
|
69
|
-
Returns the absolute value of *number.*
|
|
70
|
-
|
|
71
|
-
#### **acos** (number)
|
|
72
|
-
|
|
73
|
-
Returns the arc cosine (in radians) of *number.*
|
|
74
|
-
|
|
75
|
-
#### **asin** (number)
|
|
76
|
-
|
|
77
|
-
Returns the arc sine (in radians) of *number.*
|
|
78
|
-
|
|
79
|
-
#### **atan** (number)
|
|
80
|
-
|
|
81
|
-
Returns the arc tangent (in radians) of *number.*
|
|
82
|
-
|
|
83
|
-
#### **ceil** (number)
|
|
84
|
-
|
|
85
|
-
Returns the least integer greater than or equal to *number.*
|
|
86
|
-
|
|
87
|
-
#### **cos** (number)
|
|
88
|
-
|
|
89
|
-
Returns the cosine of *number* where *number* is expressed in radians.
|
|
90
|
-
|
|
91
|
-
#### **exp** (*number*)
|
|
92
|
-
|
|
93
|
-
Returns *e,* to the power of *number* (i.e. *e*<sup>*number*</sup>).
|
|
94
|
-
|
|
95
|
-
#### **floor** (*number*)
|
|
96
|
-
|
|
97
|
-
Returns the greatest integer less than or equal to its argument.
|
|
98
|
-
|
|
99
|
-
#### **log** (*number)*
|
|
100
|
-
|
|
101
|
-
Returns the natural logarithm (base *e*) of *number.*
|
|
102
|
-
|
|
103
|
-
#### **max** (*number1*, *number2*)
|
|
104
|
-
|
|
105
|
-
Returns the greater of *number1* and *number2.*
|
|
106
|
-
|
|
107
|
-
#### **min** (*number1*, *number2*)
|
|
108
|
-
|
|
109
|
-
Returns the lesser of *number1* and *number2.*
|
|
110
|
-
|
|
111
|
-
#### **pow** (*base*, *exponent*)
|
|
112
|
-
|
|
113
|
-
Returns *base* to the *exponent* power (i.e. *base*<sup>*exponent*</sup>).
|
|
114
|
-
|
|
115
|
-
#### **random** ()
|
|
116
|
-
|
|
117
|
-
Returns a pseudo-random number between zero and one.
|
|
118
|
-
|
|
119
|
-
#### **round** (*number*)
|
|
120
|
-
|
|
121
|
-
Returns the value of *number* rounded to the nearest integer.
|
|
122
|
-
|
|
123
|
-
#### **sin** (*number*)
|
|
40
|
+
#### MediaStream **captureStream** (*[Number frameRate]*)
|
|
124
41
|
|
|
125
|
-
|
|
42
|
+
See [HTMLCanvasElement.captureStream()](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/captureStream){:target="_blank"}.
|
|
126
43
|
|
|
127
|
-
#### **
|
|
44
|
+
#### Blob **toBlob** (*Function callback, [String type, Number quality]*)
|
|
128
45
|
|
|
129
|
-
|
|
46
|
+
See [HTMLCanvasElement.toBlob()](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toBlob){:target="_blank"}.
|
|
130
47
|
|
|
131
|
-
#### **
|
|
48
|
+
#### String **toDataURL** (*[String type, Number encoderOptions]*)
|
|
132
49
|
|
|
133
|
-
|
|
50
|
+
See [HTMLCanvasElement.toDataURL()](https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement/toDataURL){:target="_blank"}.
|
|
@@ -906,7 +906,7 @@ You can tune the *shadowIntensity*. It is the intensity of the shadow. 0 means n
|
|
|
906
906
|
|
|
907
907
|

|
|
908
908
|
|
|
909
|
-
<small
|
|
909
|
+
<small>Dynamic shadows in X_ITE</small>
|
|
910
910
|
|
|
911
911
|
## X_ITE v4.1.7 Released
|
|
912
912
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x_ite",
|
|
3
|
-
"version": "8.6.
|
|
3
|
+
"version": "8.6.12",
|
|
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>",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"dicom-parser": "^1.8.21",
|
|
61
61
|
"jpeg-js": "^0.4.4",
|
|
62
62
|
"jpeg-lossless-decoder-js": "^2.0.4",
|
|
63
|
-
"jquery": "^3.6.
|
|
63
|
+
"jquery": "^3.6.4",
|
|
64
64
|
"jquery-fullscreen-plugin": "^1.1.5",
|
|
65
65
|
"jquery-mousewheel": "^3.1.13",
|
|
66
66
|
"libgif": "^0.0.3",
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
"opentype.js": "^1.3.4",
|
|
72
72
|
"pako": "^2.1.0",
|
|
73
73
|
"string-replace-webpack-plugin": "^0.1.3",
|
|
74
|
-
"webpack": "^5.
|
|
74
|
+
"webpack": "^5.76.3",
|
|
75
75
|
"webpack-cli": "^5.0.1",
|
|
76
76
|
"webpack-shell-plugin-next": "^2.3.1"
|
|
77
77
|
},
|
package/src/lib/jquery.js
CHANGED
|
@@ -157,11 +157,8 @@ Box3 .prototype =
|
|
|
157
157
|
p2 = r1 .subtract (x),
|
|
158
158
|
p3 = r2 .subtract (x);
|
|
159
159
|
|
|
160
|
-
min .assign (p1);
|
|
161
|
-
max .assign (p1);
|
|
162
|
-
|
|
163
|
-
min .min (p2, p3, p4);
|
|
164
|
-
max .max (p2, p3, p4);
|
|
160
|
+
min .assign (p1) .min (p2, p3, p4);
|
|
161
|
+
max .assign (p1) .max (p2, p3, p4);
|
|
165
162
|
|
|
166
163
|
p1 .negate ();
|
|
167
164
|
p2 .negate ();
|
|
@@ -149,6 +149,14 @@ X3DBaseNode .prototype = Object .assign (Object .create (X3DEventObject .prototy
|
|
|
149
149
|
{
|
|
150
150
|
return this;
|
|
151
151
|
},
|
|
152
|
+
beginUpdate: function ()
|
|
153
|
+
{
|
|
154
|
+
this .setLive (true);
|
|
155
|
+
},
|
|
156
|
+
endUpdate: function ()
|
|
157
|
+
{
|
|
158
|
+
this .setLive (false);
|
|
159
|
+
},
|
|
152
160
|
isLive: (function ()
|
|
153
161
|
{
|
|
154
162
|
function isLive ()
|
|
@@ -51,7 +51,8 @@ import MapUtilities from "../../standard/Utility/MapUtilities.js";
|
|
|
51
51
|
const
|
|
52
52
|
_name = Symbol (),
|
|
53
53
|
_interests = Symbol (),
|
|
54
|
-
_values = Symbol ()
|
|
54
|
+
_values = Symbol (),
|
|
55
|
+
_userData = Symbol ();
|
|
55
56
|
|
|
56
57
|
function X3DObject () { }
|
|
57
58
|
|
|
@@ -61,6 +62,7 @@ X3DObject .prototype =
|
|
|
61
62
|
[_name]: "",
|
|
62
63
|
[_interests]: new Map (),
|
|
63
64
|
[_values]: [ ],
|
|
65
|
+
[_userData]: new Map (),
|
|
64
66
|
getId: function ()
|
|
65
67
|
{
|
|
66
68
|
return X3DObject .getId (this);
|
|
@@ -122,6 +124,17 @@ X3DObject .prototype =
|
|
|
122
124
|
interest ();
|
|
123
125
|
}
|
|
124
126
|
},
|
|
127
|
+
getUserData: function (key)
|
|
128
|
+
{
|
|
129
|
+
return this [_userData] .get (key);
|
|
130
|
+
},
|
|
131
|
+
setUserData: function (key, value)
|
|
132
|
+
{
|
|
133
|
+
if (this [_userData] === X3DObject .prototype [_userData])
|
|
134
|
+
this [_userData] = new Map ();
|
|
135
|
+
|
|
136
|
+
this [_userData] .set (key, value);
|
|
137
|
+
},
|
|
125
138
|
toString: function (options = Object .prototype)
|
|
126
139
|
{
|
|
127
140
|
const generator = new Generator (options);
|
|
@@ -91,6 +91,7 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
91
91
|
new X3DFieldDefinition (X3DConstants .inputOutput, "LogarithmicDepthBuffer", new Fields .SFBool ()),
|
|
92
92
|
new X3DFieldDefinition (X3DConstants .inputOutput, "Notifications", new Fields .SFBool (true)),
|
|
93
93
|
new X3DFieldDefinition (X3DConstants .inputOutput, "Multisampling", new Fields .SFInt32 (4)),
|
|
94
|
+
new X3DFieldDefinition (X3DConstants .inputOutput, "OptimizeStaticGroup", new Fields .SFBool (true)),
|
|
94
95
|
new X3DFieldDefinition (X3DConstants .inputOutput, "StraightenHorizon", new Fields .SFBool (true)),
|
|
95
96
|
new X3DFieldDefinition (X3DConstants .inputOutput, "Timings", new Fields .SFBool ()),
|
|
96
97
|
]),
|
|
@@ -133,7 +134,7 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
133
134
|
},
|
|
134
135
|
configure: (function ()
|
|
135
136
|
{
|
|
136
|
-
const
|
|
137
|
+
const attributes = new Set ([
|
|
137
138
|
"Antialiased",
|
|
138
139
|
"Cache",
|
|
139
140
|
"ContentScale",
|
|
@@ -144,6 +145,14 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
144
145
|
"SplashScreen",
|
|
145
146
|
]);
|
|
146
147
|
|
|
148
|
+
const restorable = new Set ([
|
|
149
|
+
"PrimitiveQuality",
|
|
150
|
+
"Rubberband",
|
|
151
|
+
"StraightenHorizon",
|
|
152
|
+
"TextureQuality",
|
|
153
|
+
"Timings",
|
|
154
|
+
]);
|
|
155
|
+
|
|
147
156
|
return function ()
|
|
148
157
|
{
|
|
149
158
|
const
|
|
@@ -152,15 +161,28 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
152
161
|
|
|
153
162
|
for (const { name, value } of this .getFieldDefinitions ())
|
|
154
163
|
{
|
|
155
|
-
if (
|
|
164
|
+
if (attributes .has (name))
|
|
156
165
|
{
|
|
157
|
-
const
|
|
158
|
-
|
|
166
|
+
const
|
|
167
|
+
attribute = $.toLowerCaseFirst (name),
|
|
168
|
+
value = browser .getElement () .attr (attribute);
|
|
169
|
+
|
|
170
|
+
browser .attributeChangedCallback (attribute, null, value);
|
|
171
|
+
|
|
159
172
|
continue;
|
|
160
173
|
}
|
|
161
174
|
|
|
162
|
-
if (
|
|
175
|
+
if (restorable .has (name))
|
|
176
|
+
{
|
|
177
|
+
const
|
|
178
|
+
value = localStorage [name],
|
|
179
|
+
field = this .getField (name);
|
|
180
|
+
|
|
181
|
+
if (value !== field .getValue ())
|
|
182
|
+
field .setValue (value);
|
|
183
|
+
|
|
163
184
|
continue;
|
|
185
|
+
}
|
|
164
186
|
|
|
165
187
|
const field = this .getField (name);
|
|
166
188
|
|
|
@@ -169,28 +191,6 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
169
191
|
|
|
170
192
|
field .assign (value);
|
|
171
193
|
}
|
|
172
|
-
|
|
173
|
-
const
|
|
174
|
-
rubberband = localStorage .Rubberband,
|
|
175
|
-
primitiveQuality = localStorage .PrimitiveQuality,
|
|
176
|
-
textureQuality = localStorage .TextureQuality,
|
|
177
|
-
straightenHorizon = localStorage .StraightenHorizon,
|
|
178
|
-
timings = localStorage .Timings;
|
|
179
|
-
|
|
180
|
-
if (rubberband !== this ._Rubberband .getValue ())
|
|
181
|
-
this ._Rubberband = rubberband;
|
|
182
|
-
|
|
183
|
-
if (primitiveQuality !== this ._PrimitiveQuality .getValue ())
|
|
184
|
-
this ._PrimitiveQuality = primitiveQuality;
|
|
185
|
-
|
|
186
|
-
if (textureQuality !== this ._TextureQuality .getValue ())
|
|
187
|
-
this ._TextureQuality = textureQuality;
|
|
188
|
-
|
|
189
|
-
if (straightenHorizon !== this ._StraightenHorizon .getValue ())
|
|
190
|
-
this ._StraightenHorizon = straightenHorizon;
|
|
191
|
-
|
|
192
|
-
if (timings !== this ._Timings .getValue ())
|
|
193
|
-
this ._Timings = timings;
|
|
194
194
|
};
|
|
195
195
|
})(),
|
|
196
196
|
getPrimitiveQuality: function ()
|
|
@@ -323,8 +323,6 @@ BrowserOptions .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
323
323
|
set_timings__: function (timings)
|
|
324
324
|
{
|
|
325
325
|
this .localStorage .Timings = timings .getValue ();
|
|
326
|
-
|
|
327
|
-
this .getBrowser () .getBrowserTimings () .setEnabled (timings .getValue ());
|
|
328
326
|
},
|
|
329
327
|
});
|
|
330
328
|
|
|
@@ -54,7 +54,6 @@ function BrowserTimings (executionContext)
|
|
|
54
54
|
X3DBaseNode .call (this, executionContext);
|
|
55
55
|
|
|
56
56
|
this .localStorage = this .getBrowser () .getLocalStorage () .addNameSpace ("BrowserTimings.");
|
|
57
|
-
this .enabled = false;
|
|
58
57
|
this .fps = new StopWatch ();
|
|
59
58
|
this .localeOptions = { minimumFractionDigits: 2, maximumFractionDigits: 2 };
|
|
60
59
|
}
|
|
@@ -78,7 +77,7 @@ BrowserTimings .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
78
77
|
{
|
|
79
78
|
X3DBaseNode .prototype .initialize .call (this);
|
|
80
79
|
|
|
81
|
-
this .getBrowser () .getBrowserOptions () .
|
|
80
|
+
this .getBrowser () .getBrowserOptions () ._Timings .addInterest ("set_enabled__", this);
|
|
82
81
|
|
|
83
82
|
this .localStorage .addDefaultValues ({ type: "LESS" });
|
|
84
83
|
|
|
@@ -94,22 +93,9 @@ BrowserTimings .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
94
93
|
|
|
95
94
|
this .set_button__ ();
|
|
96
95
|
},
|
|
97
|
-
getEnabled: function ()
|
|
98
|
-
{
|
|
99
|
-
return this .enabled;
|
|
100
|
-
},
|
|
101
|
-
setEnabled: function (enabled)
|
|
102
|
-
{
|
|
103
|
-
if (this .enabled === enabled)
|
|
104
|
-
return;
|
|
105
|
-
|
|
106
|
-
this .enabled = enabled;
|
|
107
|
-
|
|
108
|
-
this .set_enabled__ ();
|
|
109
|
-
},
|
|
110
96
|
set_enabled__: function ()
|
|
111
97
|
{
|
|
112
|
-
if (this .
|
|
98
|
+
if (this .getBrowser () .getBrowserOption ("Timings"))
|
|
113
99
|
{
|
|
114
100
|
this .element .stop (true, true) .fadeIn ();
|
|
115
101
|
this .fps .reset ();
|