sebastien 6 лет назад
Родитель
Сommit
d0b58fa3bd
52 измененных файлов с 136 добавлено и 50 удалено
  1. 2 2
      src/Materials/Textures/hdrCubeTexture.ts
  2. 1 1
      src/Mesh/abstractMesh.ts
  3. 1 1
      src/PostProcess/RenderPipeline/Pipelines/defaultRenderingPipeline.ts
  4. 3 1
      src/PostProcess/RenderPipeline/Pipelines/lensRenderingPipeline.ts
  5. 3 1
      src/PostProcess/RenderPipeline/Pipelines/ssao2RenderingPipeline.ts
  6. 3 1
      src/PostProcess/RenderPipeline/Pipelines/ssaoRenderingPipeline.ts
  7. 4 1
      src/PostProcess/RenderPipeline/Pipelines/standardRenderingPipeline.ts
  8. 2 1
      src/PostProcess/RenderPipeline/postProcessRenderEffect.ts
  9. 1 1
      src/PostProcess/RenderPipeline/postProcessRenderPipeline.ts
  10. 1 1
      src/PostProcess/RenderPipeline/postProcessRenderPipelineManagerSceneComponent.ts
  11. 1 1
      src/PostProcess/anaglyphPostProcess.ts
  12. 1 0
      src/PostProcess/blackAndWhitePostProcess.ts
  13. 2 1
      src/PostProcess/bloomEffect.ts
  14. 1 1
      src/PostProcess/circleOfConfusionPostProcess.ts
  15. 1 1
      src/PostProcess/colorCorrectionPostProcess.ts
  16. 4 3
      src/PostProcess/depthOfFieldBlurPostProcess.ts
  17. 3 2
      src/PostProcess/depthOfFieldEffect.ts
  18. 1 1
      src/PostProcess/depthOfFieldMergePostProcess.ts
  19. 1 1
      src/PostProcess/displayPassPostProcess.ts
  20. 1 1
      src/PostProcess/extractHighlightsPostProcess.ts
  21. 1 0
      src/PostProcess/filterPostProcess.ts
  22. 1 1
      src/PostProcess/fxaaPostProcess.ts
  23. 1 1
      src/PostProcess/grainPostProcess.ts
  24. 1 0
      src/PostProcess/highlightsPostProcess.ts
  25. 3 1
      src/PostProcess/imageProcessingPostProcess.ts
  26. 3 1
      src/PostProcess/motionBlurPostProcess.ts
  27. 3 1
      src/PostProcess/volumetricLightScatteringPostProcess.ts
  28. 2 0
      src/Probes/reflectionProbe.ts
  29. 1 0
      src/Rendering/edgesRenderer.ts
  30. 2 1
      src/Rendering/geometryBufferRenderer.ts
  31. 2 2
      src/Rendering/lineEdgesRenderer.ts
  32. 1 1
      src/Rendering/outlineRenderer.ts
  33. 2 2
      src/Rendering/renderingGroup.ts
  34. 1 2
      src/Rendering/renderingManager.ts
  35. 1 1
      src/Rendering/utilityLayerRenderer.ts
  36. 0 1
      src/Sprites/sprite.ts
  37. 3 1
      src/Sprites/spriteManager.ts
  38. 1 0
      src/Sprites/spriteSceneComponent.ts
  39. 0 1
      src/Tools/HDR/cubemapToSphericalPolynomial.ts
  40. 9 1
      src/Tools/dds.ts
  41. 9 1
      src/Tools/environmentTextureTools.ts
  42. 5 1
      src/Tools/filesInput.ts
  43. 5 1
      src/Tools/khronosTextureContainer.ts
  44. 4 1
      src/Tools/observable.ts
  45. 4 1
      src/Tools/performanceMonitor.ts
  46. 5 1
      src/Tools/promise.ts
  47. 9 1
      src/Tools/sceneOptimizer.ts
  48. 8 0
      src/Tools/sceneSerializer.ts
  49. 3 1
      src/Tools/stringDictionary.ts
  50. 2 0
      src/Tools/tags.ts
  51. 2 0
      src/Tools/textureTools.ts
  52. 5 1
      src/Tools/tga.ts

+ 2 - 2
src/Materials/Textures/hdrCubeTexture.ts

@@ -108,7 +108,7 @@ import { HDRTools, CubeMapToSphericalPolynomialTools } from "Tools";
          * @param gammaSpace Specifies if the texture will be use in gamma or linear space (the PBR material requires those texture in linear space, but the standard material would require them in Gamma space)
          * @param gammaSpace Specifies if the texture will be use in gamma or linear space (the PBR material requires those texture in linear space, but the standard material would require them in Gamma space)
          * @param reserved Reserved flag for internal use.
          * @param reserved Reserved flag for internal use.
          */
          */
