David Catuhe 8 tahun lalu
induk
melakukan
c19ea5cbf1
23 mengubah file dengan 10627 tambahan dan 10621 penghapusan
  1. 4231 4231
      dist/preview release/babylon.d.ts
  2. 38 38
      dist/preview release/babylon.js
  3. 20 6
      dist/preview release/babylon.max.js
  4. 4231 4231
      dist/preview release/babylon.module.d.ts
  5. 39 39
      dist/preview release/babylon.worker.js
  6. 792 789
      dist/preview release/customConfigurations/minimalViewer/babylon.d.ts
  7. 26 26
      dist/preview release/customConfigurations/minimalViewer/babylon.js
  8. 20 6
      dist/preview release/customConfigurations/minimalViewer/babylon.max.js
  9. 792 789
      dist/preview release/customConfigurations/minimalViewer/babylon.module.d.ts
  10. 1 1
      dist/preview release/gui/babylon.gui.min.js
  11. 263 263
      dist/preview release/inspector/babylon.inspector.bundle.js
  12. 24 28
      dist/preview release/inspector/babylon.inspector.d.ts
  13. 123 148
      dist/preview release/inspector/babylon.inspector.js
  14. 3 3
      dist/preview release/inspector/babylon.inspector.min.js
  15. 2 2
      dist/preview release/loaders/babylon.glTF1FileLoader.min.js
  16. 1 1
      dist/preview release/loaders/babylon.glTF2FileLoader.min.js
  17. 2 2
      dist/preview release/loaders/babylon.glTFFileLoader.min.js
  18. 1 1
      dist/preview release/loaders/babylon.objFileLoader.min.js
  19. 14 13
      dist/preview release/materialsLibrary/babylon.customMaterial.js
  20. 1 1
      dist/preview release/materialsLibrary/babylon.customMaterial.min.js
  21. 1 1
      dist/preview release/materialsLibrary/babylon.waterMaterial.min.js
  22. 1 1
      dist/preview release/postProcessesLibrary/babylon.asciiArtPostProcess.min.js
  23. 1 1
      dist/preview release/postProcessesLibrary/babylon.digitalRainPostProcess.min.js

File diff ditekan karena terlalu besar
+ 4231 - 4231
dist/preview release/babylon.d.ts


File diff ditekan karena terlalu besar
+ 38 - 38
dist/preview release/babylon.js


+ 20 - 6
dist/preview release/babylon.max.js

@@ -23838,6 +23838,7 @@ var BABYLON;
             this._areTexturesDirty = true;
             this._areFresnelDirty = true;
             this._areMiscDirty = true;
+            this._areImageProcessingDirty = true;
             this._normals = false;
             this._uvs = false;
             this._needNormals = false;
@@ -23857,6 +23858,7 @@ var BABYLON;
             this._areFresnelDirty = false;
             this._areLightsDirty = false;
             this._areMiscDirty = false;
+            this._areImageProcessingDirty = false;
         };
         MaterialDefines.prototype.markAsUnprocessed = function () {
             this._isDirty = true;
@@ -23867,6 +23869,11 @@ var BABYLON;
             this._areLightsDirty = true;
             this._areFresnelDirty = true;
             this._areMiscDirty = true;
+            this._areImageProcessingDirty = true;
+            this._isDirty = true;
+        };
+        MaterialDefines.prototype.markAsImageProcessingDirty = function () {
+            this._areImageProcessingDirty = true;
             this._isDirty = true;
         };
         MaterialDefines.prototype.markAsLightDirty = function () {
@@ -24323,6 +24330,9 @@ var BABYLON;
                 }
             }
         };
+        Material.prototype._markAllSubMeshesAsImageProcessingDirty = function () {
+            this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsImageProcessingDirty(); });
+        };
         Material.prototype._markAllSubMeshesAsTexturesDirty = function () {
             this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsTexturesDirty(); });
         };
