ohzi-core 10.6.7 → 11.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.
Files changed (64) hide show
  1. package/build/index.module.js +1 -1
  2. package/build/index.module.js.map +1 -1
  3. package/package.json +9 -11
  4. package/src/BaseApplication.js +3 -0
  5. package/src/Browser.js +4 -4
  6. package/src/Graphics.js +17 -19
  7. package/src/Initializer.js +1 -7
  8. package/src/OS.js +2 -2
  9. package/src/RenderLoop.js +16 -13
  10. package/src/action_sequencer/ActionEvent.js +1 -2
  11. package/src/action_sequencer/ActionSequencer.js +3 -7
  12. package/src/gpu_particles/ParticleAttribute.js +2 -7
  13. package/src/index.js +41 -141
  14. package/src/render_mode/NormalAORender.js +7 -8
  15. package/src/resource_loader/AsyncTextureLoader.js +5 -3
  16. package/src/resource_loader/BasisLoader.js +0 -4
  17. package/src/view_components/ApplicationView.js +2 -29
  18. package/src/view_components/ApplicationViewController.js +95 -0
  19. package/src/view_components/TransitionManager.js +60 -0
  20. package/src/view_components/VCManager.js +9 -0
  21. package/src/view_components/ViewComponent.js +9 -36
  22. package/src/view_components/ViewComponentController.js +73 -0
  23. package/src/view_components/ViewComponentControllerManager.js +59 -0
  24. package/src/view_components/ViewComponentManager.js +3 -13
  25. package/src/view_components/ViewControllerManager.js +91 -0
  26. package/src/view_components/ViewManager.js +11 -104
  27. package/src/view_components/ViewState.js +0 -7
  28. package/src/view_components/WorkerToMain.js +25 -0
  29. package/src/view_components/transition/ActionSequencerBuilder.js +3 -3
  30. package/src/view_components/transition/TransitionTable.js +9 -2
  31. package/types/BaseApplication.d.ts +1 -0
  32. package/types/Browser.d.ts +1 -1
  33. package/types/CameraManager.d.ts +2 -4
  34. package/types/Graphics.d.ts +8 -3
  35. package/types/Initializer.d.ts +1 -1
  36. package/types/RenderLoop.d.ts +1 -2
  37. package/types/SceneManager.d.ts +1 -3
  38. package/types/action_sequencer/ActionSequencer.d.ts +2 -2
  39. package/types/blitter_index.d.ts +6 -0
  40. package/types/index.d.ts +75 -73
  41. package/types/render_mode/NormalAORender.d.ts +1 -0
  42. package/types/resource_loader/AsyncTextureLoader.d.ts +1 -0
  43. package/types/utilities/FrustumPointFitter.d.ts +1 -3
  44. package/types/utilities/OMath.d.ts +9 -9
  45. package/types/view_components/ApplicationView.d.ts +1 -3
  46. package/types/view_components/ApplicationViewController.d.ts +11 -0
  47. package/types/view_components/TransitionManager.d.ts +17 -0
  48. package/types/view_components/VCManager.d.ts +5 -0
  49. package/types/view_components/ViewComponent.d.ts +1 -5
  50. package/types/view_components/ViewComponentController.d.ts +14 -0
  51. package/types/view_components/ViewComponentControllerManager.d.ts +12 -0
  52. package/types/view_components/ViewComponentManager.d.ts +0 -1
  53. package/types/view_components/ViewControllerManager.d.ts +12 -0
  54. package/types/view_components/ViewManager.d.ts +4 -22
  55. package/types/view_components/ViewState.d.ts +0 -1
  56. package/types/view_components/WorkerToMain.d.ts +8 -0
  57. package/types/view_components/transition/ActionSequencerBuilder.d.ts +1 -1
  58. package/types/view_components/transition/TransitionTable.d.ts +2 -0
  59. package/src/Configuration.js +0 -23
  60. package/src/Screen.js +0 -55
  61. package/src/render_mode/TransparencyMixRender.js +0 -147
  62. package/src/view_components/ViewContext.js +0 -15
  63. package/types/Configuration.d.ts +0 -8
  64. package/types/view_components/ViewContext.d.ts +0 -6
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ohzi-core",
3
- "version": "10.6.7",
3
+ "version": "11.0.0",
4
4
  "description": "OHZI Core Library",
5
5
  "source": "src/index.js",
6
6
  "module": "build/index.module.js",
@@ -16,8 +16,8 @@
16
16
  "preinstall": "yarn config-hooks",
17
17
  "config-hooks": "git config core.hooksPath git_hooks",
18
18
  "build": "rollup -c",