-        constructor(url: string, scene: Scene, size: number, noMipmap = false, gammaSpace = false, onLoad: Nullable<() => void> = null, onError: Nullable<(message?: string, exception?: any) => void> = null) {
+        constructor(url: string, scene: Scene, size: number, noMipmap = false, generateHarmonics = true, gammaSpace = false, reserved = false, onLoad: Nullable<() => void> = null, onError: Nullable<(message?: string, exception?: any) => void> = null) {
             super(scene);
             super(scene);
 
 
             if (!url) {
             if (!url) {
@@ -236,7 +236,7 @@ import { HDRTools, CubeMapToSphericalPolynomialTools } from "Tools";
                 return this;
                 return this;
             }
             }
 
 
-            var newTexture = new HDRCubeTexture(this.url, scene, this._size, this._noMipmap,
+            var newTexture = new HDRCubeTexture(this.url, scene, this._size, this._noMipmap, this._generateHarmonics,
                 this.gammaSpace);
                 this.gammaSpace);
 
 
             // Base texture
             // Base texture

+ 1 - 1
src/Mesh/abstractMesh.ts

@@ -2,7 +2,7 @@ import { Observer, Observable, Tools } from "Tools";
 import { Nullable, FloatArray, IndicesArray } from "types";
 import { Nullable, FloatArray, IndicesArray } from "types";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Scene, IDisposable } from "scene";
 import { Scene, IDisposable } from "scene";
-import { Quaternion, Matrix, Vector3, Color3, Color4, Plane, Tmp, Epsilon, Axis } from "Math";
+import { Quaternion, Matrix, Vector3, Color3, Color4, Plane, Tmp, Epsilon, Axis, Vector2 } from "Math";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { Node } from "Node";
 import { Node } from "Node";
 import { InstancedMesh, VertexBuffer, TransformNode, SubMesh, LinesMesh, IGetSetVerticesData, VertexData } from "Mesh";
 import { InstancedMesh, VertexBuffer, TransformNode, SubMesh, LinesMesh, IGetSetVerticesData, VertexData } from "Mesh";

+ 1 - 1
src/PostProcess/RenderPipeline/Pipelines/defaultRenderingPipeline.ts

@@ -1,5 +1,5 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
-import { IAnimatable, Observer, serialize, SerializationHelper } from "Tools";
+import { IAnimatable, Observer, serialize, SerializationHelper, Tools } from "Tools";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { ImageProcessingConfiguration, Texture } from "Materials";
 import { ImageProcessingConfiguration, Texture } from "Materials";
 import { PostProcess, PostProcessRenderPipeline, SharpenPostProcess, PostProcessRenderEffect, BloomEffect, DepthOfFieldEffect, FxaaPostProcess, ImageProcessingPostProcess, ChromaticAberrationPostProcess, GrainPostProcess, DepthOfFieldEffectBlurLevel } from "PostProcess";
 import { PostProcess, PostProcessRenderPipeline, SharpenPostProcess, PostProcessRenderEffect, BloomEffect, DepthOfFieldEffect, FxaaPostProcess, ImageProcessingPostProcess, ChromaticAberrationPostProcess, GrainPostProcess, DepthOfFieldEffectBlurLevel } from "PostProcess";

+ 3 - 1
src/PostProcess/RenderPipeline/Pipelines/lensRenderingPipeline.ts

@@ -1,7 +1,9 @@
 
 
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { RenderTargetTexture, Effect, Texture, DynamicTexture } from "Materials";
 import { RenderTargetTexture, Effect, Texture, DynamicTexture } from "Materials";
-import { PostProcess, PostProcessRenderPipeline, Scene, PostProcessRenderEffect } from "PostProcess";
+import { PostProcess, PostProcessRenderPipeline, PostProcessRenderEffect } from "PostProcess";
+import { Scene } from "scene";
+
     /**
     /**
      * BABYLON.JS Chromatic Aberration GLSL Shader
      * BABYLON.JS Chromatic Aberration GLSL Shader
      * Author: Olivier Guyot
      * Author: Olivier Guyot

+ 3 - 1
src/PostProcess/RenderPipeline/Pipelines/ssao2RenderingPipeline.ts

@@ -2,9 +2,11 @@ import { Tools, serialize, SerializationHelper } from "Tools";
 import { Vector3, Tmp } from "Math";
 import { Vector3, Tmp } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect, Texture, DynamicTexture } from "Materials";
 import { Effect, Texture, DynamicTexture } from "Materials";
-import { PostProcess, PostProcessRenderPipeline, Scene, PassPostProcess, PostProcessRenderEffect } from "PostProcess";
+import { PostProcess, PostProcessRenderPipeline, PassPostProcess, PostProcessRenderEffect } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { GeometryBufferRenderer } from "index";
 import { GeometryBufferRenderer } from "index";
+import { Scene } from "scene";
+
     /**
     /**
      * Render pipeline to produce ssao effect
      * Render pipeline to produce ssao effect
      */
      */

+ 3 - 1
src/PostProcess/RenderPipeline/Pipelines/ssaoRenderingPipeline.ts

@@ -1,9 +1,11 @@
 import { Vector2, Vector3, Tmp } from "Math";
 import { Vector2, Vector3, Tmp } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { RenderTargetTexture, Effect, Texture, DynamicTexture } from "Materials";
 import { RenderTargetTexture, Effect, Texture, DynamicTexture } from "Materials";
-import { PostProcess, PostProcessRenderPipeline, Scene, PassPostProcess, BlurPostProcess, PostProcessRenderEffect } from "PostProcess";
+import { PostProcess, PostProcessRenderPipeline, PassPostProcess, BlurPostProcess, PostProcessRenderEffect } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { serialize } from "Tools";
 import { serialize } from "Tools";
+import { Scene } from "scene";
+
     /**
     /**
      * Render pipeline to produce ssao effect
      * Render pipeline to produce ssao effect
      */
      */

+ 4 - 1
src/PostProcess/RenderPipeline/Pipelines/standardRenderingPipeline.ts

@@ -3,11 +3,14 @@ import { IAnimatable, Tools, serialize, serializeAsTexture, SerializationHelper
 import { Vector2, Vector3, Matrix, Vector4, Scalar } from "Math";
 import { Vector2, Vector3, Matrix, Vector4, Scalar } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect, Texture } from "Materials";
 import { Effect, Texture } from "Materials";
-import { PostProcess, PostProcessRenderPipeline, BlurPostProcess, FxaaPostProcess, Scene, PostProcessRenderEffect } from "PostProcess";
+import { PostProcess, PostProcessRenderPipeline, BlurPostProcess, FxaaPostProcess, PostProcessRenderEffect } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { IDisposable } from "scene";
 import { IDisposable } from "scene";
 import { SpotLight, DirectionalLight } from "Lights";
 import { SpotLight, DirectionalLight } from "Lights";
 import { GeometryBufferRenderer } from "Rendering";
 import { GeometryBufferRenderer } from "Rendering";
+import { Scene } from "scene";
+import { Animation } from "Animations";
+
     /**
     /**
      * Standard rendering pipeline
      * Standard rendering pipeline
      * Default pipeline should be used going forward but the standard pipeline will be kept for backwards compatibility.
      * Default pipeline should be used going forward but the standard pipeline will be kept for backwards compatibility.

+ 2 - 1
src/PostProcess/RenderPipeline/postProcessRenderEffect.ts

@@ -2,6 +2,7 @@ import { Nullable } from "types";
 import { Tools } from "Tools";
 import { Tools } from "Tools";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { PostProcess } from "PostProcess";
 import { PostProcess } from "PostProcess";
+import { Engine } from "Engine";
     /**
     /**
      * This represents a set of one or more post processes in Babylon.
      * This represents a set of one or more post processes in Babylon.
      * A post process can be used to apply a shader to a texture after it is rendered.
      * A post process can be used to apply a shader to a texture after it is rendered.
@@ -30,7 +31,7 @@ import { PostProcess } from "PostProcess";
          * @param getPostProcesses A function that returns a set of post processes which the effect will run in order to be run.
          * @param getPostProcesses A function that returns a set of post processes which the effect will run in order to be run.
          * @param singleInstance False if this post process can be run on multiple cameras. (default: true)
          * @param singleInstance False if this post process can be run on multiple cameras. (default: true)
          */
          */
-        constructor(name: string, getPostProcesses: () => Nullable<PostProcess | Array<PostProcess>>, singleInstance?: boolean) {
+        constructor(engine: Engine, name: string, getPostProcesses: () => Nullable<PostProcess | Array<PostProcess>>, singleInstance?: boolean) {
             this._name = name;
             this._name = name;
             this._singleInstance = singleInstance || true;
             this._singleInstance = singleInstance || true;
 
 

+ 1 - 1
src/PostProcess/RenderPipeline/postProcessRenderPipeline.ts

@@ -1,5 +1,5 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
-import { Tools } from "Tools";
+import { Tools, serialize } from "Tools";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { PostProcessRenderEffect } from "PostProcess";
 import { PostProcessRenderEffect } from "PostProcess";

+ 1 - 1
src/PostProcess/RenderPipeline/postProcessRenderPipelineManagerSceneComponent.ts

@@ -1,4 +1,4 @@
-import { ISceneComponent } from "sceneComponent";
+import { ISceneComponent, SceneComponentConstants } from "sceneComponent";
 import { PostProcessRenderPipelineManager } from "PostProcess";
 import { PostProcessRenderPipelineManager } from "PostProcess";
 import { Scene } from "scene";
 import { Scene } from "scene";
 
 

+ 1 - 1
src/PostProcess/anaglyphPostProcess.ts

@@ -1,5 +1,5 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
-import { Engine } from "Particles";
+import { Engine } from "Engine";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";

+ 1 - 0
src/PostProcess/blackAndWhitePostProcess.ts

@@ -1,6 +1,7 @@
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";
+import { Engine } from "Engine";
 
 
     /**
     /**
      * Post process used to render in black and white
      * Post process used to render in black and white

+ 2 - 1
src/PostProcess/bloomEffect.ts

@@ -1,7 +1,8 @@
-import { PostProcessRenderEffect, PostProcess, ExtractHighlightsPostProcess, BlurPostProcess, BloomMergePostProcess, Scene } from "PostProcess";
+import { PostProcessRenderEffect, PostProcess, ExtractHighlightsPostProcess, BlurPostProcess, BloomMergePostProcess } from "PostProcess";
 import { Vector2 } from "Math";
 import { Vector2 } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Texture } from "Materials";
 import { Texture } from "Materials";
+import { Scene } from "scene";
 
 
     /**
     /**
      * The bloom effect spreads bright areas of an image to simulate artifacts seen in cameras
      * The bloom effect spreads bright areas of an image to simulate artifacts seen in cameras

+ 1 - 1
src/PostProcess/circleOfConfusionPostProcess.ts

@@ -1,5 +1,5 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
-import { Engine } from "Particles";
+import { Engine } from "Engine";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { RenderTargetTexture, Effect } from "Materials";
 import { RenderTargetTexture, Effect } from "Materials";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";

+ 1 - 1
src/PostProcess/colorCorrectionPostProcess.ts

@@ -1,6 +1,6 @@
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Texture, Effect } from "Materials";
 import { Texture, Effect } from "Materials";
-import { Engine } from "Particles";
+import { Engine } from "Engine";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 
 
     /**
     /**

+ 4 - 3
src/PostProcess/depthOfFieldBlurPostProcess.ts

@@ -2,9 +2,10 @@ import { Nullable } from "types";
 import { Vector2 } from "Math";
 import { Vector2 } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect, Texture } from "Materials";
 import { Effect, Texture } from "Materials";
-import { PostProcess, BlurPostProcess, Scene, PostProcessOptions } from "PostProcess";
+import { PostProcess, BlurPostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
-    
+import { Scene } from "scene";
+
     /**
     /**
      * The DepthOfFieldBlurPostProcess applied a blur in a give direction.
      * The DepthOfFieldBlurPostProcess applied a blur in a give direction.
      * This blur differs from the standard BlurPostProcess as it attempts to avoid blurring pixels
      * This blur differs from the standard BlurPostProcess as it attempts to avoid blurring pixels
@@ -28,7 +29,7 @@ import { Engine } from "Engine";
          * @param textureType Type of textures used when performing the post process. (default: 0)
          * @param textureType Type of textures used when performing the post process. (default: 0)
          * @param blockCompilation If compilation of the shader should not be done in the constructor. The updateEffect method can be used to compile the shader at a later time. (default: false)
          * @param blockCompilation If compilation of the shader should not be done in the constructor. The updateEffect method can be used to compile the shader at a later time. (default: false)
          */
          */
-        constructor(name: string, scene: Scene, public direction: Vector2, kernel: number, options: number | PostProcessOptions, camera: Nullable<Camera>, circleOfConfusion: PostProcess, imageToBlur: Nullable<PostProcess> = null, engine?: Engine, reusable?: boolean, blockCompilation = false) {
+        constructor(name: string, scene: Scene, public direction: Vector2, kernel: number, options: number | PostProcessOptions, camera: Nullable<Camera>, circleOfConfusion: PostProcess, imageToBlur: Nullable<PostProcess> = null, samplingMode: number = Texture.BILINEAR_SAMPLINGMODE, engine?: Engine, reusable?: boolean, textureType: number = Engine.TEXTURETYPE_UNSIGNED_INT, blockCompilation = false) {
             super(name, direction, kernel, options, camera, samplingMode = Texture.BILINEAR_SAMPLINGMODE, engine, reusable, textureType = Engine.TEXTURETYPE_UNSIGNED_INT, `#define DOF 1\r\n`, blockCompilation);
             super(name, direction, kernel, options, camera, samplingMode = Texture.BILINEAR_SAMPLINGMODE, engine, reusable, textureType = Engine.TEXTURETYPE_UNSIGNED_INT, `#define DOF 1\r\n`, blockCompilation);
 
 
             this.onApplyObservable.add((effect: Effect) => {
             this.onApplyObservable.add((effect: Effect) => {

+ 3 - 2
src/PostProcess/depthOfFieldEffect.ts

@@ -2,8 +2,9 @@ import { Nullable } from "types";
 import { Vector2 } from "Math";
 import { Vector2 } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { RenderTargetTexture, Texture } from "Materials";
 import { RenderTargetTexture, Texture } from "Materials";
-import { PostProcess, PostProcessRenderEffect, CircleOfConfusionPostProcess, DepthOfFieldBlurPostProcess, DepthOfFieldMergePostProcess, Scene } from "PostProcess";
-    
+import { PostProcess, PostProcessRenderEffect, CircleOfConfusionPostProcess, DepthOfFieldBlurPostProcess, DepthOfFieldMergePostProcess } from "PostProcess";
+import { Scene } from "scene";
+
     /**
     /**
      * Specifies the level of max blur that should be applied when using the depth of field effect
      * Specifies the level of max blur that should be applied when using the depth of field effect
      */
      */

+ 1 - 1
src/PostProcess/depthOfFieldMergePostProcess.ts

@@ -1,7 +1,7 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";
-import { PostProcess } from "PostProcess";
+import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
     /**
     /**
      * Options to be set when merging outputs from the default pipeline.
      * Options to be set when merging outputs from the default pipeline.

+ 1 - 1
src/PostProcess/displayPassPostProcess.ts

@@ -2,7 +2,7 @@
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
-    
+
     /**
     /**
      * DisplayPassPostProcess which produces an output the same as it's input
      * DisplayPassPostProcess which produces an output the same as it's input
      */
      */

+ 1 - 1
src/PostProcess/extractHighlightsPostProcess.ts

@@ -4,7 +4,7 @@ import { Effect } from "Materials";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { ToGammaSpace } from "Math";
 import { ToGammaSpace } from "Math";
-    
+
     /**
     /**
      * The extract highlights post process sets all pixels to black except pixels above the specified luminance threshold. Used as the first step for a bloom effect.
      * The extract highlights post process sets all pixels to black except pixels above the specified luminance threshold. Used as the first step for a bloom effect.
      */
      */

+ 1 - 0
src/PostProcess/filterPostProcess.ts

@@ -4,6 +4,7 @@ import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+
     /**
     /**
      * Applies a kernel filter to the image
      * Applies a kernel filter to the image
      */
      */

+ 1 - 1
src/PostProcess/fxaaPostProcess.ts

@@ -3,7 +3,7 @@ import { Camera } from "Cameras";
 import { Effect, Texture } from "Materials";
 import { Effect, Texture } from "Materials";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
-    
+
     /**
     /**
      * Fxaa post process
      * Fxaa post process
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses#fxaa
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses#fxaa

+ 1 - 1
src/PostProcess/grainPostProcess.ts

@@ -3,7 +3,7 @@ import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
-    
+
     /**
     /**
      * The GrainPostProcess adds noise to the image at mid luminance levels
      * The GrainPostProcess adds noise to the image at mid luminance levels
      */
      */

+ 1 - 0
src/PostProcess/highlightsPostProcess.ts

@@ -2,6 +2,7 @@ import { Nullable } from "types";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+
     /**
     /**
      * Extracts highlights from the image
      * Extracts highlights from the image
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses

+ 3 - 1
src/PostProcess/imageProcessingPostProcess.ts

@@ -3,8 +3,10 @@ import { Observer, serialize } from "Tools";
 import { Color4 } from "Math";
 import { Color4 } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { BaseTexture, ImageProcessingConfiguration, Effect, ColorCurves, IImageProcessingConfigurationDefines } from "Materials";
 import { BaseTexture, ImageProcessingConfiguration, Effect, ColorCurves, IImageProcessingConfigurationDefines } from "Materials";
-import { PostProcess, Scene, PostProcessOptions } from "PostProcess";
+import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+import { Scene } from "scene";
+
     /**
     /**
      * ImageProcessingPostProcess
      * ImageProcessingPostProcess
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses#imageprocessing
      * @see https://doc.babylonjs.com/how_to/how_to_use_postprocesses#imageprocessing

+ 3 - 1
src/PostProcess/motionBlurPostProcess.ts

@@ -3,9 +3,11 @@ import { Tools } from "Tools";
 import { Vector2 } from "Math";
 import { Vector2 } from "Math";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Effect } from "Materials";
 import { Effect } from "Materials";
-import { PostProcess, Scene, PostProcessOptions } from "PostProcess";
+import { PostProcess, PostProcessOptions } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { GeometryBufferRenderer } from "Rendering";
 import { GeometryBufferRenderer } from "Rendering";
+import { Scene } from "scene";
+
     /**
     /**
      * The Motion Blur Post Process which blurs an image based on the objects velocity in scene.
      * The Motion Blur Post Process which blurs an image based on the objects velocity in scene.
      * Velocity can be affected by each object's rotation, position and scale depending on the transformation speed.
      * Velocity can be affected by each object's rotation, position and scale depending on the transformation speed.

+ 3 - 1
src/PostProcess/volumetricLightScatteringPostProcess.ts

@@ -1,10 +1,12 @@
 import { SmartArray, Tools, serializeAsVector3, serialize, serializeAsMeshReference } from "Tools";
 import { SmartArray, Tools, serializeAsVector3, serialize, serializeAsMeshReference } from "Tools";
 import { Color4, Color3, Vector2, Vector3, Matrix, Viewport } from "Math";
 import { Color4, Color3, Vector2, Vector3, Matrix, Viewport } from "Math";
-import { Mesh, SubMesh, AbstractMesh, Scene, VertexBuffer } from "Mesh";
+import { Mesh, SubMesh, AbstractMesh, VertexBuffer } from "Mesh";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Material, StandardMaterial, RenderTargetTexture, Effect, Texture } from "Materials";
 import { Material, StandardMaterial, RenderTargetTexture, Effect, Texture } from "Materials";
 import { PostProcess } from "PostProcess";
 import { PostProcess } from "PostProcess";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+import { Scene } from "scene";
+
     /**
     /**
      *  Inspired by http://http.developer.nvidia.com/GPUGems3/gpugems3_ch13.html
      *  Inspired by http://http.developer.nvidia.com/GPUGems3/gpugems3_ch13.html
      */
      */

+ 2 - 0
src/Probes/reflectionProbe.ts

@@ -2,6 +2,8 @@ import { RenderTargetTexture } from "Materials";
 import { Matrix, Vector3 } from "Math";
 import { Matrix, Vector3 } from "Math";
 import { AbstractMesh } from "Mesh";
 import { AbstractMesh } from "Mesh";
 import { Nullable } from "types";
 import { Nullable } from "types";
+import { Scene } from "scene";
+import { Engine } from "Engine";
 
 
 declare module "scene" {
 declare module "scene" {
     export interface Scene {
     export interface Scene {

+ 1 - 0
src/Rendering/edgesRenderer.ts

@@ -7,6 +7,7 @@ import { LineEdgesRenderer } from "Rendering";
 import { ShaderMaterial, Effect, Material } from "Materials";
 import { ShaderMaterial, Effect, Material } from "Materials";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+import { Node } from "node";
 
 
 declare module "Mesh/AbstractMesh" {
 declare module "Mesh/AbstractMesh" {
     export interface AbstractMesh {
     export interface AbstractMesh {

+ 2 - 1
src/Rendering/geometryBufferRenderer.ts

@@ -1,10 +1,11 @@
 import { Matrix, Color4 } from "Math";
 import { Matrix, Color4 } from "Math";
 import { Mesh, SubMesh, VertexBuffer } from "Mesh";
 import { Mesh, SubMesh, VertexBuffer } from "Mesh";
-import { Engine } from "Particles";
+import { Engine } from "Engine";
 import { SmartArray } from "Tools";
 import { SmartArray } from "Tools";
 import { MultiRenderTarget, Effect, Texture, Material } from "Materials";
 import { MultiRenderTarget, Effect, Texture, Material } from "Materials";
 import { GeometryBufferRendererSceneComponent } from "Rendering";
 import { GeometryBufferRendererSceneComponent } from "Rendering";
 import { Scene } from "scene";
 import { Scene } from "scene";
+import { SceneComponentConstants } from "sceneComponent";
 
 
     /**
     /**
      * This renderer is helpfull to fill one of the render target with a geometry buffer.
      * This renderer is helpfull to fill one of the render target with a geometry buffer.

+ 2 - 2
src/Rendering/lineEdgesRenderer.ts

@@ -1,5 +1,5 @@
-import { EdgesRenderer, AbstractMesh } from "Rendering";
-import { VertexBuffer } from "Mesh";
+import { EdgesRenderer } from "Rendering";
+import { VertexBuffer, AbstractMesh } from "Mesh";
 import { Tmp, Vector3 } from "Math";
 import { Tmp, Vector3 } from "Math";
 
 
     /**
     /**

+ 1 - 1
src/Rendering/outlineRenderer.ts

@@ -1,6 +1,6 @@
 import { AbstractMesh, SubMesh, _InstancesBatch, VertexBuffer } from "Mesh";
 import { AbstractMesh, SubMesh, _InstancesBatch, VertexBuffer } from "Mesh";
 import { Scene } from "scene";
 import { Scene } from "scene";
-import { Engine } from "Particles";
+import { Engine } from "Engine";
 import { ISceneComponent, SceneComponentConstants } from "sceneComponent";
 import { ISceneComponent, SceneComponentConstants } from "sceneComponent";
 import { Effect, Material } from "Materials";
 import { Effect, Material } from "Materials";
 
 

+ 2 - 2
src/Rendering/renderingGroup.ts

@@ -1,7 +1,6 @@
 import { SmartArray } from "Tools";
 import { SmartArray } from "Tools";
-import { SubMesh } from "Mesh";
+import { AbstractMesh, SubMesh } from "Mesh";
 import { Nullable } from "types";
 import { Nullable } from "types";
-import { AbstractMesh } from "Culling";
 import { Vector3 } from "Math";
 import { Vector3 } from "Math";
 import { IParticleSystem } from "Particles";
 import { IParticleSystem } from "Particles";
 import { IEdgesRenderer } from "Rendering";
 import { IEdgesRenderer } from "Rendering";
@@ -9,6 +8,7 @@ import { ISpriteManager } from "Sprites";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { Material } from "Materials";
 import { Material } from "Materials";
 import { Scene } from "scene";
 import { Scene } from "scene";
+import { Camera } from "Cameras";
 
 
     /**
     /**
      * This represents the object necessary to create a rendering group.
      * This represents the object necessary to create a rendering group.

+ 1 - 2
src/Rendering/renderingManager.ts

@@ -1,7 +1,6 @@
 import { Nullable } from "types";
 import { Nullable } from "types";
 import { RenderingGroupInfo, Scene } from "scene";
 import { RenderingGroupInfo, Scene } from "scene";
-import { AbstractMesh } from "Culling";
-import { SubMesh } from "Mesh";
+import { AbstractMesh, SubMesh } from "Mesh";
 import { RenderingGroup } from "Rendering";
 import { RenderingGroup } from "Rendering";
 import { SmartArray } from "Tools";
 import { SmartArray } from "Tools";
 import { ISpriteManager } from "Sprites";
 import { ISpriteManager } from "Sprites";

+ 1 - 1
src/Rendering/utilityLayerRenderer.ts

@@ -1,10 +1,10 @@
 import { IDisposable, Scene } from "scene";
 import { IDisposable, Scene } from "scene";
 import { Nullable } from "types";
 import { Nullable } from "types";
 import { Observable, Observer } from "Tools";
 import { Observable, Observer } from "Tools";
-import { AbstractMesh } from "Culling";
 import { PointerInfoPre, PointerInfo, PointerEventTypes } from "Events";
 import { PointerInfoPre, PointerInfo, PointerEventTypes } from "Events";
 import { PickingInfo } from "Collisions";
 import { PickingInfo } from "Collisions";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
+import { AbstractMesh } from "Mesh";
 
 
     /**
     /**
      * Renders a layer on top of an existing scene
      * Renders a layer on top of an existing scene

+ 0 - 1
src/Sprites/sprite.ts

@@ -3,7 +3,6 @@ import { Nullable } from "types";
 import { ActionManager } from "Actions";
 import { ActionManager } from "Actions";
 import { ISpriteManager } from "Sprites";
 import { ISpriteManager } from "Sprites";
 
 
-
     /**
     /**
      * Class used to represent a sprite
      * Class used to represent a sprite
      * @see http://doc.babylonjs.com/babylon101/sprites
      * @see http://doc.babylonjs.com/babylon101/sprites

+ 3 - 1
src/Sprites/spriteManager.ts

@@ -1,8 +1,10 @@
 import { IDisposable, Scene } from "scene";
 import { IDisposable, Scene } from "scene";
 import { Nullable } from "types";
 import { Nullable } from "types";
 import { Observable, Observer } from "Tools";
 import { Observable, Observer } from "Tools";
-import { VertexBuffer } from "Mesh";
+import { VertexBuffer, Buffer } from "Mesh";
 import { Vector3 } from "Math";
 import { Vector3 } from "Math";
+import { Sprite, SpriteSceneComponent } from ".";
+import { Ray, Camera, PickingInfo, Texture, Effect, SceneComponentConstants, Material, Engine } from "index";
 
 
     /**
     /**
      * Defines the minimum interface to fullfil in order to be a sprite manager.
      * Defines the minimum interface to fullfil in order to be a sprite manager.

+ 1 - 0
src/Sprites/spriteSceneComponent.ts

@@ -6,6 +6,7 @@ import { Ray } from "Culling";
 import { Camera } from "Cameras";
 import { Camera } from "Cameras";
 import { PickingInfo } from "Collisions";
 import { PickingInfo } from "Collisions";
 import { ISceneComponent, SceneComponentConstants } from "sceneComponent";
 import { ISceneComponent, SceneComponentConstants } from "sceneComponent";
+import { ActionManager, ActionEvent } from "index";
 
 
 declare module "scene" {
 declare module "scene" {
     export interface Scene {
     export interface Scene {

+ 0 - 1
src/Tools/HDR/cubemapToSphericalPolynomial.ts

@@ -4,7 +4,6 @@ import { Nullable } from "types";
 import { Engine } from "Engine";
 import { Engine } from "Engine";
 import { CubeMapInfo } from "Tools";
 import { CubeMapInfo } from "Tools";
 
 
-
     class FileFaceOrientation {
     class FileFaceOrientation {
         public name: string;
         public name: string;
         public worldAxisForNormal: Vector3; // the world axis corresponding to the normal to the face
         public worldAxisForNormal: Vector3; // the world axis corresponding to the normal to the face

+ 9 - 1
src/Tools/dds.ts

@@ -1,3 +1,11 @@
+import { SphericalPolynomial, Scalar } from "Math";
+
+import { Engine, InternalTexture } from "index";
+
+import { Nullable } from "types";
+
+import { Tools, CubeMapToSphericalPolynomialTools } from ".";
+
     // Based on demo done by Brandon Jones - http://media.tojicode.com/webgl-samples/dds.html
     // Based on demo done by Brandon Jones - http://media.tojicode.com/webgl-samples/dds.html
     // All values and structures referenced from:
     // All values and structures referenced from:
     // http://msdn.microsoft.com/en-us/library/bb943991.aspx/
     // http://msdn.microsoft.com/en-us/library/bb943991.aspx/
@@ -639,4 +647,4 @@
                 info.sphericalPolynomial = undefined;
                 info.sphericalPolynomial = undefined;
             }
             }
         }
         }
-    }
+    }

+ 9 - 1
src/Tools/environmentTextureTools.ts

@@ -1,3 +1,11 @@
+import { Nullable } from "types";
+
+import { Tools } from ".";
+
+import { CubeTexture, Engine, Scene, Texture, PostProcess, InternalTexture, BaseTexture } from "index";
+
+import { Scalar, SphericalPolynomial, Vector3 } from "Math";
+
     /**
     /**
      * Raw texture data and descriptor sufficient for WebGL texture upload
      * Raw texture data and descriptor sufficient for WebGL texture upload
      */
      */
@@ -593,4 +601,4 @@
             Vector3.FromArrayToRef(irradianceInfo.xy, 0, sp.xy);
             Vector3.FromArrayToRef(irradianceInfo.xy, 0, sp.xy);
             texture._sphericalPolynomial = sp;
             texture._sphericalPolynomial = sp;
         }
         }
-    }
+    }

+ 5 - 1
src/Tools/filesInput.ts

@@ -1,3 +1,7 @@
+import { Engine, Scene, SceneLoaderProgressEvent, SceneLoader } from "index";
+
+import { Tools } from ".";
+
     /**
     /**
      * Class used to help managing file picking and drag'n'drop
      * Class used to help managing file picking and drag'n'drop
      */
      */
@@ -288,4 +292,4 @@
                 Tools.Error("Please provide a valid .babylon file.");
                 Tools.Error("Please provide a valid .babylon file.");
             }
             }
         }
         }
-    }
+    }

+ 5 - 1
src/Tools/khronosTextureContainer.ts

@@ -1,3 +1,7 @@
+import { Tools } from ".";
+
+import { InternalTexture } from "index";
+
     /**
     /**
      * for description see https://www.khronos.org/opengles/sdk/tools/KTX/
      * for description see https://www.khronos.org/opengles/sdk/tools/KTX/
      * for file layout see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/
      * for file layout see https://www.khronos.org/opengles/sdk/tools/KTX/file_format_spec/
@@ -188,4 +192,4 @@
                 height = Math.max(1.0, height * 0.5);
                 height = Math.max(1.0, height * 0.5);
             }
             }
         }
         }
-    }
+    }

+ 4 - 1
src/Tools/observable.ts

@@ -1,3 +1,7 @@
+import { Nullable } from "types";
+
+import { Tools } from ".";
+
     /**
     /**
      * A class serves as a medium between the observable and its observers
      * A class serves as a medium between the observable and its observers
      */
      */
@@ -424,4 +428,3 @@
             return false;
             return false;
         }
         }
     }
     }
-

+ 4 - 1
src/Tools/performanceMonitor.ts

@@ -1,3 +1,7 @@
+import { Nullable } from "types";
+
+import { Tools } from ".";
+
     /**
     /**
 	 * Performance monitor tracks rolling average frame-time and frame-time variance over a user defined sliding-window
 	 * Performance monitor tracks rolling average frame-time and frame-time variance over a user defined sliding-window
 	 */
 	 */
@@ -221,4 +225,3 @@
         }
         }
 
 
     }
     }