@@ -28707,7 +28717,7 @@ var BABYLON;
             }
             // Attaches observer.
             this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(function (conf) {
-                _this._markAllSubMeshesAsTexturesDirty();
+                _this._markAllSubMeshesAsImageProcessingDirty();
             });
         };
         Object.defineProperty(StandardMaterial.prototype, "cameraColorCurvesEnabled", {
@@ -29029,15 +29039,17 @@ var BABYLON;
                     defines.BUMP = false;
                     defines.REFRACTION = false;
                 }
-                if (!this.imageProcessingConfiguration.isReady()) {
-                    return false;
-                }
-                this.imageProcessingConfiguration.prepareDefines(defines);
                 defines.ALPHAFROMDIFFUSE = this._shouldUseAlphaFromDiffuseTexture();
                 defines.EMISSIVEASILLUMINATION = this._useEmissiveAsIllumination;
                 defines.LINKEMISSIVEWITHDIFFUSE = this._linkEmissiveWithDiffuse;
                 defines.SPECULAROVERALPHA = this._useSpecularOverAlpha;
             }
+            if (defines._areImageProcessingDirty) {
+                if (!this._imageProcessingConfiguration.isReady()) {
+                    return false;
+                }
+                this._imageProcessingConfiguration.prepareDefines(defines);
+            }
             if (defines._areFresnelDirty) {
                 if (StandardMaterial.FresnelEnabled) {
                     // Fresnel
@@ -30208,7 +30220,7 @@ var BABYLON;
             }
             // Attaches observer.
             this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(function (conf) {
-                _this._markAllSubMeshesAsTexturesDirty();
+                _this._markAllSubMeshesAsImageProcessingDirty();
             });
         };
         Object.defineProperty(PBRBaseMaterial.prototype, "useLogarithmicDepth", {
@@ -30451,6 +30463,8 @@ var BABYLON;
                 defines.PREMULTIPLYALPHA = this._premultiplyAlpha;
                 defines.ALPHABLEND = this.needAlphaBlending();
                 defines.ALPHAFRESNEL = this._useAlphaFresnel;
+            }
+            if (defines._areImageProcessingDirty) {
                 if (!this._imageProcessingConfiguration.isReady()) {
                     return false;
                 }

File diff ditekan karena terlalu besar
+ 4231 - 4231
dist/preview release/babylon.module.d.ts


File diff ditekan karena terlalu besar
+ 39 - 39
dist/preview release/babylon.worker.js


File diff ditekan karena terlalu besar
+ 792 - 789
dist/preview release/customConfigurations/minimalViewer/babylon.d.ts


File diff ditekan karena terlalu besar
+ 26 - 26
dist/preview release/customConfigurations/minimalViewer/babylon.js


+ 20 - 6
dist/preview release/customConfigurations/minimalViewer/babylon.max.js

@@ -23838,6 +23838,7 @@ var BABYLON;
             this._areTexturesDirty = true;
             this._areFresnelDirty = true;
             this._areMiscDirty = true;
+            this._areImageProcessingDirty = true;
             this._normals = false;
             this._uvs = false;
             this._needNormals = false;
@@ -23857,6 +23858,7 @@ var BABYLON;
             this._areFresnelDirty = false;
             this._areLightsDirty = false;
             this._areMiscDirty = false;
+            this._areImageProcessingDirty = false;
         };
         MaterialDefines.prototype.markAsUnprocessed = function () {
             this._isDirty = true;
@@ -23867,6 +23869,11 @@ var BABYLON;
             this._areLightsDirty = true;
             this._areFresnelDirty = true;
             this._areMiscDirty = true;
+            this._areImageProcessingDirty = true;
+            this._isDirty = true;
+        };
+        MaterialDefines.prototype.markAsImageProcessingDirty = function () {
+            this._areImageProcessingDirty = true;
             this._isDirty = true;
         };
         MaterialDefines.prototype.markAsLightDirty = function () {
@@ -24323,6 +24330,9 @@ var BABYLON;
                 }
             }
         };
+        Material.prototype._markAllSubMeshesAsImageProcessingDirty = function () {
+            this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsImageProcessingDirty(); });
+        };
         Material.prototype._markAllSubMeshesAsTexturesDirty = function () {
             this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsTexturesDirty(); });
         };
