ohzi-core 8.0.2 → 9.0.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.
- package/build/index.module.js +1 -1
- package/build/index.module.js.map +1 -1
- package/package.json +1 -1
- package/src/BaseApplication.js +3 -1
- package/src/Browser.js +2 -1
- package/src/CameraManager.js +14 -1
- package/src/Capabilities.js +2 -1
- package/src/Configuration.js +2 -1
- package/src/CustomBezierCurve.js +3 -1
- package/src/Debug.js +15 -11
- package/src/EventManager.js +2 -1
- package/src/Graphics.js +15 -12
- package/src/Initializer.js +19 -18
- package/src/Input.js +3 -2
- package/src/KeyboardInput.js +3 -1
- package/src/OS.js +2 -1
- package/src/OScreen.js +2 -1
- package/src/OrthographicCamera.js +4 -2
- package/src/PerspectiveCamera.js +4 -2
- package/src/ReflectionPlaneContext.js +2 -1
- package/src/RenderLayers.js +3 -1
- package/src/RenderLoop.js +11 -9
- package/src/RenderOrder.js +3 -1
- package/src/ResourceContainer.js +3 -2
- package/src/SceneManager.js +2 -1
- package/src/Screen.js +3 -2
- package/src/Time.js +2 -1
- package/src/UI.js +5 -4
- package/src/action_sequencer/ActionEvent.js +4 -2
- package/src/action_sequencer/ActionInterpolator.js +4 -2
- package/src/action_sequencer/ActionSequencer.js +4 -2
- package/src/action_sequencer/NumberInterpolator.js +5 -3
- package/src/action_sequencer/VectorInterpolator.js +4 -2
- package/src/blitter_index.js +5 -5
- package/src/canvas_drawer/CanvasDrawer.js +3 -1
- package/src/canvas_drawer/MultiLineTextDrawer.js +4 -2
- package/src/canvas_drawer/SimpleTextDrawer.js +4 -2
- package/src/components/AudioClip.js +3 -1
- package/src/components/AxisHelper.js +3 -1
- package/src/components/BaseObject.js +3 -1
- package/src/components/EdgeMesh.js +3 -1
- package/src/components/GeometryEdgeVisualizer.js +5 -2
- package/src/components/Grid.js +5 -2
- package/src/components/Line.js +3 -1
- package/src/components/MultiLinePath.js +4 -2
- package/src/components/MultiLineText2D.js +4 -2
- package/src/components/ObjectAxis.js +4 -2
- package/src/components/ObjectOrientedBoundingBox.js +3 -1
- package/src/components/PlaneHelper.js +3 -1
- package/src/components/Shape2D.js +4 -2
- package/src/components/Shape3D.js +4 -2
- package/src/components/Text2D.js +5 -3
- package/src/components/UIElement.js +11 -9
- package/src/components/UpdatableMaterialMesh.js +3 -1
- package/src/components/WorldImage.js +3 -1
- package/src/components/mouse_interactors/ObjectRotator.js +6 -4
- package/src/components/sdf_text/SDFText.js +4 -2
- package/src/components/sdf_text/SDFTextBatch.js +6 -4
- package/src/components/sdf_text/TextGlyph.js +3 -1
- package/src/data_textures/CustomDataTexture.js +3 -1
- package/src/data_textures/RGBADataTexture.js +4 -2
- package/src/data_textures/RGBAFloatDataTexture.js +4 -2
- package/src/data_textures/RGBDataTexture.js +4 -2
- package/src/data_textures/RGBFloatDataTexture.js +4 -2
- package/src/editor/ManipulatorHandle.js +6 -4
- package/src/editor/ObjectEditor.js +6 -4
- package/src/editor/ObjectManipulator.js +6 -4
- package/src/editor/ObjectPicker.js +5 -3
- package/src/gpu_particles/GPUParticleSystem.js +4 -2
- package/src/gpu_particles/ParticleAttribute.js +5 -3
- package/src/gpu_particles/ParticlePositionAttribute.js +5 -3
- package/src/html_utilities/CSSAnimator.js +6 -4
- package/src/html_utilities/css_animator_states/Animating.js +6 -4
- package/src/html_utilities/css_animator_states/Idle.js +3 -1
- package/src/index.js +112 -110
- package/src/materials/AddMaterial.js +5 -2
- package/src/materials/AlphaFilterMaterial.js +5 -2
- package/src/materials/BaseShaderMaterial.js +3 -1
- package/src/materials/BlitMaterial.js +3 -1
- package/src/materials/BloomComposeMaterial.js +6 -4
- package/src/materials/BoxBlurMaterial.js +5 -2
- package/src/materials/ClearAlphaMaterial.js +5 -3
- package/src/materials/ClearColorMaterial.js +5 -3
- package/src/materials/ClearDepthNormalMaterial.js +5 -2
- package/src/materials/DeferredRendererComposeMaterial.js +5 -2
- package/src/materials/DepthNormalMaterial.js +3 -1
- package/src/materials/DisplayNormalTextureMaterial.js +5 -2
- package/src/materials/DualFilteringBlurMaterial.js +5 -2
- package/src/materials/FXAAMaterial.js +5 -3
- package/src/materials/GaussianBlurMaterial.js +6 -2
- package/src/materials/LuminosityHighPassMaterial.js +6 -2
- package/src/materials/MedianFilterMaterial.js +5 -2
- package/src/materials/NormalMaterial.js +3 -1
- package/src/materials/SDFScreenTextMaterial.js +5 -2
- package/src/materials/SDFTextMaterial.js +6 -3
- package/src/materials/SSAOComposeMaterial.js +5 -2
- package/src/materials/SSAOMaterial.js +7 -3
- package/src/materials/ScreenSpaceTextureMaterial.js +4 -2
- package/src/materials/UIElementMaterial.js +6 -3
- package/src/materials/UnrealBloomComposeMaterial.js +6 -2
- package/src/materials/UnrealBlurMaterial.js +5 -2
- package/src/materials/UnrealComposeMaterial.js +5 -2
- package/src/materials/ViewPositionMaterial.js +3 -1
- package/src/materials/deferred/DeferredPointLightMaterial.js +5 -2
- package/src/materials/gpu_particles/AttributeUpdateMaterial.js +8 -4
- package/src/materials/gpu_particles/BasicParticleMaterial.js +3 -1
- package/src/materials/gpu_particles/ParticleStorageMaterial.js +4 -1
- package/src/materials/gpu_particles/PositionStorageMaterial.js +5 -4
- package/src/object_pool/Pool.js +3 -1
- package/src/primitives/Arrow.js +3 -1
- package/src/primitives/Cube.js +3 -1
- package/src/primitives/HorizontalPlane.js +3 -1
- package/src/primitives/Sphere.js +3 -1
- package/src/primitives/VerticalPlane.js +3 -1
- package/src/raycast/GroupRaycaster.js +7 -5
- package/src/raycast/PlaneDragResolver.js +6 -4
- package/src/raycast/PlaneRaycastResolver.js +3 -1
- package/src/raycast/PlaneRaycaster.js +5 -3
- package/src/raycast/RaycastResolver.js +3 -1
- package/src/raycast/SurfaceDragResolver.js +6 -4
- package/src/raycast/states/BaseState.js +3 -1
- package/src/raycast/states/IdleState.js +5 -3
- package/src/raycast/states/OnRaycastEnter.js +5 -3
- package/src/raycast/states/OnRaycastExit.js +5 -3
- package/src/raycast/states/OnRaycastHover.js +5 -3
- package/src/render_mode/BaseRender.js +3 -1
- package/src/render_mode/BloomRender.js +10 -8
- package/src/render_mode/DebugNormalsRender.js +8 -6
- package/src/render_mode/DeferredRender.js +10 -8
- package/src/render_mode/NormalAORender.js +13 -11
- package/src/render_mode/NormalRender.js +7 -5
- package/src/render_mode/OutlineRender.js +6 -3
- package/src/render_mode/PlanarReflectionsRender.js +9 -6
- package/src/render_mode/TransparencyMixRender.js +8 -4
- package/src/render_mode/UnrealBloomRender.js +11 -9
- package/src/render_mode/VRRender.js +71 -0
- package/src/render_utilities/Blitter.js +4 -2
- package/src/render_utilities/Blurrer.js +5 -3
- package/src/render_utilities/DepthAndNormalsRenderer.js +7 -5
- package/src/render_utilities/DualFilteringBlurrer.js +6 -4
- package/src/render_utilities/GaussianBlurrer.js +6 -4
- package/src/render_utilities/MedianFilter.js +5 -3
- package/src/render_utilities/ViewPositionRenderer.js +7 -5
- package/src/resource_loader/AbstractLoader.js +5 -3
- package/src/resource_loader/AsyncTextureLoader.js +4 -2
- package/src/resource_loader/AudioLoader.js +5 -3
- package/src/resource_loader/BasisLoader.js +4 -2
- package/src/resource_loader/CubemapLoader.js +6 -4
- package/src/resource_loader/DAELoader.js +6 -4
- package/src/resource_loader/DDSLoader.js +6 -4
- package/src/resource_loader/FileLoader.js +6 -4
- package/src/resource_loader/FontLoader.js +4 -2
- package/src/resource_loader/GLTFDRACOLoader.js +6 -4
- package/src/resource_loader/GLTFLoader.js +6 -4
- package/src/resource_loader/HDRCubeTextureLoader.js +6 -4
- package/src/resource_loader/JSONLoader.js +4 -2
- package/src/resource_loader/OBJLoader.js +6 -4
- package/src/resource_loader/PointArrayLoader.js +8 -6
- package/src/resource_loader/RGBETextureLoader.js +6 -4
- package/src/resource_loader/ResourceBatch.js +4 -2
- package/src/resource_loader/SVGLoader.js +6 -4
- package/src/resource_loader/TextLoader.js +6 -4
- package/src/resource_loader/TextureLoader.js +4 -2
- package/src/resource_loader/VideoLoader.js +4 -2
- package/src/shaders/anti_aliasing/fxaa.frag +10 -10
- package/src/shaders/basic_line/basic_line.vert +1 -1
- package/src/static_batcher/BatchedMesh.js +7 -5
- package/src/static_batcher/GeometryBatch.js +3 -1
- package/src/static_batcher/GeometryBatcher.js +4 -3
- package/src/static_batcher/MeshBatcher.js +4 -2
- package/src/ui/ui_element_position/ScreenSpacePosition.js +3 -1
- package/src/ui/ui_element_position/WorldSpacePosition.js +4 -2
- package/src/ui/ui_element_state/OnIdle.js +4 -2
- package/src/ui/ui_element_state/OnMouseEnter.js +4 -2
- package/src/ui/ui_element_state/OnMouseExit.js +4 -2
- package/src/ui/ui_element_state/OnMouseHover.js +4 -2
- package/src/ui/ui_element_state/UIElementState.js +3 -1
- package/src/utilities/ArrayUtilities.js +3 -1
- package/src/utilities/CameraUtilities.js +6 -5
- package/src/utilities/EasingFunctions.js +35 -35
- package/src/utilities/FrustumPointFitter.js +3 -1
- package/src/utilities/GeometryUtilities.js +3 -1
- package/src/utilities/HTMLUtilities.js +3 -1
- package/src/utilities/ImageUtilities.js +3 -1
- package/src/utilities/MeshSampler.js +2 -1
- package/src/utilities/ModelUtilities.js +2 -1
- package/src/utilities/OMath.js +3 -1
- package/src/utilities/ObjectUtilities.js +3 -1
- package/src/utilities/OrthographicFrustumPointFitter.js +3 -1
- package/src/utilities/PerspectiveFrustumPointFitter.js +5 -2
- package/src/utilities/StringUtilities.js +3 -1
- package/src/utilities/TimeUtilities.js +3 -1
- package/src/utilities/Validation.js +3 -1
- package/src/view_components/ApplicationView.js +7 -5
- package/src/view_components/ViewComponent.js +5 -3
- package/src/view_components/ViewComponentManager.js +3 -2
- package/src/view_components/ViewContext.js +2 -1
- package/src/view_components/ViewManager.js +4 -3
- package/src/view_components/ViewState.js +3 -1
- package/src/view_components/transition/ActionSequencerBuilder.js +7 -5
- package/src/view_components/transition/DrawIOAnimationSheet.js +3 -1
- package/src/view_components/transition/TransitionTable.js +4 -2
- package/src/view_components/transition/ViewStateTransitionHandler.js +5 -3
- package/types/raycast/states/OnRaycastHover.d.ts +2 -1
- package/types/render_mode/DebugNormalsRender.d.ts +2 -1
- package/types/resource_loader/GLTFLoader.d.ts +3 -1
- package/types/ui/ui_element_state/OnIdle.d.ts +1 -1
- package/types/ui/ui_element_state/OnMouseEnter.d.ts +1 -1
- package/types/ui/ui_element_state/OnMouseExit.d.ts +1 -1
- package/types/view_components/ApplicationView.d.ts +1 -1
|
@@ -1,112 +1,112 @@
|
|
|
1
1
|
class EasingFunctions
|
|
2
2
|
{
|
|
3
3
|
constructor()
|
|
4
|
-
{
|
|
4
|
+
{}
|
|
5
5
|
|
|
6
|
-
linear(x)
|
|
6
|
+
static linear(x)
|
|
7
7
|
{
|
|
8
8
|
return x;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
triangular(x)
|
|
11
|
+
static triangular(x)
|
|
12
12
|
{
|
|
13
13
|
return 1 - Math.abs((x * 2) % (1 * 2) - 1);
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
ease_in_sine(x)
|
|
16
|
+
static ease_in_sine(x)
|
|
17
17
|
{
|
|
18
18
|
return 1 - Math.cos(x * 3.1415926 / 2);
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
ease_out_sine(x)
|
|
21
|
+
static ease_out_sine(x)
|
|
22
22
|
{
|
|
23
23
|
return Math.sin(x * 3.1415926 / 2);
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
ease_in_out_sine(x)
|
|
26
|
+
static ease_in_out_sine(x)
|
|
27
27
|
{
|
|
28
28
|
return -(Math.cos(3.1415926 * x) - 1) / 2;
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
ease_in_cubic(x)
|
|
31
|
+
static ease_in_cubic(x)
|
|
32
32
|
{
|
|
33
33
|
return x * x * x;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
ease_out_cubic(x)
|
|
36
|
+
static ease_out_cubic(x)
|
|
37
37
|
{
|
|
38
38
|
return 1 - Math.pow(1 - x, 3);
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
-
ease_in_out_cubic(x)
|
|
41
|
+
static ease_in_out_cubic(x)
|
|
42
42
|
{
|
|
43
43
|
return x < 0.5
|
|
44
44
|
? 4 * x * x * x
|
|
45
45
|
: 1 - Math.pow(-2 * x + 2, 3) / 2;
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
ease_in_quad(x)
|
|
48
|
+
static ease_in_quad(x)
|
|
49
49
|
{
|
|
50
50
|
return x * x;
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
ease_out_quad(x)
|
|
53
|
+
static ease_out_quad(x)
|
|
54
54
|
{
|
|
55
55
|
return 1 - (1 - x) * (1 - x);
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
ease_in_out_quad(x)
|
|
58
|
+
static ease_in_out_quad(x)
|
|
59
59
|
{
|
|
60
60
|
return x < 0.5
|
|
61
61
|
? 2 * x * x
|
|
62
62
|
: 1 - Math.pow(-2 * x + 2, 2) / 2;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
|
-
ease_in_quart(x)
|
|
65
|
+
static ease_in_quart(x)
|
|
66
66
|
{
|
|
67
67
|
return x * x * x * x;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
ease_out_quart(x)
|
|
70
|
+
static ease_out_quart(x)
|
|
71
71
|
{
|
|
72
72
|
return 1 - Math.pow(1 - x, 4);
|
|
73
73
|
}
|
|
74
74
|
|
|
75
|
-
ease_in_out_quart(x)
|
|
75
|
+
static ease_in_out_quart(x)
|
|
76
76
|
{
|
|
77
77
|
return x < 0.5
|
|
78
78
|
? 8 * x * x * x * x
|
|
79
79
|
: 1 - Math.pow(-2 * x + 2, 4) / 2;
|
|
80
80
|
}
|
|
81
81
|
|
|
82
|
-
ease_in_quint(x)
|
|
82
|
+
static ease_in_quint(x)
|
|
83
83
|
{
|
|
84
84
|
return x * x * x * x * x;
|
|
85
85
|
}
|
|
86
86
|
|
|
87
|
-
ease_out_quint(x)
|
|
87
|
+
static ease_out_quint(x)
|
|
88
88
|
{
|
|
89
89
|
return 1 - Math.pow(1 - x, 5);
|
|
90
90
|
}
|
|
91
91
|
|
|
92
|
-
ease_in_out_quint(x)
|
|
92
|
+
static ease_in_out_quint(x)
|
|
93
93
|
{
|
|
94
94
|
return x < 0.5
|
|
95
95
|
? 16 * x * x * x * x * x
|
|
96
96
|
: 1 - Math.pow(-2 * x + 2, 5) / 2;
|
|
97
97
|
}
|
|
98
98
|
|
|
99
|
-
ease_in_expo(x)
|
|
99
|
+
static ease_in_expo(x)
|
|
100
100
|
{
|
|
101
101
|
return x === 0 ? 0 : Math.pow(2, 10 * x - 10);
|
|
102
102
|
}
|
|
103
103
|
|
|
104
|
-
ease_out_expo(x)
|
|
104
|
+
static ease_out_expo(x)
|
|
105
105
|
{
|
|
106
106
|
return x === 1 ? 1 : 1 - Math.pow(2, -10 * x);
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
-
ease_in_out_expo(x)
|
|
109
|
+
static ease_in_out_expo(x)
|
|
110
110
|
{
|
|
111
111
|
return x === 0
|
|
112
112
|
? 0
|
|
@@ -117,41 +117,41 @@ class EasingFunctions
|
|
|
117
117
|
: (2 - Math.pow(2, -20 * x + 10)) / 2;
|
|
118
118
|
}
|
|
119
119
|
|
|
120
|
-
ease_in_circ(x)
|
|
120
|
+
static ease_in_circ(x)
|
|
121
121
|
{
|
|
122
122
|
return 1 - Math.sqrt(1 - Math.pow(x, 2));
|
|
123
123
|
}
|
|
124
124
|
|
|
125
|
-
ease_out_circ(x)
|
|
125
|
+
static ease_out_circ(x)
|
|
126
126
|
{
|
|
127
127
|
return Math.sqrt(1 - Math.pow(x - 1, 2));
|
|
128
128
|
}
|
|
129
129
|
|
|
130
|
-
ease_in_out_circ(x)
|
|
130
|
+
static ease_in_out_circ(x)
|
|
131
131
|
{
|
|
132
132
|
return x < 0.5
|
|
133
133
|
? (1 - Math.sqrt(1 - Math.pow(2 * x, 2))) / 2
|
|
134
134
|
: (Math.sqrt(1 - Math.pow(-2 * x + 2, 2)) + 1) / 2;
|
|
135
135
|
}
|
|
136
136
|
|
|
137
|
-
ease_in_back(x)
|
|
137
|
+
static ease_in_back(x)
|
|
138
138
|
{
|
|
139
139
|
return 2.7015 * x * x * x - 1.7015 * x * x;
|
|
140
140
|
}
|
|
141
141
|
|
|
142
|
-
ease_out_back(x)
|
|
142
|
+
static ease_out_back(x)
|
|
143
143
|
{
|
|
144
144
|
return 1 + 2.7015 * Math.pow(x - 1, 3) + 1.7015 * Math.pow(x - 1, 2);
|
|
145
145
|
}
|
|
146
146
|
|
|
147
|
-
ease_in_out_back(x)
|
|
147
|
+
static ease_in_out_back(x)
|
|
148
148
|
{
|
|
149
149
|
return x < 0.5
|
|
150
150
|
? (Math.pow(2 * x, 2) * ((2.5949095 + 1) * 2 * x - 2.5949095)) / 2
|
|
151
151
|
: (Math.pow(2 * x - 2, 2) * ((2.5949095 + 1) * (x * 2 - 2) + 2.5949095) + 2) / 2;
|
|
152
152
|
}
|
|
153
153
|
|
|
154
|
-
ease_in_elastic(x)
|
|
154
|
+
static ease_in_elastic(x)
|
|
155
155
|
{
|
|
156
156
|
const c4 = (2 * Math.PI) / 3;
|
|
157
157
|
|
|
@@ -162,7 +162,7 @@ class EasingFunctions
|
|
|
162
162
|
: -Math.pow(2, 10 * x - 10) * Math.sin((x * 10 - 10.75) * c4);
|
|
163
163
|
}
|
|
164
164
|
|
|
165
|
-
ease_out_elastic(x)
|
|
165
|
+
static ease_out_elastic(x)
|
|
166
166
|
{
|
|
167
167
|
return x === 0
|
|
168
168
|
? 0
|
|
@@ -171,7 +171,7 @@ class EasingFunctions
|
|
|
171
171
|
: Math.pow(2, -10 * x) * Math.sin((x * 10 - 0.75) * 2.0943950) + 1;
|
|
172
172
|
}
|
|
173
173
|
|
|
174
|
-
ease_in_out_elastic(x)
|
|
174
|
+
static ease_in_out_elastic(x)
|
|
175
175
|
{
|
|
176
176
|
return x === 0
|
|
177
177
|
? 0
|
|
@@ -182,12 +182,12 @@ class EasingFunctions
|
|
|
182
182
|
: Math.pow(2, -20 * x + 10) * Math.sin((20 * x - 11.125) * 1.3962633) / 2 + 1;
|
|
183
183
|
}
|
|
184
184
|
|
|
185
|
-
ease_in_bounce(x)
|
|
185
|
+
static ease_in_bounce(x)
|
|
186
186
|
{
|
|
187
187
|
return 1 - this.ease_out_bounce(1 - x);
|
|
188
188
|
}
|
|
189
189
|
|
|
190
|
-
ease_out_bounce(x)
|
|
190
|
+
static ease_out_bounce(x)
|
|
191
191
|
{
|
|
192
192
|
const n1 = 7.5625;
|
|
193
193
|
const d1 = 2.75;
|
|
@@ -210,17 +210,17 @@ class EasingFunctions
|
|
|
210
210
|
}
|
|
211
211
|
}
|
|
212
212
|
|
|
213
|
-
ease_in_out_bounce(x)
|
|
213
|
+
static ease_in_out_bounce(x)
|
|
214
214
|
{
|
|
215
215
|
return x < 0.5
|
|
216
216
|
? (1 - this.ease_out_bounce(1 - 2 * x)) / 2
|
|
217
217
|
: (1 + this.ease_out_bounce(2 * x - 1)) / 2;
|
|
218
218
|
}
|
|
219
219
|
|
|
220
|
-
heartbeat(t)
|
|
220
|
+
static heartbeat(t)
|
|
221
221
|
{
|
|
222
222
|
return 1.0 - Math.pow(Math.abs(Math.sin(t + 1.0)), 63.0) * Math.sign(Math.sin(t)) * Math.sin(t + 1.5 + 1.0) * 0.8;
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
225
|
|
|
226
|
-
export
|
|
226
|
+
export { EasingFunctions };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Line3, Plane, Quaternion, Sphere, Vector3 } from 'three';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
class FrustumPointFitter
|
|
4
4
|
{
|
|
5
5
|
constructor()
|
|
6
6
|
{
|
|
@@ -253,3 +253,5 @@ export default class FrustumPointFitter
|
|
|
253
253
|
return Math.max(Math.abs(distH), Math.abs(distV));
|
|
254
254
|
}
|
|
255
255
|
}
|
|
256
|
+
|
|
257
|
+
export { FrustumPointFitter };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { BufferAttribute } from 'three';
|
|
2
2
|
import { BufferGeometry } from 'three';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
class GeometryUtilities
|
|
5
5
|
{
|
|
6
6
|
static convert_to_non_indexed_geometry(geometry_buffer)
|
|
7
7
|
{
|
|
@@ -72,3 +72,5 @@ export default class GeometryUtilities
|
|
|
72
72
|
non_indexed_geometry_buffer.setAttribute('barycentric', new BufferAttribute(new Float32Array(bar_coordinates), 3));
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
+
|
|
76
|
+
export { GeometryUtilities };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Vector4 } from 'three';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
class ImageUtilities
|
|
4
4
|
{
|
|
5
5
|
constructor()
|
|
6
6
|
{ }
|
|
@@ -24,3 +24,5 @@ export default class ImageUtilities
|
|
|
24
24
|
return new Vector4(data[position + 0], data[position + 1], data[position + 2], data[position + 3]);
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
|
+
|
|
28
|
+
export { ImageUtilities };
|
package/src/utilities/OMath.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Vector3, Box3 } from 'three';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
class OrthographicFrustumPointFitter
|
|
4
4
|
{
|
|
5
5
|
constructor()
|
|
6
6
|
{
|
|
@@ -45,3 +45,5 @@ export default class OrthographicFrustumPointFitter
|
|
|
45
45
|
return Math.max(Math.abs(distH), Math.abs(distV));
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
|
+
|
|
49
|
+
export { OrthographicFrustumPointFitter };
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Vector3, Plane, Quaternion, Sphere, Line3 } from 'three';
|
|
2
|
-
import OMath from './OMath';
|
|
3
|
-
|
|
2
|
+
import { OMath } from './OMath';
|
|
3
|
+
|
|
4
|
+
class PerspectiveFrustumPointFitter
|
|
4
5
|
{
|
|
5
6
|
constructor()
|
|
6
7
|
{
|
|
@@ -249,3 +250,5 @@ export default class PerspectiveFrustumPointFitter
|
|
|
249
250
|
return Math.max(Math.abs(distH), Math.abs(distV));
|
|
250
251
|
}
|
|
251
252
|
}
|
|
253
|
+
|
|
254
|
+
export { PerspectiveFrustumPointFitter };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import ResourceContainer from '../ResourceContainer';
|
|
2
|
-
import HTMLUtilities from '../utilities/HTMLUtilities';
|
|
3
|
-
import ViewManager from './ViewManager';
|
|
4
|
-
import ViewState from './ViewState';
|
|
1
|
+
import { ResourceContainer } from '../ResourceContainer';
|
|
2
|
+
import { HTMLUtilities } from '../utilities/HTMLUtilities';
|
|
3
|
+
import { ViewManager } from './ViewManager';
|
|
4
|
+
import { ViewState } from './ViewState';
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
class ApplicationView extends ViewState
|
|
7
7
|
{
|
|
8
8
|
constructor({ name, url, container })
|
|
9
9
|
{
|
|
@@ -73,3 +73,5 @@ export default class ApplicationView extends ViewState
|
|
|
73
73
|
this.container.style.opacity = current_state_data[`${this.name}_opacity`];
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
|
+
|
|
77
|
+
export { ApplicationView };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import HTMLUtilities from '../utilities/HTMLUtilities';
|
|
2
|
-
import ViewComponentManager from './ViewComponentManager';
|
|
1
|
+
import { HTMLUtilities } from '../utilities/HTMLUtilities';
|
|
2
|
+
import { ViewComponentManager } from './ViewComponentManager';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
class ViewComponent
|
|
5
5
|
{
|
|
6
6
|
constructor({ name, container })
|
|
7
7
|
{
|
|
@@ -70,3 +70,5 @@ export default class ViewComponent
|
|
|
70
70
|
HTMLUtilities.load_videos(this.container);
|
|
71
71
|
}
|
|
72
72
|
}
|
|
73
|
+
|
|
74
|
+
export { ViewComponent };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import ViewManager from './ViewManager';
|
|
1
|
+
import { ViewManager } from './ViewManager';
|
|
2
2
|
|
|
3
3
|
class ViewComponentManager
|
|
4
4
|
{
|
|
@@ -65,4 +65,5 @@ class ViewComponentManager
|
|
|
65
65
|
}
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
|
|
68
|
+
const view_component_manager = new ViewComponentManager();
|
|
69
|
+
export { view_component_manager as ViewComponentManager };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import TransitionTable from './transition/TransitionTable';
|
|
2
|
-
import ViewStateTransitionHandler from './transition/ViewStateTransitionHandler';
|
|
1
|
+
import { TransitionTable } from './transition/TransitionTable';
|
|
2
|
+
import { ViewStateTransitionHandler } from './transition/ViewStateTransitionHandler';
|
|
3
3
|
|
|
4
4
|
class ViewManager
|
|
5
5
|
{
|
|
@@ -186,4 +186,5 @@ class ViewManager
|
|
|
186
186
|
}
|
|
187
187
|
}
|
|
188
188
|
|
|
189
|
-
|
|
189
|
+
const view_manager = new ViewManager();
|
|
190
|
+
export { view_manager as ViewManager };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import ActionSequencer from '../../action_sequencer/ActionSequencer';
|
|
2
|
-
import NumberInterpolator from '../../action_sequencer/NumberInterpolator';
|
|
3
|
-
import ActionEvent from '../../action_sequencer/ActionEvent';
|
|
4
|
-
import DrawIOAnimationSheet from './DrawIOAnimationSheet';
|
|
1
|
+
import { ActionSequencer } from '../../action_sequencer/ActionSequencer';
|
|
2
|
+
import { NumberInterpolator } from '../../action_sequencer/NumberInterpolator';
|
|
3
|
+
import { ActionEvent } from '../../action_sequencer/ActionEvent';
|
|
4
|
+
import { DrawIOAnimationSheet } from './DrawIOAnimationSheet';
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
class ActionSequencerBuilder
|
|
7
7
|
{
|
|
8
8
|
constructor(initial_state_data)
|
|
9
9
|
{
|
|
@@ -120,3 +120,5 @@ export default class ActionSequencerBuilder
|
|
|
120
120
|
return longest_time;
|
|
121
121
|
}
|
|
122
122
|
}
|
|
123
|
+
|
|
124
|
+
export { ActionSequencerBuilder };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import ActionSequencerBuilder from './ActionSequencerBuilder';
|
|
1
|
+
import { ActionSequencerBuilder } from './ActionSequencerBuilder';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
class TransitionTable
|
|
4
4
|
{
|
|
5
5
|
constructor()
|
|
6
6
|
{
|
|
@@ -52,3 +52,5 @@ export default class TransitionTable
|
|
|
52
52
|
this.initial_state_data = initial_state_data;
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
|
+
|
|
56
|
+
export { TransitionTable };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import Time from '../../Time';
|
|
2
|
-
import ViewState from '../ViewState';
|
|
1
|
+
import { Time } from '../../Time';
|
|
2
|
+
import { ViewState } from '../ViewState';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
class ViewStateTransitionHandler
|
|
5
5
|
{
|
|
6
6
|
constructor(transition_table)
|
|
7
7
|
{
|
|
@@ -94,3 +94,5 @@ export default class ViewStateTransitionHandler
|
|
|
94
94
|
this.last_state.on_exit();
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
|
+
|
|
98
|
+
export { ViewStateTransitionHandler };
|