-

+ 5 - 1
src/Tools/promise.ts

@@ -1,3 +1,7 @@
+import { Nullable } from "types";
+
+import { Tools } from ".";
+
     enum PromiseStates {
     enum PromiseStates {
         Pending,
         Pending,
         Fulfilled,
         Fulfilled,
@@ -251,4 +255,4 @@
                 root.Promise = InternalPromise;
                 root.Promise = InternalPromise;
             }
             }
         }
         }
-    }
+    }

+ 9 - 1
src/Tools/sceneOptimizer.ts

@@ -1,3 +1,11 @@
+import { Scene, IDisposable, Engine } from "index";
+
+import { AbstractMesh, Mesh } from "Mesh";
+
+import { Nullable } from "types";
+
+import { Observer, Observable } from ".";
+
     /**
     /**
      * Defines the root class used to create scene optimization to use with SceneOptimizer
      * Defines the root class used to create scene optimization to use with SceneOptimizer
      * @description More details at http://doc.babylonjs.com/how_to/how_to_use_sceneoptimizer
      * @description More details at http://doc.babylonjs.com/how_to/how_to_use_sceneoptimizer
@@ -840,4 +848,4 @@
 
 
             return optimizer;
             return optimizer;
         }
         }
-    }
+    }

+ 8 - 0
src/Tools/sceneSerializer.ts

@@ -1,3 +1,11 @@
+import { Geometry, BoxGeometry, SphereGeometry, CylinderGeometry, TorusGeometry, GroundGeometry, TorusKnotGeometry, _PrimitiveGeometry, Mesh } from "Mesh";
+
+import { Plane } from "Math";
+
+import { Engine, MultiMaterial, Material, Scene, Light } from "index";
+
+import { Animation } from "Animations";
+
     var serializedGeometries: Geometry[] = [];
     var serializedGeometries: Geometry[] = [];
     var serializeGeometry = (geometry: Geometry, serializationGeometries: any): any => {
     var serializeGeometry = (geometry: Geometry, serializationGeometries: any): any => {
         if ((<any>serializedGeometries)[geometry.id]) {
         if ((<any>serializedGeometries)[geometry.id]) {

+ 3 - 1
src/Tools/stringDictionary.ts

@@ -1,3 +1,5 @@
+import { Nullable } from "types";
+
     /**
     /**
      * This class implement a typical dictionary using a string as key and the generic type T as value.
      * This class implement a typical dictionary using a string as key and the generic type T as value.
      * The underlying implementation relies on an associative array to ensure the best performances.
      * The underlying implementation relies on an associative array to ensure the best performances.
@@ -180,4 +182,4 @@
 
 
         private _count = 0;
         private _count = 0;
         private _data: {[key: string]: T} = {};
         private _data: {[key: string]: T} = {};
-    }
+    }

+ 2 - 0
src/Tools/tags.ts

@@ -1,3 +1,5 @@
+import { Tools, AndOrNotEvaluator } from ".";
+
     /**
     /**
      * Class used to store custom tags
      * Class used to store custom tags
      */
      */

+ 2 - 0
src/Tools/textureTools.ts

@@ -1,3 +1,5 @@
+import { Texture, Scene, RenderTargetTexture, InternalTexture, PassPostProcess, Engine, BaseTexture } from "index";
+
     /**
     /**
      * Class used to host texture specific utilities
      * Class used to host texture specific utilities
      */
      */

+ 5 - 1
src/Tools/tga.ts

@@ -1,3 +1,7 @@
+import { InternalTexture } from "index";
+
+import { Tools } from ".";
+
     /**
     /**
      * Based on jsTGALoader - Javascript loader for TGA file
      * Based on jsTGALoader - Javascript loader for TGA file
      * By Vincent Thibault
      * By Vincent Thibault
@@ -330,4 +334,4 @@
             return imageData;
             return imageData;
         }
         }
 
 
-    }
+    }