x_ite 11.5.7 → 11.5.9
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/README.md +13 -8
- package/dist/assets/components/AnnotationComponent.js +2 -2
- package/dist/assets/components/AnnotationComponent.min.js +2 -2
- package/dist/assets/components/CADGeometryComponent.js +2 -2
- package/dist/assets/components/CADGeometryComponent.min.js +2 -2
- package/dist/assets/components/CubeMapTexturingComponent.js +2 -2
- package/dist/assets/components/CubeMapTexturingComponent.min.js +2 -2
- package/dist/assets/components/DISComponent.js +2 -2
- package/dist/assets/components/DISComponent.min.js +2 -2
- package/dist/assets/components/EventUtilitiesComponent.js +2 -2
- package/dist/assets/components/EventUtilitiesComponent.min.js +2 -2
- package/dist/assets/components/Geometry2DComponent.js +8 -8
- package/dist/assets/components/Geometry2DComponent.min.js +2 -2
- package/dist/assets/components/GeospatialComponent.js +4 -4
- package/dist/assets/components/GeospatialComponent.min.js +2 -2
- package/dist/assets/components/HAnimComponent.js +2 -2
- package/dist/assets/components/HAnimComponent.min.js +2 -2
- package/dist/assets/components/KeyDeviceSensorComponent.js +2 -2
- package/dist/assets/components/KeyDeviceSensorComponent.min.js +2 -2
- package/dist/assets/components/LayoutComponent.js +6 -6
- package/dist/assets/components/LayoutComponent.min.js +2 -2
- package/dist/assets/components/NURBSComponent.js +2 -2
- package/dist/assets/components/NURBSComponent.min.js +2 -2
- package/dist/assets/components/ParticleSystemsComponent.js +5 -42
- package/dist/assets/components/ParticleSystemsComponent.min.js +2 -2
- package/dist/assets/components/PickingComponent.js +4 -4
- package/dist/assets/components/PickingComponent.min.js +2 -2
- package/dist/assets/components/RigidBodyPhysicsComponent.js +4 -4
- package/dist/assets/components/RigidBodyPhysicsComponent.min.js +2 -2
- package/dist/assets/components/ScriptingComponent.js +2 -2
- package/dist/assets/components/ScriptingComponent.min.js +2 -2
- package/dist/assets/components/TextComponent.js +5 -5
- package/dist/assets/components/TextComponent.min.js +2 -2
- package/dist/assets/components/TextureProjectionComponent.js +2 -2
- package/dist/assets/components/TextureProjectionComponent.min.js +2 -2
- package/dist/assets/components/Texturing3DComponent.js +4469 -4439
- package/dist/assets/components/Texturing3DComponent.min.js +2 -2
- package/dist/assets/components/VolumeRenderingComponent.js +145 -69
- package/dist/assets/components/VolumeRenderingComponent.min.js +2 -2
- package/dist/assets/components/WebXRComponent.js +3 -3
- package/dist/assets/components/WebXRComponent.min.js +2 -2
- package/dist/assets/components/X_ITEComponent.js +2 -3
- package/dist/assets/components/X_ITEComponent.min.js +2 -2
- package/dist/assets/lib/draco_decoder_gltf.js +1 -1
- package/dist/assets/lib/libktx.js +1 -1
- package/dist/example.html +1 -1
- package/dist/x_ite.css +1 -1
- package/dist/x_ite.js +55510 -55478
- package/dist/x_ite.min.js +2 -2
- package/dist/x_ite.min.mjs +2 -2
- package/dist/x_ite.mjs +54636 -54604
- package/dist/x_ite.zip +0 -0
- package/package.json +3 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/* X_ITE v11.5.
|
|
2
|
-
const __X_ITE_X3D__ = window [Symbol .for ("X_ITE.X3D-11.5.
|
|
1
|
+
/* X_ITE v11.5.9 */
|
|
2
|
+
const __X_ITE_X3D__ = window [Symbol .for ("X_ITE.X3D-11.5.9")];
|
|
3
3
|
/******/ (() => { // webpackBootstrap
|
|
4
4
|
/******/ "use strict";
|
|
5
5
|
/******/ // The require scope
|
|
@@ -1919,13 +1919,17 @@ function X3DVolumeDataNode (executionContext)
|
|
|
1919
1919
|
this .groupNode = privateScene .createNode ("Group", false);
|
|
1920
1920
|
this .proximitySensorNode = privateScene .createNode ("ProximitySensor", false);
|
|
1921
1921
|
this .transformNode = privateScene .createNode ("Transform", false);
|
|
1922
|
-
this .shapeNode = privateScene .createNode ("Shape", false);
|
|
1923
|
-
this .appearanceNode = privateScene .createNode ("Appearance", false);
|
|
1924
|
-
this .textureTransformNode = privateScene .createNode ("TextureTransform3D", false);
|
|
1925
|
-
this .geometryNode = privateScene .createNode ("QuadSet", false);
|
|
1926
|
-
this .textureCoordinateNode = privateScene .createNode ("TextureCoordinate3D", false);
|
|
1927
|
-
this .coordinateNode = privateScene .createNode ("Coordinate", false);
|
|
1928
1922
|
this .volumeMaterialNode = new VolumeRendering_VolumeMaterial (privateScene, this);
|
|
1923
|
+
this .textureTransformNode = privateScene .createNode ("TextureTransform3D", false);
|
|
1924
|
+
this .appearanceNode = privateScene .createNode ("Appearance", false);
|
|
1925
|
+
this .lowShapeNode = privateScene .createNode ("Shape", false);
|
|
1926
|
+
this .lowGeometryNode = privateScene .createNode ("QuadSet", false);
|
|
1927
|
+
this .lowTextureCoordinateNode = privateScene .createNode ("TextureCoordinate3D", false);
|
|
1928
|
+
this .lowCoordinateNode = privateScene .createNode ("Coordinate", false);
|
|
1929
|
+
this .hiShapeNode = privateScene .createNode ("Shape", false);
|
|
1930
|
+
this .hiGeometryNode = privateScene .createNode ("QuadSet", false);
|
|
1931
|
+
this .hiTextureCoordinateNode = privateScene .createNode ("TextureCoordinate3D", false);
|
|
1932
|
+
this .hiCoordinateNode = privateScene .createNode ("Coordinate", false);
|
|
1929
1933
|
this .textureNormalMatrixArray = new Float32Array (9);
|
|
1930
1934
|
}
|
|
1931
1935
|
|
|
@@ -1945,43 +1949,68 @@ Object .assign (Object .setPrototypeOf (X3DVolumeDataNode .prototype, (external_
|
|
|
1945
1949
|
|
|
1946
1950
|
this .proximitySensorNode ._orientation_changed .addFieldInterest (this .transformNode ._rotation);
|
|
1947
1951
|
this .proximitySensorNode ._orientation_changed .addFieldInterest (this .textureTransformNode ._rotation);
|
|
1952
|
+
this .proximitySensorNode ._isActive .addInterest ("set_active__", this);
|
|
1948
1953
|
|
|
1949
|
-
this .groupNode ._children
|
|
1950
|
-
this .
|
|
1951
|
-
|
|
1952
|
-
this .
|
|
1953
|
-
this .
|
|
1954
|
-
this .shapeNode ._appearance = this .appearanceNode;
|
|
1955
|
-
this .shapeNode ._geometry = this .geometryNode;
|
|
1954
|
+
this .groupNode ._children = [this .proximitySensorNode, this .transformNode];
|
|
1955
|
+
this .transformNode ._children = [this .lowShapeNode, this .hiShapeNode];
|
|
1956
|
+
|
|
1957
|
+
this .textureTransformNode ._translation = new (external_X_ITE_X3D_Fields_default()).SFVec3f (0.5, 0.5, 0.5);
|
|
1958
|
+
this .textureTransformNode ._center = new (external_X_ITE_X3D_Fields_default()).SFVec3f (-0.5, -0.5, -0.5);
|
|
1956
1959
|
this .appearanceNode ._alphaMode = "BLEND";
|
|
1957
1960
|
this .appearanceNode ._material = this .volumeMaterialNode;
|
|
1958
1961
|
this .appearanceNode ._textureTransform = this .textureTransformNode;
|
|
1959
|
-
|
|
1960
|
-
this .
|
|
1961
|
-
this .
|
|
1962
|
-
this .
|
|
1963
|
-
|
|
1964
|
-
this .
|
|
1965
|
-
this .
|
|
1966
|
-
this .
|
|
1967
|
-
|
|
1968
|
-
this .
|
|
1969
|
-
this .
|
|
1970
|
-
this .
|
|
1971
|
-
this .
|
|
1972
|
-
this .
|
|
1973
|
-
this .
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
this .
|
|
1977
|
-
this .
|
|
1978
|
-
this .
|
|
1979
|
-
|
|
1980
|
-
this .
|
|
1981
|
-
this .
|
|
1982
|
-
this .
|
|
1983
|
-
this .
|
|
1984
|
-
|
|
1962
|
+
|
|
1963
|
+
this .lowShapeNode ._pointerEvents = false;
|
|
1964
|
+
this .lowShapeNode ._castShadow = false;
|
|
1965
|
+
this .lowShapeNode ._visible = false;
|
|
1966
|
+
this .lowShapeNode ._appearance = this .appearanceNode;
|
|
1967
|
+
this .lowShapeNode ._geometry = this .lowGeometryNode;
|
|
1968
|
+
this .lowGeometryNode ._texCoord = this .lowTextureCoordinateNode;
|
|
1969
|
+
this .lowGeometryNode ._coord = this .lowCoordinateNode;
|
|
1970
|
+
|
|
1971
|
+
this .hiShapeNode ._pointerEvents = false;
|
|
1972
|
+
this .hiShapeNode ._castShadow = false;
|
|
1973
|
+
this .hiShapeNode ._visible = false;
|
|
1974
|
+
this .hiShapeNode ._appearance = this .appearanceNode;
|
|
1975
|
+
this .hiShapeNode ._geometry = this .hiGeometryNode;
|
|
1976
|
+
this .hiGeometryNode ._texCoord = this .hiTextureCoordinateNode;
|
|
1977
|
+
this .hiGeometryNode ._coord = this .hiCoordinateNode;
|
|
1978
|
+
|
|
1979
|
+
this .volumeMaterialNode .setPrivate (true);
|
|
1980
|
+
this .textureTransformNode .setPrivate (true);
|
|
1981
|
+
this .appearanceNode .setPrivate (true);
|
|
1982
|
+
|
|
1983
|
+
this .lowCoordinateNode .setPrivate (true);
|
|
1984
|
+
this .lowTextureCoordinateNode .setPrivate (true);
|
|
1985
|
+
this .lowGeometryNode .setPrivate (true);
|
|
1986
|
+
this .lowShapeNode .setPrivate (true);
|
|
1987
|
+
|
|
1988
|
+
this .hiCoordinateNode .setPrivate (true);
|
|
1989
|
+
this .hiTextureCoordinateNode .setPrivate (true);
|
|
1990
|
+
this .hiGeometryNode .setPrivate (true);
|
|
1991
|
+
this .hiShapeNode .setPrivate (true);
|
|
1992
|
+
|
|
1993
|
+
this .transformNode .setPrivate (true);
|
|
1994
|
+
this .proximitySensorNode .setPrivate (true);
|
|
1995
|
+
this .groupNode .setPrivate (true);
|
|
1996
|
+
|
|
1997
|
+
this .volumeMaterialNode .setup ();
|
|
1998
|
+
this .textureTransformNode .setup ();
|
|
1999
|
+
this .appearanceNode .setup ();
|
|
2000
|
+
|
|
2001
|
+
this .lowCoordinateNode .setup ();
|
|
2002
|
+
this .lowTextureCoordinateNode .setup ();
|
|
2003
|
+
this .lowGeometryNode .setup ();
|
|
2004
|
+
this .lowShapeNode .setup ();
|
|
2005
|
+
|
|
2006
|
+
this .hiCoordinateNode .setup ();
|
|
2007
|
+
this .hiTextureCoordinateNode .setup ();
|
|
2008
|
+
this .hiGeometryNode .setup ();
|
|
2009
|
+
this .hiShapeNode .setup ();
|
|
2010
|
+
|
|
2011
|
+
this .transformNode .setup ();
|
|
2012
|
+
this .proximitySensorNode .setup ();
|
|
2013
|
+
this .groupNode .setup ();
|
|
1985
2014
|
|
|
1986
2015
|
this .connectChildNode (this .groupNode);
|
|
1987
2016
|
|
|
@@ -1990,12 +2019,13 @@ Object .assign (Object .setPrototypeOf (X3DVolumeDataNode .prototype, (external_
|
|
|
1990
2019
|
|
|
1991
2020
|
this .getLive () .addInterest ("set_live__", this, true);
|
|
1992
2021
|
|
|
1993
|
-
this ._dimensions
|
|
2022
|
+
this ._dimensions .addInterest ("set_dimensions__", this);
|
|
1994
2023
|
this .textureTransformNode .addInterest ("set_textureTransform__", this);
|
|
1995
2024
|
|
|
1996
2025
|
this .set_live__ (false);
|
|
1997
2026
|
this .set_dimensions__ ();
|
|
1998
2027
|
this .set_textureTransform__ ();
|
|
2028
|
+
this .set_active__ ();
|
|
1999
2029
|
},
|
|
2000
2030
|
getBBox (bbox, shadows)
|
|
2001
2031
|
{
|
|
@@ -2016,25 +2046,37 @@ Object .assign (Object .setPrototypeOf (X3DVolumeDataNode .prototype, (external_
|
|
|
2016
2046
|
{
|
|
2017
2047
|
uniformNames .push ("x3d_TextureNormalMatrix");
|
|
2018
2048
|
},
|
|
2019
|
-
getNumPlanes ()
|
|
2049
|
+
getNumPlanes (quality)
|
|
2020
2050
|
{
|
|
2021
|
-
switch (
|
|
2051
|
+
switch (quality)
|
|
2022
2052
|
{
|
|
2023
2053
|
case (external_X_ITE_X3D_TextureQuality_default()).LOW:
|
|
2024
|
-
{
|
|
2025
2054
|
return 200;
|
|
2026
|
-
}
|
|
2027
2055
|
case (external_X_ITE_X3D_TextureQuality_default()).MEDIUM:
|
|
2028
|
-
{
|
|
2029
2056
|
return 400;
|
|
2030
|
-
}
|
|
2031
2057
|
case (external_X_ITE_X3D_TextureQuality_default()).HIGH:
|
|
2032
|
-
{
|
|
2033
2058
|
return 600;
|
|
2034
|
-
|
|
2059
|
+
}
|
|
2060
|
+
},
|
|
2061
|
+
getPoints (quality)
|
|
2062
|
+
{
|
|
2063
|
+
const
|
|
2064
|
+
numPlanes = this .getNumPlanes (quality),
|
|
2065
|
+
size = this ._dimensions .getValue () .magnitude (),
|
|
2066
|
+
size1_2 = size / 2,
|
|
2067
|
+
points = [ ];
|
|
2068
|
+
|
|
2069
|
+
for (let i = 0; i < numPlanes; ++ i)
|
|
2070
|
+
{
|
|
2071
|
+
const z = i / (numPlanes - 1) - 0.5;
|
|
2072
|
+
|
|
2073
|
+
points .push ( size1_2, size1_2, size * z,
|
|
2074
|
+
-size1_2, size1_2, size * z,
|
|
2075
|
+
-size1_2, -size1_2, size * z,
|
|
2076
|
+
size1_2, -size1_2, size * z);
|
|
2035
2077
|
}
|
|
2036
2078
|
|
|
2037
|
-
return
|
|
2079
|
+
return points;
|
|
2038
2080
|
},
|
|
2039
2081
|
set_live__ (rebuild)
|
|
2040
2082
|
{
|
|
@@ -2044,46 +2086,80 @@ Object .assign (Object .setPrototypeOf (X3DVolumeDataNode .prototype, (external_
|
|
|
2044
2086
|
|
|
2045
2087
|
if (this .getLive () .getValue () || alwaysUpdate)
|
|
2046
2088
|
{
|
|
2047
|
-
browser .getBrowserOptions () ._TextureQuality
|
|
2089
|
+
browser .getBrowserOptions () ._TextureQuality .addInterest ("set_dimensions__", this);
|
|
2090
|
+
browser .getBrowserOptions () ._QualityWhenMoving .addInterest ("set_dimensions__", this);
|
|
2048
2091
|
|
|
2049
2092
|
if (rebuild)
|
|
2050
2093
|
this .set_dimensions__ ();
|
|
2051
2094
|
}
|
|
2052
2095
|
else
|
|
2053
2096
|
{
|
|
2054
|
-
browser .getBrowserOptions () ._TextureQuality
|
|
2097
|
+
browser .getBrowserOptions () ._TextureQuality .removeInterest ("set_dimensions__", this);
|
|
2098
|
+
browser .getBrowserOptions () ._QualityWhenMoving .removeInterest ("set_dimensions__", this);
|
|
2055
2099
|
}
|
|
2056
2100
|
},
|
|
2057
2101
|
set_dimensions__ ()
|
|
2058
2102
|
{
|
|
2059
2103
|
const
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2104
|
+
browser = this .getBrowser (),
|
|
2105
|
+
quality = browser .getBrowserOptions () .getTextureQuality (),
|
|
2106
|
+
moving = browser .getBrowserOptions () .getQualityWhenMoving () ?? quality;
|
|
2107
|
+
|
|
2108
|
+
this .proximitySensorNode ._size = new (external_X_ITE_X3D_Vector3_default()) (200 * this ._dimensions .length ());
|
|
2109
|
+
this .textureTransformNode ._scale = this ._dimensions .inverse ();
|
|
2064
2110
|
|
|
2065
|
-
|
|
2111
|
+
const hi = this .getPoints (quality);
|
|
2066
2112
|
|
|
2067
|
-
|
|
2113
|
+
this .hiCoordinateNode ._point = hi;
|
|
2114
|
+
this .hiTextureCoordinateNode ._point = hi;
|
|
2115
|
+
|
|
2116
|
+
if (moving === quality)
|
|
2068
2117
|
{
|
|
2069
|
-
|
|
2118
|
+
this .lowShapeNode ._geometry = this .hiGeometryNode;
|
|
2119
|
+
}
|
|
2120
|
+
else
|
|
2121
|
+
{
|
|
2122
|
+
const low = this .getPoints (moving);
|
|
2070
2123
|
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
size1_2, -size1_2, size * z);
|
|
2124
|
+
this .lowCoordinateNode ._point = low;
|
|
2125
|
+
this .lowTextureCoordinateNode ._point = low;
|
|
2126
|
+
this .lowShapeNode ._geometry = this .lowGeometryNode;
|
|
2075
2127
|
}
|
|
2076
2128
|
|
|
2077
|
-
this .
|
|
2078
|
-
this .textureCoordinateNode ._point = points;
|
|
2079
|
-
this .textureTransformNode ._scale = new (external_X_ITE_X3D_Fields_default()).SFVec3f (1 / this ._dimensions .x,
|
|
2080
|
-
1 / this ._dimensions .y,
|
|
2081
|
-
1 / this ._dimensions .z);
|
|
2129
|
+
this .set_active__ ();
|
|
2082
2130
|
},
|
|
2083
2131
|
set_textureTransform__ ()
|
|
2084
2132
|
{
|
|
2085
2133
|
this .textureNormalMatrixArray .set (new (external_X_ITE_X3D_Matrix4_default()) (... this .textureTransformNode .getMatrix ()) .submatrix .inverse ());
|
|
2086
2134
|
},
|
|
2135
|
+
set_active__ ()
|
|
2136
|
+
{
|
|
2137
|
+
const
|
|
2138
|
+
browser = this .getBrowser (),
|
|
2139
|
+
quality = browser .getBrowserOptions () .getTextureQuality (),
|
|
2140
|
+
moving = browser .getBrowserOptions () .getQualityWhenMoving () ?? quality,
|
|
2141
|
+
update = this .proximitySensorNode ._isActive .getValue () && quality !== moving;
|
|
2142
|
+
|
|
2143
|
+
if (update)
|
|
2144
|
+
browser .sensorEvents () .addInterest ("update", this);
|
|
2145
|
+
else
|
|
2146
|
+
browser .sensorEvents () .removeInterest ("update", this);
|
|
2147
|
+
|
|
2148
|
+
this .lowShapeNode ._visible = !update;
|
|
2149
|
+
this .hiShapeNode ._visible = update;
|
|
2150
|
+
},
|
|
2151
|
+
update ()
|
|
2152
|
+
{
|
|
2153
|
+
const
|
|
2154
|
+
browser = this .getBrowser (),
|
|
2155
|
+
moving = browser .getCurrentSpeed () > 0 || browser .getViewer () .isActive ();
|
|
2156
|
+
|
|
2157
|
+
if (this .lowShapeNode ._visible .getValue () !== moving)
|
|
2158
|
+
this .lowShapeNode ._visible = moving;
|
|
2159
|
+
|
|
2160
|
+
if (this .hiShapeNode ._visible .getValue () !== !moving)
|
|
2161
|
+
this .hiShapeNode ._visible = !moving;
|
|
2162
|
+
},
|
|
2087
2163
|
traverse (type, renderObject)
|
|
2088
2164
|
{
|
|
2089
2165
|
this .groupNode .traverse (type, renderObject);
|