19
- "create-tag": "cross-var git tag -a \"v$npm_package_version\" -m \"Release Version $npm_package_version\" && cross-var git push origin \"v$npm_package_version\"",
20
- "update-version": "cross-var echo \"v$npm_package_version\" > .version",
19
+ "create-tag": "git tag -a \"v$npm_package_version\" -m \"Release Version $npm_package_version\" && git push origin \"v$npm_package_version\"",
20
+ "update-version": "echo \"v$npm_package_version\" > .version",
21
21
  "fix-syntax": "standardx --fix",
22
22
  "generate-types": "npx -p typescript tsc src/* --declaration --allowJs --emitDeclarationOnly --outDir types",
23
23
  "upload": "yarn build && npm publish && yarn create-tag",
@@ -44,20 +44,18 @@
44
44
  "registry": "https://registry.npmjs.org/"
45
45
  },
46
46
  "dependencies": {
47
- "three": "0.148.0"
47
+ "three": "0.157.0"
48
48
  },
49
49
  "standardx": {
50
50
  "ignore": [
51
- "rollup.config.js"
51
+ "rollup.config.mjs"
52
52
  ]
53
53
  },
54
54
  "devDependencies": {
55
- "cross-var": "^1.1.0",
56
- "rollup": "^2.44.0",
57
- "rollup-plugin-glslify": "^1.2.0",
58
- "rollup-plugin-sourcemaps": "^0.6.3",
59
- "rollup-plugin-terser": "^7.0.2",
55
+ "@rollup/plugin-terser": "^0.4.4",
56
+ "rollup": "4.1.4",
57
+ "rollup-plugin-glslify": "^1.3.1",
60
58
  "standardx": "^7.0.0",
61
- "typescript": "^4.4.3"
59
+ "typescript": "4.4.4"
62
60
  }
63
61
  }
@@ -26,6 +26,9 @@ class BaseApplication
26
26
 
27
27
  on_frame_end()
28
28
  {}
29
+
30
+ dispose()
31
+ {}
29
32
  }
30
33
 
31
34
  export { BaseApplication };
package/src/Browser.js CHANGED
@@ -1,10 +1,10 @@
1
1
 
2
2
  class Browser
