David Catuhe 8 năm trước cách đây
mục cha
commit
92bf3cd566

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1297 - 1297
dist/preview release/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 9 - 9
dist/preview release/babylon.js


+ 15 - 3
dist/preview release/babylon.max.js

@@ -17108,7 +17108,7 @@ var BABYLON;
         Object.defineProperty(Scene.prototype, "mainSoundTrack", {
             get: function () {
                 if (!this._mainSoundTrack) {
-                    // this._mainSoundTrack = new SoundTrack(this, { mainTrack: true });
+                    this._mainSoundTrack = new BABYLON.SoundTrack(this, { mainTrack: true });
                 }
                 return this._mainSoundTrack;
             },
@@ -57001,7 +57001,7 @@ var BABYLON;
         };
         ImageProcessingPostProcess.prototype._updateParameters = function () {
             this._defines.FROMLINEARSPACE = this._fromLinearSpace;
-            this.imageProcessingConfiguration.prepareDefines(this._defines);
+            this.imageProcessingConfiguration.prepareDefines(this._defines, true);
             var defines = "";
             for (var define in this._defines) {
                 if (this._defines[define]) {
@@ -71165,7 +71165,19 @@ var BABYLON;
          * Prepare the list of defines associated to the shader.
          * @param defines the list of defines to complete
          */
-        ImageProcessingConfiguration.prototype.prepareDefines = function (defines) {
+        ImageProcessingConfiguration.prototype.prepareDefines = function (defines, forPostProcess) {
+            if (forPostProcess === void 0) { forPostProcess = false; }
+            if (forPostProcess !== this.applyByPostProcess) {
+                defines.VIGNETTE = false;
+                defines.TONEMAPPING = false;
+                defines.CONTRAST = false;
+                defines.EXPOSURE = false;
+                defines.COLORCURVES = false;
+                defines.COLORGRADING = false;
+                defines.IMAGEPROCESSING = false;
+                defines.IMAGEPROCESSINGPOSTPROCESS = this.applyByPostProcess;
+                return;
+            }
             defines.VIGNETTE = this.vignetteEnabled;
             defines.VIGNETTEBLENDMODEMULTIPLY = (this.vignetteBlendMode === ImageProcessingConfiguration._VIGNETTEMODE_MULTIPLY);
             defines.VIGNETTEBLENDMODEOPAQUE = !defines.VIGNETTEBLENDMODEMULTIPLY;

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 1297 - 1297
dist/preview release/babylon.module.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 9 - 9
dist/preview release/babylon.worker.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 5917 - 5917
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 9 - 9
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.js


+ 15 - 3
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.max.js

@@ -17108,7 +17108,7 @@ var BABYLON;
         Object.defineProperty(Scene.prototype, "mainSoundTrack", {
             get: function () {
                 if (!this._mainSoundTrack) {
-                    // this._mainSoundTrack = new SoundTrack(this, { mainTrack: true });
+                    this._mainSoundTrack = new BABYLON.SoundTrack(this, { mainTrack: true });
                 }
                 return this._mainSoundTrack;
             },
@@ -57001,7 +57001,7 @@ var BABYLON;
         };
         ImageProcessingPostProcess.prototype._updateParameters = function () {
             this._defines.FROMLINEARSPACE = this._fromLinearSpace;
-            this.imageProcessingConfiguration.prepareDefines(this._defines);
+            this.imageProcessingConfiguration.prepareDefines(this._defines, true);
             var defines = "";
             for (var define in this._defines) {
                 if (this._defines[define]) {
@@ -71165,7 +71165,19 @@ var BABYLON;
          * Prepare the list of defines associated to the shader.
          * @param defines the list of defines to complete
          */
-        ImageProcessingConfiguration.prototype.prepareDefines = function (defines) {
+        ImageProcessingConfiguration.prototype.prepareDefines = function (defines, forPostProcess) {
+            if (forPostProcess === void 0) { forPostProcess = false; }
+            if (forPostProcess !== this.applyByPostProcess) {
+                defines.VIGNETTE = false;
+                defines.TONEMAPPING = false;
+                defines.CONTRAST = false;
+                defines.EXPOSURE = false;
+                defines.COLORCURVES = false;
+                defines.COLORGRADING = false;
+                defines.IMAGEPROCESSING = false;
+                defines.IMAGEPROCESSINGPOSTPROCESS = this.applyByPostProcess;
+                return;
+            }
             defines.VIGNETTE = this.vignetteEnabled;
             defines.VIGNETTEBLENDMODEMULTIPLY = (this.vignetteBlendMode === ImageProcessingConfiguration._VIGNETTEMODE_MULTIPLY);
             defines.VIGNETTEBLENDMODEOPAQUE = !defines.VIGNETTEBLENDMODEMULTIPLY;

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 5917 - 5917
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.module.d.ts


+ 12 - 1
src/Materials/babylon.imageProcessingConfiguration.ts

@@ -331,7 +331,18 @@ module BABYLON {
          * Prepare the list of defines associated to the shader.
          * @param defines the list of defines to complete
          */
-        public prepareDefines(defines: IImageProcessingConfigurationDefines): void {
+        public prepareDefines(defines: IImageProcessingConfigurationDefines, forPostProcess: boolean = false): void {
+            if (forPostProcess !== this.applyByPostProcess) {
+                defines.VIGNETTE = false;
+                defines.TONEMAPPING = false;
+                defines.CONTRAST = false;
+                defines.EXPOSURE = false;
+                defines.COLORCURVES = false;
+                defines.COLORGRADING = false;  
+                defines.IMAGEPROCESSING = false;              
+                defines.IMAGEPROCESSINGPOSTPROCESS = this.applyByPostProcess;
+                return;
+            }
             defines.VIGNETTE = this.vignetteEnabled;
             defines.VIGNETTEBLENDMODEMULTIPLY = (this.vignetteBlendMode === ImageProcessingConfiguration._VIGNETTEMODE_MULTIPLY);
             defines.VIGNETTEBLENDMODEOPAQUE = !defines.VIGNETTEBLENDMODEMULTIPLY;

+ 1 - 1
src/PostProcess/babylon.imageProcessingPostProcess.ts

@@ -318,7 +318,7 @@
 
         protected _updateParameters(): void {
             this._defines.FROMLINEARSPACE = this._fromLinearSpace;
-            this.imageProcessingConfiguration.prepareDefines(this._defines);
+            this.imageProcessingConfiguration.prepareDefines(this._defines, true);
             var defines = "";
             for (const define in this._defines) {
                 if (this._defines[define]) {

+ 1 - 1
src/babylon.scene.ts

@@ -691,7 +691,7 @@
 
         public get mainSoundTrack(): SoundTrack {
             if (!this._mainSoundTrack) {
-               // this._mainSoundTrack = new SoundTrack(this, { mainTrack: true });
+                this._mainSoundTrack = new SoundTrack(this, { mainTrack: true });
             }
 
             return this._mainSoundTrack;