@@ -35084,7 +35094,7 @@ var BABYLON;
             }
             // Attaches observer.
             this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(function (conf) {
-                _this._markAllSubMeshesAsTexturesDirty();
+                _this._markAllSubMeshesAsImageProcessingDirty();
             });
         };
         Object.defineProperty(PBRBaseMaterial.prototype, "useLogarithmicDepth", {
@@ -35327,6 +35337,8 @@ var BABYLON;
                 defines.PREMULTIPLYALPHA = this._premultiplyAlpha;
                 defines.ALPHABLEND = this.needAlphaBlending();
                 defines.ALPHAFRESNEL = this._useAlphaFresnel;
+            }
+            if (defines._areImageProcessingDirty) {
                 if (!this._imageProcessingConfiguration.isReady()) {
                     return false;
                 }
@@ -41899,7 +41911,7 @@ var BABYLON;
             }
             // Attaches observer.
             this._imageProcessingObserver = this._imageProcessingConfiguration.onUpdateParameters.add(function (conf) {
-                _this._markAllSubMeshesAsTexturesDirty();
+                _this._markAllSubMeshesAsImageProcessingDirty();
             });
         };
         Object.defineProperty(StandardMaterial.prototype, "cameraColorCurvesEnabled", {
@@ -42221,15 +42233,17 @@ var BABYLON;
                     defines.BUMP = false;
                     defines.REFRACTION = false;
                 }
-                if (!this.imageProcessingConfiguration.isReady()) {
-                    return false;
-                }
-                this.imageProcessingConfiguration.prepareDefines(defines);
                 defines.ALPHAFROMDIFFUSE = this._shouldUseAlphaFromDiffuseTexture();
                 defines.EMISSIVEASILLUMINATION = this._useEmissiveAsIllumination;
                 defines.LINKEMISSIVEWITHDIFFUSE = this._linkEmissiveWithDiffuse;
                 defines.SPECULAROVERALPHA = this._useSpecularOverAlpha;
             }