3
3
  {
4
- init()
4
+ init(opr, chrome)
5
5
  {
6
6
  this.browser_name = '';
7
- this.agent = window.navigator.userAgent.toLowerCase();
7
+ this.agent = navigator.userAgent.toLowerCase();
8
8
 
9
9
  // vr specific
10
10
  this.vr_browser_keywords = ['oculusbrowser', 'oculus', 'vive', 'rift', 'windowsmr', 'cardboard', 'daydream', 'wolvic'];
@@ -23,10 +23,10 @@ class Browser
23
23
  case this.agent.indexOf('edg') > -1:
24
24
  this.browser_name = 'edge_chromium';
25
25
  break;
26
- case this.agent.indexOf('opr') > -1 && !!window.opr:
26
+ case this.agent.indexOf('opr') > -1 && !!opr:
27
27
  this.browser_name = 'opera';
28
28
  break;
29
- case this.agent.indexOf('chrome') > -1 && !!window.chrome:
29
+ case this.agent.indexOf('chrome') > -1 && !!chrome:
30
30
  this.browser_name = 'chrome';
31
31
  break;
32
32
  case this.agent.indexOf('trident') > -1:
package/src/Graphics.js CHANGED
@@ -1,28 +1,27 @@
1
- import { Configuration } from './Configuration';
2
- import { BaseRender } from './render_mode/BaseRender';
3
- import { OScreen } from './OScreen';
4
1
  import { CameraManager } from './CameraManager';
5
- import { SceneManager } from './SceneManager';
6
2
  import { Capabilities } from './Capabilities';
7
- import { DepthAndNormalsRenderer } from './render_utilities/DepthAndNormalsRenderer';
3
+ import { OScreen } from './OScreen';
4
+ import { SceneManager } from './SceneManager';
5
+ import { BaseRender } from './render_mode/BaseRender';
8
6
  import { Blitter } from './render_utilities/Blitter';
7
+ import { DepthAndNormalsRenderer } from './render_utilities/DepthAndNormalsRenderer';
9
8
 
10
9
  import {
10
+ AlwaysDepth,
11
+ FloatType,
12
+ LinearSRGBColorSpace,
11
13
  NearestFilter,
14
+ NoBlending,
12
15
  RGBAFormat,
13
- LinearEncoding,
14
- FloatType,
15
- WebGLRenderTarget,
16
16
  ShaderMaterial,
17
- NoBlending,
18
- AlwaysDepth
17
+ WebGLRenderTarget
19
18
  } from 'three';
20
19
 
21
20
  import { WebGLRenderer } from 'three';
22
21
 
23
22
  class Graphics
24
23
  {
25
- init(canvas, core_attributes, context_attributes, threejs_attributes)
24
+ init({ canvas, core_attributes, context_attributes, threejs_attributes, dpr })
26
25
  {
27
26
  this._renderer = undefined;
28
27
  this.blitter = undefined;
@@ -93,10 +92,9 @@ class Graphics
93
92
  this._renderer.autoClear = false;
94
93
  }
95
94
 
95
+ OScreen.dpr = dpr;
96
96
  this._renderer.setPixelRatio(1);
97
97
 
98
- OScreen.dpr = Configuration.dpr;
99
-
100
98
  if (!this.is_webgl2)
101
99
  {
102
100
  this._renderer.extensions.get('ANGLE_instanced_arrays');
@@ -109,6 +107,7 @@ class Graphics
109
107
  this.no_render = new BaseRender();
110
108
 
111
109
  this.current_render_mode = this.no_render;
110
+
112
111
  Capabilities.max_anisotropy = this._renderer.capabilities.getMaxAnisotropy();
113
112
  Capabilities.vertex_texture_sampler_available = this._renderer.capabilities.maxVertexTextures > 0;
114
113
  Capabilities.fp_textures_available = this.is_floating_point_texture_available();
@@ -116,9 +115,6 @@ class Graphics
116
115
  this.generateDepthNormalTexture = false;
117
116
 
118
117
  this.depth_and_normals_renderer = new DepthAndNormalsRenderer();
119
-
120
- this.resize_observer = new ResizeObserver(this.on_resize.bind(this));
121
- this.resize_observer.observe(this.canvas);
122
118
  }
123
119
 
124
120
  get dom_element()
@@ -233,11 +229,13 @@ class Graphics
233
229
  !!clear_stencil);
234
230
  }
235
231
 
236
- on_resize(entries)
232
+ on_resize(entries, dpr)
237
233
  {
238
234
  for (const entry of entries)
239
235
  {
240
- OScreen.dpr = Configuration.dpr;
236
+ OScreen.dpr = dpr;
237
+ // this._renderer.setPixelRatio(dpr);
238
+
241
239
  OScreen.update_position(entry.contentRect.x, entry.contentRect.y);
242
240
  OScreen.update_size(entry.contentRect.width, entry.contentRect.height);
243
241
 
@@ -363,7 +361,7 @@ class Graphics
363
361
  minFilter: NearestFilter,
364
362
  magFilter: NearestFilter,
365
363
  format: RGBAFormat,
366
- encoding: LinearEncoding,
364
+ colorSpace: LinearSRGBColorSpace,
367
365
  type: FloatType,
368
366
  stencilBuffer: false,
369
367
  depthBuffer: false
@@ -1,7 +1,5 @@
1
- import { Browser } from './Browser';
2
1
  import { CameraManager } from './CameraManager';
3
2
  import { Capabilities } from './Capabilities';
4
- import { Configuration } from './Configuration';
5
3
  import { Debug } from './Debug';
6
4
  import { EventManager } from './EventManager';
7
5
  import { Graphics } from './Graphics';
@@ -26,12 +24,10 @@ class Initializer
26
24
  CameraManager.init();
27
25
  CameraUtilities.init(input);
28
26
  Capabilities.init();
29
- Configuration.init();
30
27
  EventManager.init();
31
28
  GeometryBatcher.init();
32
29
 
33
30
  OS.init();
34
- Browser.init();
35
31
  ReflectionPlaneContext.init();
36
32
  ResourceContainer.init();
37
33
  SceneManager.init();
@@ -42,12 +38,10 @@ class Initializer
42
38
  Debug.init();
43
39
  }
44
40
 
45
- dispose(render_loop)
41
+ dispose()
46
42
  {
47
43
  Graphics.dispose();
48
44
  SceneManager.dispose();
49
-
50
- render_loop.dispose();
51
45
  }
52
46
  }
53
47
 
package/src/OS.js CHANGED
@@ -23,8 +23,8 @@ class OS
23
23
 
24
24
  get_os()
25
25
  {
26
- const userAgent = window.navigator.userAgent;
27
- const platform = window.navigator.platform;
26
+ const userAgent = navigator.userAgent;
27
+ const platform = navigator.platform;
28
28
  const macosPlatforms = ['Macintosh', 'MacIntel', 'MacPPC', 'Mac68K'];
29
29
  const windowsPlatforms = ['Win32', 'Win64', 'Windows', 'WinCE'];
30
30
  const iosPlatforms = ['iPhone', 'iPad', 'iPod'];
package/src/RenderLoop.js CHANGED
@@ -1,19 +1,19 @@
1
+ import { BaseApplication } from './BaseApplication';
2
+ import { Debug } from './Debug';
1
3
  import { Time } from './Time';
2
4
  import { UI } from './UI';
3
- import { Debug } from './Debug';
4
- import { BaseApplication } from './BaseApplication';
5
- import { ViewManager } from './view_components/ViewManager';
6
- import { ViewComponentManager } from './view_components/ViewComponentManager';
5
+ import { TransitionManager } from './view_components/TransitionManager';
6
+ import { VCManager } from './view_components/VCManager';
7
+ import { ViewComponentControllerManager } from './view_components/ViewComponentControllerManager';
7
8
 
8
9
  class RenderLoop
9
10
  {
10
- constructor(target_application, graphics, input)
11
+ constructor(target_application, graphics)
11
12
  {
12
13
  target_application = target_application || new BaseApplication();
13
14
 
14
15
  this.target_application = target_application;
15
16
  this.graphics = graphics;
16
- this.input = input;
17
17
 
18
18
  this.is_running = false;
19
19
  this.frames_passed = 0;
@@ -27,6 +27,7 @@ class RenderLoop
27
27
  {
28
28
  return;
29
29
  }
30
+
30
31
  Time.__update();
31
32
 
32
33
  // ###### START CYCLE ######
@@ -35,31 +36,33 @@ class RenderLoop
35
36
  this.target_application.on_post_start();
36
37
  }
37
38
 
38
- this.input.update();
39
-
40
39
  this.time_accumulator += Time.delta_time;
41
40
 
42
41
  this.target_application.before_update();
43
- ViewManager.before_update();
42
+ TransitionManager.before_update();
44
43
 
45
44
  while (this.time_accumulator > Time.fixed_delta_time)
46
45
  {
47
46
  this.target_application.fixed_update();
48
- ViewManager.fixed_update();
47
+ TransitionManager.fixed_update();
48
+
49
49
  this.time_accumulator -= Time.fixed_delta_time;
50
50
  }
51
+
51
52
  Time.__set_frame_interpolation(this.time_accumulator / Time.fixed_delta_time);
52
53
 
53
54
  this.target_application.update();
54
55
 
55
- ViewManager.update();
56
- ViewComponentManager.update();
56
+ TransitionManager.update();
57
+ VCManager.update();
58
+ ViewComponentControllerManager.update();
57
59
 
58
60
  this.target_application.on_pre_render();
59
61
 
60
62
  this.graphics.update(); // render scene
61
63
  UI.update(); // update after new camera matrix has been calculated
62
64
  UI.render(this.graphics); // render ui layer on top
65
+
63
66
  this.target_application.on_post_render();
64
67
 
65
68
  Debug.render(this.graphics); // render debug layer
@@ -67,9 +70,9 @@ class RenderLoop
67
70
  // ###### END CYCLE #######
68
71
 
69
72
  this.target_application.on_frame_end();
73
+
70
74
  this.frames_passed++;
71
75
 
72
- this.input.clear();
73
76
  UI.clear();
74
77
  Debug.clear();
75
78
  }
@@ -1,4 +1,3 @@
1
- import { ViewContext } from '../view_components/ViewContext';
2
1
 
3
2
  class ActionEvent
4
3
  {
@@ -11,7 +10,7 @@ class ActionEvent
11
10
 
12
11
  trigger()
13
12
  {
14
- ViewContext.app[this.name][this.method](...this.args.split(','));
13
+ ViewApi.application[this.name][this.method](...this.args.split(','));
15
14
  }
16
15
  }
17
16
 
@@ -3,11 +3,11 @@ import { OMath } from '../utilities/OMath';
3
3
 
4
4
  class ActionSequencer
5
5
  {
6
- constructor(context = {})
6
+ constructor(context = {}, transitions_velocity)
7
7
  {
8
8
  this.previous_elapsed_time = -0.00001;
9
9
  this.elapsed_time = -0.00001;
10
- this.playback_speed = this.__get_playback_speed();
10
+ this.playback_speed = this.__get_playback_speed(transitions_velocity);
11
11
  this.playing = true;
12
12
 
13
13
  this.action_events = [];
@@ -255,12 +255,8 @@ class ActionSequencer
255
255
  return current;
256
256
  }
257
257
 
258
- __get_playback_speed()
258
+ __get_playback_speed(transitions_velocity)
259
259
  {
260
- const url_params = new URLSearchParams(window.location.search);
261
-
262
- const transitions_velocity = url_params.get('transitions_velocity');
263
-
264
260
  if (transitions_velocity)
265
261
  {
266
262
  return Number(transitions_velocity);
@@ -1,11 +1,6 @@
1
1
  import { Graphics } from '../Graphics';
2
2
 
3
- import { NearestFilter } from 'three';
4
- import { RGBAFormat } from 'three';
5
- import { LinearEncoding } from 'three';
6
- import { HalfFloatType } from 'three';
7
- import { FloatType } from 'three';
8
- import { WebGLRenderTarget } from 'three';
3
+ import { FloatType, HalfFloatType, LinearSRGBColorSpace, NearestFilter, RGBAFormat, WebGLRenderTarget } from 'three';
9
4
  import { Capabilities } from '../Capabilities';
10
5
 
11
6
  class ParticleAttribute
@@ -37,7 +32,7 @@ class ParticleAttribute
37
32
  minFilter: NearestFilter,
38
33
  magFilter: NearestFilter,
39
34
  format: RGBAFormat,
40
- encoding: LinearEncoding,
35
+ colorSpace: LinearSRGBColorSpace,
41
36
  type: Capabilities.fp_textures_available ? FloatType : HalfFloatType,
42
37
  stencilBuffer: false,
43
38
  depthBuffer: false
package/src/index.js CHANGED
@@ -1,45 +1,47 @@
1
- import { AbstractLoader } from './resource_loader/AbstractLoader';
2
- import { ActionSequencerBuilder } from './view_components/transition/ActionSequencerBuilder';
3
- import { ApplicationView } from './view_components/ApplicationView';
4
1
  import { BaseApplication } from './BaseApplication';
5
- import { BaseRender } from './render_mode/BaseRender';
2
+ import { AddMaterial } from './materials/AddMaterial';
6
3
  import { BaseShaderMaterial } from './materials/BaseShaderMaterial';
7
4
  import { BlitMaterial } from './materials/BlitMaterial';
8
- import { AddMaterial } from './materials/AddMaterial';
9
5
  import { UnrealBloomComposeMaterial } from './materials/UnrealBloomComposeMaterial';
6
+ import { BaseRender } from './render_mode/BaseRender';
7
+ import { AbstractLoader } from './resource_loader/AbstractLoader';
8
+ import { ApplicationView } from './view_components/ApplicationView';
9
+ import { ApplicationViewController } from './view_components/ApplicationViewController';
10
+ import { ActionSequencerBuilder } from './view_components/transition/ActionSequencerBuilder';
11
+ import { WorkerToMain } from './view_components/WorkerToMain';
10
12
 
11
13
  import { Browser } from './Browser';
12
14
  import { CameraManager } from './CameraManager';
13
- import { Capabilities } from './Capabilities';
14
15
  import { CanvasDrawer } from './canvas_drawer/CanvasDrawer';
15
- import { Configuration } from './Configuration';
16
- import { CSSAnimator } from './html_utilities/CSSAnimator';
17
- import { DrawIOAnimationSheet } from './view_components/transition/DrawIOAnimationSheet';
16
+ import { SimpleTextDrawer } from './canvas_drawer/SimpleTextDrawer';
17
+ import { Capabilities } from './Capabilities';
18
18
  import { Debug } from './Debug';
19
- import { DebugNormalsRender } from './render_mode/DebugNormalsRender';
20
19
  import { EventManager } from './EventManager';
21
20
  import { Graphics } from './Graphics';
22
- import { KeyboardInput } from './KeyboardInput';
21
+ import { CSSAnimator } from './html_utilities/CSSAnimator';
23
22
  import { Initializer } from './Initializer';
24
- import { NormalAORender } from './render_mode/NormalAORender';
25
- import { NormalRender } from './render_mode/NormalRender';
26
- import { VRRender } from './render_mode/VRRender';
27
- import { UnrealBloomRender } from './render_mode/UnrealBloomRender';
23
+ import { KeyboardInput } from './KeyboardInput';
28
24
  import { OrthographicCamera } from './OrthographicCamera';
29
25
  import { OS } from './OS';
26
+ import { OScreen } from './OScreen';
30
27
  import { PerspectiveCamera } from './PerspectiveCamera';
28
+ import { DebugNormalsRender } from './render_mode/DebugNormalsRender';
29
+ import { NormalAORender } from './render_mode/NormalAORender';
30
+ import { NormalRender } from './render_mode/NormalRender';
31
+ import { UnrealBloomRender } from './render_mode/UnrealBloomRender';
32
+ import { VRRender } from './render_mode/VRRender';
31
33
  import { RenderLoop } from './RenderLoop';
32
34
  import { SceneManager } from './SceneManager';
33
- import { OScreen } from './OScreen';
34
- import { Screen } from './Screen';
35
- import { SimpleTextDrawer } from './canvas_drawer/SimpleTextDrawer';
36
35
  import { Time } from './Time';
37
36
  import { UI } from './UI';
37
+ import { DrawIOAnimationSheet } from './view_components/transition/DrawIOAnimationSheet';
38
+ import { TransitionTable } from './view_components/transition/TransitionTable';
39
+ import { TransitionManager } from './view_components/TransitionManager';
40
+ import { VCManager } from './view_components/VCManager';
38
41
  import { ViewComponent } from './view_components/ViewComponent';
42
+ import { ViewComponentController } from './view_components/ViewComponentController';
39
43
  import { ViewComponentManager } from './view_components/ViewComponentManager';
40
44
  import { ViewManager } from './view_components/ViewManager';
41
- import { ViewContext } from './view_components/ViewContext';
42
- import { TransitionTable } from './view_components/transition/TransitionTable';
43
45
 
44
46
  import { Arrow } from './primitives/Arrow';
45
47
  import { Cube } from './primitives/Cube';
@@ -54,34 +56,34 @@ import { FrustumPointFitter } from './utilities/FrustumPointFitter';
54
56
  import { GeometryUtilities } from './utilities/GeometryUtilities';
55
57
  import { HTMLUtilities } from './utilities/HTMLUtilities';
56
58
  import { ImageUtilities } from './utilities/ImageUtilities';
57
- import { OMath } from './utilities/OMath';
58
59
  import { MeshSampler } from './utilities/MeshSampler';
59
60
  import { ModelUtilities } from './utilities/ModelUtilities';
60
61
  import { ObjectUtilities } from './utilities/ObjectUtilities';
62
+ import { OMath } from './utilities/OMath';
63
+ import { OrthographicFrustumPointFitter } from './utilities/OrthographicFrustumPointFitter';
64
+ import { PerspectiveFrustumPointFitter } from './utilities/PerspectiveFrustumPointFitter';
61
65
  import { StringUtilities } from './utilities/StringUtilities';
62
66
  import { TimeUtilities } from './utilities/TimeUtilities';
63
67
  import { Validation } from './utilities/Validation';
64
- import { PerspectiveFrustumPointFitter } from './utilities/PerspectiveFrustumPointFitter';
65
- import { OrthographicFrustumPointFitter } from './utilities/OrthographicFrustumPointFitter';
66
68
 
67
69
  import { Grid } from './components/Grid';
68
70
  import { Line } from './components/Line';
69
71
  import { Text2D } from './components/Text2D';
70
- import { WorldImage } from './components/WorldImage';
71
72
  import { UIElement } from './components/UIElement';
72
73
  import { UpdatableMaterialMesh } from './components/UpdatableMaterialMesh';
74
+ import { WorldImage } from './components/WorldImage';
73
75
 
74
76
  import { SDFTextBatch } from './components/sdf_text/SDFTextBatch';
75
77
 
76
- import { ActionSequencer } from './action_sequencer/ActionSequencer';
77
- import { ActionEvent } from './action_sequencer/ActionEvent';
78
+ import { ActionEvent } from './action_sequencer/ActionEvent';
78
79
  import { ActionInterpolator } from './action_sequencer/ActionInterpolator';
80
+ import { ActionSequencer } from './action_sequencer/ActionSequencer';
79
81
  import { NumberInterpolator } from './action_sequencer/NumberInterpolator';
80
82
  import { VectorInterpolator } from './action_sequencer/VectorInterpolator';
81
83
 
82
- import { MedianFilter } from './render_utilities/MedianFilter';
83
- import { GaussianBlurrer } from './render_utilities/GaussianBlurrer';
84
84
  import { DualFilteringBlurrer } from './render_utilities/DualFilteringBlurrer';
85
+ import { GaussianBlurrer } from './render_utilities/GaussianBlurrer';
86
+ import { MedianFilter } from './render_utilities/MedianFilter';
85
87
 
86
88
  import { Blurrer } from './render_utilities/Blurrer';
87
89
 
@@ -89,25 +91,25 @@ import { GPUParticleSystem } from './gpu_particles/GPUParticleSystem';
89
91
  import { ParticleAttribute } from './gpu_particles/ParticleAttribute';
90
92
  import { ParticlePositionAttribute } from './gpu_particles/ParticlePositionAttribute';
91
93
 
92
- import { DualFilteringBlurMaterial } from './materials/DualFilteringBlurMaterial';
93
94
  import * as BufferGeometryUtils from 'three/examples/jsm/utils/BufferGeometryUtils.js';
95
+ import { DualFilteringBlurMaterial } from './materials/DualFilteringBlurMaterial';
94
96
  import { MeshBatcher } from './static_batcher/MeshBatcher';
95
97
 
98
+ import { AsyncTextureLoader } from './resource_loader/AsyncTextureLoader';
96
99
  import { AudioLoader } from './resource_loader/AudioLoader';
97
100
  import { BasisLoader } from './resource_loader/BasisLoader';
98
101
  import { CubemapLoader } from './resource_loader/CubemapLoader';
99
102
  import { DAELoader } from './resource_loader/DAELoader';
100
103
  import { FileLoader } from './resource_loader/FileLoader';
101
104
  import { FontLoader } from './resource_loader/FontLoader';
102
- import { GLTFLoader } from './resource_loader/GLTFLoader';
103
105
  import { GLTFDRACOLoader } from './resource_loader/GLTFDRACOLoader';
106
+ import { GLTFLoader } from './resource_loader/GLTFLoader';
104
107
  import { HDRCubeTextureLoader } from './resource_loader/HDRCubeTextureLoader';
105
108
  import { JSONLoader } from './resource_loader/JSONLoader';
106
109
  import { OBJLoader } from './resource_loader/OBJLoader';
107
110
  import { PointArrayLoader } from './resource_loader/PointArrayLoader';
108
111
  import { RGBETextureLoader } from './resource_loader/RGBETextureLoader';
109
112
  import { TextLoader } from './resource_loader/TextLoader';
110
- import { AsyncTextureLoader } from './resource_loader/AsyncTextureLoader';
111
113
  import { TextureLoader } from './resource_loader/TextureLoader';
112
114
  import { VideoLoader } from './resource_loader/VideoLoader';
113
115
 
@@ -115,114 +117,12 @@ import { ResourceBatch } from './resource_loader/ResourceBatch';
115
117
  import { ResourceContainer } from './ResourceContainer';
116
118
 
117
119
  export {
118
- AbstractLoader,
119
- ActionSequencerBuilder,
120
- ApplicationView,
121
- BaseApplication,
122
- BaseShaderMaterial,
123
- Browser,
124
- CameraManager,
125
- Capabilities,
126
- CanvasDrawer,
127
- Configuration,
128
- CSSAnimator,
129
- DrawIOAnimationSheet,
130
- Debug,
131
- DebugNormalsRender,
132
- EventManager,
133
- Graphics,
134
- KeyboardInput,
135
- Initializer,
136
- NormalAORender,
137
- NormalRender,
138
- VRRender,
139
- UnrealBloomRender,
140
- OrthographicCamera,
141
- OS,
142
- PerspectiveCamera,
143
- RenderLoop,
144
- SceneManager,
145
- OScreen,
146
- Screen,
147
- SimpleTextDrawer,
148
- Time,
149
- UI,
150
- BlitMaterial,
151
- AddMaterial,
152
- UnrealBloomComposeMaterial,
153
- BaseRender,
154
- ArrayUtilities,
155
- CameraUtilities,
156
- EasingFunctions,
157
- FrustumPointFitter,
158
- GeometryUtilities,
159
- HTMLUtilities,
160
- ImageUtilities,
161
- OMath,
162
- MeshSampler,
163
- ModelUtilities,
164
- ObjectUtilities,
165
- StringUtilities,
166
- TimeUtilities,
167
- Validation,
168
- ViewComponent,
169
- ViewComponentManager,
170
- ViewManager,
171
- Grid,
172
- Line,
173
- Text2D,
174
- TransitionTable,
175
- UIElement,
176
- SDFTextBatch,
177
- UpdatableMaterialMesh,
178
- WorldImage,
179
-
180
- Arrow,
181
- Cube,
182
- HorizontalPlane,
183
- Sphere,
184
- VerticalPlane,
185
-
186
- ActionSequencer,
187
- ActionEvent,
188
- ActionInterpolator,
189
- NumberInterpolator,
190
- VectorInterpolator,
191
- ViewContext,
192
-
193
- MedianFilter,
194
- GaussianBlurrer,
195
- Blurrer,
196
- DualFilteringBlurrer,
197
-
198
- GPUParticleSystem,
199
- ParticleAttribute,
200
- ParticlePositionAttribute,
201
- PerspectiveFrustumPointFitter,
202
- OrthographicFrustumPointFitter,
203
-
204
- DualFilteringBlurMaterial,
205
- BufferGeometryUtils,
206
- MeshBatcher,
207
-
208
- AudioLoader,
209
- BasisLoader,
210
- CubemapLoader,
211
- DAELoader,
212
- FileLoader,
213
- FontLoader,
214
- GLTFLoader,
215
- GLTFDRACOLoader,
216
- HDRCubeTextureLoader,
217
- JSONLoader,
218
- OBJLoader,
219
- PointArrayLoader,
220
- RGBETextureLoader,
221
- TextLoader,
222
- AsyncTextureLoader,
223
- TextureLoader,
224
- VideoLoader,
225
-
226
- ResourceBatch,
227
- ResourceContainer
120
+ AbstractLoader, ActionEvent, ActionInterpolator, ActionSequencer, ActionSequencerBuilder, AddMaterial, ApplicationView, ApplicationViewController, ArrayUtilities, Arrow, AsyncTextureLoader, AudioLoader, BaseApplication, BaseRender, BaseShaderMaterial, BasisLoader, BlitMaterial, Blurrer, Browser, BufferGeometryUtils, CameraManager, CameraUtilities, CanvasDrawer, Capabilities,
121
+ CSSAnimator, Cube, CubemapLoader, DAELoader, Debug, DebugNormalsRender, DrawIOAnimationSheet, DualFilteringBlurMaterial, DualFilteringBlurrer, EasingFunctions, EventManager, FileLoader,
122
+ FontLoader, FrustumPointFitter, GaussianBlurrer, GeometryUtilities, GLTFDRACOLoader, GLTFLoader, GPUParticleSystem, Graphics, Grid, HDRCubeTextureLoader, HorizontalPlane, HTMLUtilities,
123
+ ImageUtilities, Initializer, JSONLoader, KeyboardInput, Line, MedianFilter, MeshBatcher, MeshSampler,
124
+ ModelUtilities, NormalAORender, NormalRender, NumberInterpolator, ObjectUtilities, OBJLoader, OMath, OrthographicCamera, OrthographicFrustumPointFitter, OS, OScreen, ParticleAttribute,
125
+ ParticlePositionAttribute, PerspectiveCamera, PerspectiveFrustumPointFitter, PointArrayLoader, RenderLoop, ResourceBatch,
126
+ ResourceContainer, RGBETextureLoader, SceneManager, SDFTextBatch, SimpleTextDrawer, Sphere, StringUtilities, Text2D, TextLoader, TextureLoader, Time, TimeUtilities, TransitionManager, TransitionTable, UI, UIElement, UnrealBloomComposeMaterial, UnrealBloomRender, UpdatableMaterialMesh, Validation, VCManager, VectorInterpolator, VerticalPlane, VideoLoader, ViewComponent, ViewComponentController,
127
+ ViewComponentManager, ViewManager, VRRender, WorkerToMain, WorldImage
228
128
  };
@@ -1,19 +1,18 @@
1
1
  import { CameraManager } from '../CameraManager';
2
- import { SceneManager } from '../SceneManager';
2
+ import { Graphics } from '../Graphics';
3
3
  import { OScreen } from '../OScreen';
4
- import { BaseRender } from '../render_mode/BaseRender';
5
- import { Configuration } from '../Configuration';
6
- import { SSAOMaterial } from '../materials/SSAOMaterial';
7
- import { SSAOComposeMaterial } from '../materials/SSAOComposeMaterial';
4
+ import { SceneManager } from '../SceneManager';
8
5
  import { DisplayNormalTextureMaterial } from '../materials/DisplayNormalTextureMaterial';
6
+ import { SSAOComposeMaterial } from '../materials/SSAOComposeMaterial';
7
+ import { SSAOMaterial } from '../materials/SSAOMaterial';
8
+ import { BaseRender } from '../render_mode/BaseRender';
9
9
  import { Blurrer } from '../render_utilities/Blurrer';
10
- import { Graphics } from '../Graphics';
11
10
 
12
11
  import { WebGLRenderTarget } from 'three';
13
12
 
14
13
  class NormalAORender extends BaseRender
15
14
  {
16
- constructor()
15
+ constructor(use_ssaa = false)
17
16
  {
18
17
  super();
19
18
 
@@ -21,7 +20,7 @@ class NormalAORender extends BaseRender
21
20
  this.ssao_compose_mat = new SSAOComposeMaterial();
22
21
  this.debug_normals = new DisplayNormalTextureMaterial();
23
22
 
24
- this.ssaa = Configuration.use_ssaa ? 2 : 1;
23
+ this.ssaa = use_ssaa ? 2 : 1;
25
24
 
26
25
  this.main_RT = new WebGLRenderTarget(OScreen.width * this.ssaa, OScreen.height * this.ssaa);
27
26