+            if (defines._areImageProcessingDirty) {
+                if (!this._imageProcessingConfiguration.isReady()) {
+                    return false;
+                }
+                this._imageProcessingConfiguration.prepareDefines(defines);
+            }
             if (defines._areFresnelDirty) {
                 if (StandardMaterial.FresnelEnabled) {
                     // Fresnel

File diff ditekan karena terlalu besar
+ 792 - 789
dist/preview release/customConfigurations/minimalViewer/babylon.module.d.ts


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/gui/babylon.gui.min.js


File diff ditekan karena terlalu besar
+ 263 - 263
dist/preview release/inspector/babylon.inspector.bundle.js


+ 24 - 28
dist/preview release/inspector/babylon.inspector.d.ts

@@ -61,6 +61,7 @@ declare module INSPECTOR {
          * Set 'firstTime' to true if there is no inspector created beforehands
          */
         openPopup(firstTime?: boolean): void;
+        getActiveTabIndex(): number;
     }
 }
 
@@ -337,6 +338,23 @@ declare module INSPECTOR {
 }
 
 declare module INSPECTOR {
+    class PhysicsImpostorAdapter extends Adapter implements IToolVisible {
+        private _viewer;
+        private _isVisible;
+        constructor(obj: BABYLON.PhysicsImpostor, viewer: BABYLON.Debug.PhysicsViewer);
+        /** Returns the name displayed in the tree */
+        id(): string;
+        /** Returns the type of this object - displayed in the tree */
+        type(): string;
+        /** Returns the list of properties to be displayed for this adapter */
+        getProperties(): Array<PropertyLine>;
+        getTools(): Array<AbstractTreeTool>;
+        setVisible(b: boolean): void;
+        isVisible(): boolean;
+    }
+}
+
+declare module INSPECTOR {
     class GUIAdapter extends Adapter implements IToolVisible {
         constructor(obj: BABYLON.GUI.Control);
         /** Returns the name displayed in the tree */
@@ -444,23 +462,6 @@ declare module INSPECTOR {
 }
 
 declare module INSPECTOR {
-    class PhysicsImpostorAdapter extends Adapter implements IToolVisible {
-        private _viewer;
-        private _isVisible;
-        constructor(obj: BABYLON.PhysicsImpostor, viewer: BABYLON.Debug.PhysicsViewer);
-        /** Returns the name displayed in the tree */
-        id(): string;
-        /** Returns the type of this object - displayed in the tree */
-        type(): string;
-        /** Returns the list of properties to be displayed for this adapter */
-        getProperties(): Array<PropertyLine>;
-        getTools(): Array<AbstractTreeTool>;
-        setVisible(b: boolean): void;
-        isVisible(): boolean;
-    }
-}
-
-declare module INSPECTOR {
     interface SortDirection {
         [property: string]: number;
     }
@@ -1031,6 +1032,7 @@ declare module INSPECTOR {
         switchMeshTab(mesh?: BABYLON.AbstractMesh): void;
         /** Returns the active tab */
         getActiveTab(): Tab;
+        getActiveTabIndex(): number;
         readonly inspector: Inspector;
         /**
          * Returns the total width in pixel of the tabbar,
@@ -1102,22 +1104,16 @@ declare module INSPECTOR {
     class LabelTool extends AbstractTool {
         /** True if label are displayed, false otherwise */
         private _isDisplayed;
-        private _canvas;
+        private _advancedTexture;
         private _labelInitialized;
         private _scene;
-        private _canvas2DLoaded;
-        private _newMeshObserver;
-        private _removedMeshObserver;
-        private _newLightObserver;
-        private _removedLightObserver;
-        private _newCameraObserver;
-        private _removedCameraObserver;
+        private _guiLoaded;
         constructor(parent: HTMLElement, inspector: Inspector);
         dispose(): void;
-        private _checkC2DLoaded();
+        private _checkGUILoaded();
         private _initializeLabels();
-        private _createLabel(node);
-        private _removeLabel(node);
+        private _createLabel(mesh);
+        private _removeLabel(mesh);
         action(): void;
     }
 }

+ 123 - 148
dist/preview release/inspector/babylon.inspector.js

@@ -320,6 +320,9 @@ var INSPECTOR;
                 });
             }
         };
+        Inspector.prototype.getActiveTabIndex = function () {
+            return this._tabbar.getActiveTabIndex();
+        };
         return Inspector;
     }());
     INSPECTOR.Inspector = Inspector;
@@ -1002,6 +1005,73 @@ var __extends = (this && this.__extends) || (function () {
 })();
 var INSPECTOR;
 (function (INSPECTOR) {
+    var PhysicsImpostorAdapter = (function (_super) {
+        __extends(PhysicsImpostorAdapter, _super);
+        function PhysicsImpostorAdapter(obj, viewer) {
+            var _this = _super.call(this, obj) || this;
+            _this._isVisible = false;
+            _this._viewer = viewer;
+            return _this;
+        }
+        /** Returns the name displayed in the tree */
+        PhysicsImpostorAdapter.prototype.id = function () {
+            var str = '';
+            var physicsImposter = this._obj;
+            if (physicsImposter && physicsImposter.object) {
+                str = physicsImposter.object.name;
+            } // otherwise nothing displayed        
+            return str;
+        };
+        /** Returns the type of this object - displayed in the tree */
+        PhysicsImpostorAdapter.prototype.type = function () {
+            return INSPECTOR.Helpers.GET_TYPE(this._obj);
+        };
+        /** Returns the list of properties to be displayed for this adapter */
+        PhysicsImpostorAdapter.prototype.getProperties = function () {
+            var propertiesLines = [];
+            for (var _i = 0, _a = INSPECTOR.PROPERTIES['PhysicsImpostor'].properties; _i < _a.length; _i++) {
+                var dirty = _a[_i];
+                var infos = new INSPECTOR.Property(dirty, this._obj);
+                propertiesLines.push(new INSPECTOR.PropertyLine(infos));
+            }
+            return propertiesLines;
+        };
+        PhysicsImpostorAdapter.prototype.getTools = function () {
+            var tools = [];
+            tools.push(new INSPECTOR.Checkbox(this));
+            return tools;
+        };
+        PhysicsImpostorAdapter.prototype.setVisible = function (b) {
+            this._isVisible = b;
+            if (b) {
+                this._viewer.showImpostor(this._obj);
+            }
+            else {
+                this._viewer.hideImpostor(this._obj);
+            }
+        };
+        PhysicsImpostorAdapter.prototype.isVisible = function () {
+            return this._isVisible;
+        };
+        return PhysicsImpostorAdapter;
+    }(INSPECTOR.Adapter));
+    INSPECTOR.PhysicsImpostorAdapter = PhysicsImpostorAdapter;
+})(INSPECTOR || (INSPECTOR = {}));
+
+//# sourceMappingURL=PhysicsImpostorAdapter.js.map
+
+var __extends = (this && this.__extends) || (function () {
+    var extendStatics = Object.setPrototypeOf ||
+        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
+        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
+    return function (d, b) {
+        extendStatics(d, b);
+        function __() { this.constructor = d; }
+        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
+    };
+})();
+var INSPECTOR;
+(function (INSPECTOR) {
     var GUIAdapter = (function (_super) {
         __extends(GUIAdapter, _super);
         function GUIAdapter(obj) {
@@ -1482,9 +1552,9 @@ var INSPECTOR;
             this._obj.computeWorldMatrix();
             var m = this._obj.getWorldMatrix();
             // Axis
-            var x = new BABYLON.Vector3(8, 0, 0);
-            var y = new BABYLON.Vector3(0, 8, 0);
-            var z = new BABYLON.Vector3(0, 0, 8);
+            var x = new BABYLON.Vector3(8 / this._obj.scaling.x, 0, 0);
+            var y = new BABYLON.Vector3(0, 8 / this._obj.scaling.y, 0);
+            var z = new BABYLON.Vector3(0, 0, 8 / this._obj.scaling.z);
             // Draw an axis of the given color
             var _drawAxis = function (color, start, end) {
                 var axis = BABYLON.Mesh.CreateLines("###axis###", [
@@ -1527,73 +1597,6 @@ var __extends = (this && this.__extends) || (function () {
 })();
 var INSPECTOR;
 (function (INSPECTOR) {
-    var PhysicsImpostorAdapter = (function (_super) {
-        __extends(PhysicsImpostorAdapter, _super);
-        function PhysicsImpostorAdapter(obj, viewer) {
-            var _this = _super.call(this, obj) || this;
-            _this._isVisible = false;
-            _this._viewer = viewer;
-            return _this;
-        }
-        /** Returns the name displayed in the tree */
-        PhysicsImpostorAdapter.prototype.id = function () {
-            var str = '';
-            var physicsImposter = this._obj;
-            if (physicsImposter && physicsImposter.object) {
-                str = physicsImposter.object.name;
-            } // otherwise nothing displayed        
-            return str;
-        };
-        /** Returns the type of this object - displayed in the tree */
-        PhysicsImpostorAdapter.prototype.type = function () {
-            return INSPECTOR.Helpers.GET_TYPE(this._obj);
-        };
-        /** Returns the list of properties to be displayed for this adapter */
-        PhysicsImpostorAdapter.prototype.getProperties = function () {
-            var propertiesLines = [];
-            for (var _i = 0, _a = INSPECTOR.PROPERTIES['PhysicsImpostor'].properties; _i < _a.length; _i++) {
-                var dirty = _a[_i];
-                var infos = new INSPECTOR.Property(dirty, this._obj);
-                propertiesLines.push(new INSPECTOR.PropertyLine(infos));
-            }
-            return propertiesLines;
-        };
-        PhysicsImpostorAdapter.prototype.getTools = function () {
-            var tools = [];
-            tools.push(new INSPECTOR.Checkbox(this));
-            return tools;
-        };
-        PhysicsImpostorAdapter.prototype.setVisible = function (b) {
-            this._isVisible = b;
-            if (b) {
-                this._viewer.showImpostor(this._obj);
-            }
-            else {
-                this._viewer.hideImpostor(this._obj);
-            }
-        };
-        PhysicsImpostorAdapter.prototype.isVisible = function () {
-            return this._isVisible;
-        };
-        return PhysicsImpostorAdapter;
-    }(INSPECTOR.Adapter));
-    INSPECTOR.PhysicsImpostorAdapter = PhysicsImpostorAdapter;
-})(INSPECTOR || (INSPECTOR = {}));
-
-//# sourceMappingURL=PhysicsImpostorAdapter.js.map
-
-var __extends = (this && this.__extends) || (function () {
-    var extendStatics = Object.setPrototypeOf ||
-        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
-        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
-    return function (d, b) {
-        extendStatics(d, b);
-        function __() { this.constructor = d; }
-        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
-    };
-})();
-var INSPECTOR;
-(function (INSPECTOR) {
     var DetailPanel = (function (_super) {
         __extends(DetailPanel, _super);
         function DetailPanel(dr) {
@@ -4171,6 +4174,14 @@ var INSPECTOR;
                 }
             }
         };
+        TabBar.prototype.getActiveTabIndex = function () {
+            for (var i = 0; i < this._tabs.length; i++) {
+                if (this._tabs[i].isActive()) {
+                    return i;
+                }
+            }
+            return 0;
+        };
         Object.defineProperty(TabBar.prototype, "inspector", {
             get: function () {
                 return this._inspector;
@@ -4439,40 +4450,26 @@ var INSPECTOR;
             var _this = _super.call(this, 'fa-tags', parent, inspector, 'Display mesh names on the canvas') || this;
             /** True if label are displayed, false otherwise */
             _this._isDisplayed = false;
-            _this._canvas = null;
+            _this._advancedTexture = null;
             _this._labelInitialized = false;
             _this._scene = null;
-            _this._canvas2DLoaded = false;
-            _this._newMeshObserver = null;
-            _this._removedMeshObserver = null;
-            _this._newLightObserver = null;
-            _this._removedLightObserver = null;
-            _this._newCameraObserver = null;
-            _this._removedCameraObserver = null;
+            _this._guiLoaded = false;
             _this._scene = inspector.scene;
             return _this;
         }
         LabelTool.prototype.dispose = function () {
-            if (this._newMeshObserver) {
-                this._scene.onNewMeshAddedObservable.remove(this._newMeshObserver);
-                this._scene.onMeshRemovedObservable.remove(this._removedMeshObserver);
-                this._scene.onNewLightAddedObservable.remove(this._newLightObserver);
-                this._scene.onLightRemovedObservable.remove(this._removedLightObserver);
-                this._scene.onNewCameraAddedObservable.remove(this._newCameraObserver);
-                this._scene.onCameraRemovedObservable.remove(this._removedCameraObserver);
-                this._newMeshObserver = this._newLightObserver = this._newCameraObserver = this._removedMeshObserver = this._removedLightObserver = this._removedCameraObserver = null;
-            }
-            this._canvas.dispose();
-            this._canvas = null;
-        };
-        LabelTool.prototype._checkC2DLoaded = function () {
-            if (this._canvas2DLoaded === true) {
+            if (this._advancedTexture) {
+                this._advancedTexture.dispose();
+            }
+        };
+        LabelTool.prototype._checkGUILoaded = function () {
+            if (this._guiLoaded === true) {
                 return true;
             }
-            if (BABYLON.Canvas2D) {
-                this._canvas2DLoaded = true;
+            if (BABYLON.GUI) {
+                this._guiLoaded = true;
             }
-            return this._canvas2DLoaded;
+            return this._guiLoaded;
         };
         LabelTool.prototype._initializeLabels = function () {
             var _this = this;
@@ -4480,74 +4477,52 @@ var INSPECTOR;
             if (this._labelInitialized) {
                 return;
             }
-            // Can't initialize them if the Canvas2D lib is not loaded yet
-            if (!this._checkC2DLoaded()) {
+            // Can't initialize them if the GUI lib is not loaded yet
+            if (!this._checkGUILoaded()) {
                 return;
             }
             // Create the canvas that will be used to display the labels
-            this._canvas = new BABYLON.ScreenSpaceCanvas2D(this._scene, { id: "###Label Canvas###" /*, cachingStrategy: BABYLON.Canvas2D.CACHESTRATEGY_TOPLEVELGROUPS*/ });
+            this._advancedTexture = BABYLON.GUI.AdvancedDynamicTexture.CreateFullscreenUI("UI");
             // Create label for all the Meshes, Lights and Cameras
             // Those that will be created/removed after this method is called will be taken care by the event handlers added below
             for (var _i = 0, _a = this._scene.meshes; _i < _a.length; _i++) {
                 var m = _a[_i];
                 this._createLabel(m);
             }
-            for (var _b = 0, _c = this._scene.lights; _b < _c.length; _b++) {
-                var l = _c[_b];
-                this._createLabel(l);
-            }
-            for (var _d = 0, _e = this._scene.cameras; _d < _e.length; _d++) {
-                var c = _e[_d];
-                this._createLabel(c);
-            }
-            // Add handlers for new/removed meshes, camera and lights
-            this._newMeshObserver = this._scene.onNewMeshAddedObservable.add(function (e, s) {
-                _this._createLabel(e);
-            });
-            this._removedMeshObserver = this._scene.onMeshRemovedObservable.add(function (e, s) {
-                _this._removeLabel(e);
+            this._scene.onNewMeshAddedObservable.add(function (m, s) {
+                _this._createLabel(m);
             });
-            this._newLightObserver = this._scene.onNewLightAddedObservable.add(function (e, s) {
-                _this._createLabel(e);
-            });
-            this._removedLightObserver = this._scene.onLightRemovedObservable.add(function (e, s) {
-                _this._removeLabel(e);
-            });
-            this._newCameraObserver = this._scene.onNewCameraAddedObservable.add(function (e, s) {
-                _this._createLabel(e);
-            });
-            this._removedCameraObserver = this._scene.onCameraRemovedObservable.add(function (e, s) {
-                _this._removeLabel(e);
+            this._scene.onMeshRemovedObservable.add(function (m, s) {
+                _this._removeLabel(m);
             });
             this._labelInitialized = true;
         };
-        LabelTool.prototype._createLabel = function (node) {
+        LabelTool.prototype._createLabel = function (mesh) {
             // Don't create label for "system nodes" (starting and ending with ###)
-            var name = node.name;
+            var name = mesh.name;
             if (INSPECTOR.Helpers.IsSystemName(name)) {
                 return;
             }
-            var labelGroup = new BABYLON.Group2D({ parent: this._canvas, id: "Label of " + node.name, trackNode: node, origin: BABYLON.Vector2.Zero(),
-                children: [
-                    new BABYLON.Rectangle2D({ id: "LabelRect", x: 0, y: 0, width: 100, height: 30, origin: BABYLON.Vector2.Zero(), border: "#FFFFFFFF", fill: "#808080B0", children: [
-                            new BABYLON.Text2D(node.name, { x: 10, y: 4, fontName: "bold 16px Arial", fontSignedDistanceField: true })
-                        ]
-                    })
-                ] });
-            var r = labelGroup.children[0];
-            var t = r.children[0];
-            var ts = t.textSize.width;
-            r.width = ts + 20;
-            r.height = t.textSize.height + 12;
-            labelGroup.addExternalData("owner", node);
-            return labelGroup;
-        };
-        LabelTool.prototype._removeLabel = function (node) {
-            for (var _i = 0, _a = this._canvas.children; _i < _a.length; _i++) {
+            if (mesh) {
+                var rect1 = new BABYLON.GUI.Rectangle();
+                rect1.width = 4 + 10 * name.length + "px";
+                rect1.height = "22px";
+                rect1.background = "rgba(0,0,0,0.6)";
+                rect1.color = "black";
+                this._advancedTexture.addControl(rect1);
+                var label = new BABYLON.GUI.TextBlock();
+                label.text = name;
+                label.fontSize = 12;
+                rect1.addControl(label);
+                rect1.linkWithMesh(mesh);
+            }
+        };
+        LabelTool.prototype._removeLabel = function (mesh) {
+            for (var _i = 0, _a = this._advancedTexture._rootContainer.children; _i < _a.length; _i++) {
                 var g = _a[_i];
-                var ed = g.getExternalData("owner");
-                if (ed === node) {
-                    g.dispose();
+                var ed = g._linkedMesh;
+                if (ed === mesh) {
+                    this._advancedTexture.removeControl(g);
                     break;
                 }
             }
@@ -4555,7 +4530,7 @@ var INSPECTOR;
         // Action : Display/hide mesh names on the canvas
         LabelTool.prototype.action = function () {
             // Don't toggle if the script is not loaded
-            if (!this._checkC2DLoaded()) {
+            if (!this._checkGUILoaded()) {
                 return;
             }
             // Toggle the label display state
@@ -4563,10 +4538,10 @@ var INSPECTOR;
             // Check if we have to display the labels
             if (this._isDisplayed) {
                 this._initializeLabels();
-                this._canvas.levelVisible = true;
+                this._advancedTexture._rootContainer.isVisible = true;
             }
             else {
-                this._canvas.levelVisible = false;
+                this._advancedTexture._rootContainer.isVisible = false;
             }
         };
         return LabelTool;

File diff ditekan karena terlalu besar
+ 3 - 3
dist/preview release/inspector/babylon.inspector.min.js


File diff ditekan karena terlalu besar
+ 2 - 2
dist/preview release/loaders/babylon.glTF1FileLoader.min.js


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/loaders/babylon.glTF2FileLoader.min.js


File diff ditekan karena terlalu besar
+ 2 - 2
dist/preview release/loaders/babylon.glTFFileLoader.min.js


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/loaders/babylon.objFileLoader.min.js


+ 14 - 13
dist/preview release/materialsLibrary/babylon.customMaterial.js

@@ -105,14 +105,9 @@ varying vec3 vDirectionW;\n\
 #endif\n\
 #include<reflectionFunction>\n\
 #endif\n\
-#ifdef CAMERACOLORGRADING\n\
-#include<colorGradingDefinition> \n\
-#include<colorGrading>\n\
-#endif\n\
-#ifdef CAMERACOLORCURVES\n\
-#include<colorCurvesDefinition>\n\
-#include<colorCurves>\n\
-#endif\n\
+#include<imageProcessingDeclaration>\n\
+#include<imageProcessingFunctions>\n\
+\n\
 #include<bumpFragmentFunctions>\n\
 #include<clipPlaneFragmentDeclaration>\n\
 #include<logDepthDeclaration>\n\
@@ -317,12 +312,18 @@ color.rgb+=lightmapColor;\n\
 #endif\n\
 #include<logDepthFragment>\n\
 #include<fogFragment>\n\
-#ifdef CAMERACOLORGRADING\n\
-color=colorGrades(color);\n\
-#endif\n\
-#ifdef CAMERACOLORCURVES\n\
-color.rgb=applyColorCurves(color.rgb);\n\
+\n\
+// Apply image processing if relevant. As this applies in linear space, \n\
+// We first move from gamma to linear.\n\
+#ifdef IMAGEPROCESSINGPOSTPROCESS\n\
+	color.rgb = toLinearSpace(color.rgb);\n\
+#else\n\
+	#ifdef IMAGEPROCESSING\n\
+		color.rgb = toLinearSpace(color.rgb);\n\
+		color = applyImageProcessing(color);\n\
+	#endif\n\
 #endif\n\
+\n\
 #[Fragment_Before_FragColor]\n\
 gl_FragColor=color;\n\
 }";

File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/materialsLibrary/babylon.customMaterial.min.js


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/materialsLibrary/babylon.waterMaterial.min.js


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/postProcessesLibrary/babylon.asciiArtPostProcess.min.js


File diff ditekan karena terlalu besar
+ 1 - 1
dist/preview release/postProcessesLibrary/babylon.digitalRainPostProcess.min.js