David Catuhe 7 سال پیش
والد
کامیت
aae4811f36

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 7780 - 7680
Playground/babylon.d.txt


BIN
Playground/textures/hollow.png


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 10894 - 10892
dist/preview release/babylon.d.ts


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 4 - 4
dist/preview release/babylon.js


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

@@ -55315,8 +55315,10 @@ var BABYLON;
              * automatic start to happen and let you decide when to start emitting particles.
              */
             this.preventAutoStart = false;
+            /** Gets or sets the estimated area used by the system. It will be used to normalize the projection onto the noise texture (default is (1, 1)) */
             this.noiseGridSize = new BABYLON.Vector2(1, 1);
-            this.noiseStrength = 50;
+            /** Gets or sets the strength to apply to the noise value (default is (10, 10, 10)) */
+            this.noiseStrength = new BABYLON.Vector3(10, 10, 10);
             /**
              * Callback triggered when the particle animation is ending.
              */
@@ -55518,8 +55520,8 @@ var BABYLON;
                             var fetchedColorB = BABYLON.Tools.FetchR(particle.position.x / _this.noiseGridSize.x + 0.66, particle.position.y / _this.noiseGridSize.y + 0.33, noiseTextureSize.width, noiseTextureSize.height, noiseTextureData);
                             var force = BABYLON.Tmp.Vector3[0];
                             var scaledForce = BABYLON.Tmp.Vector3[1];
-                            force.copyFromFloats(2 * fetchedColorR - 1, 2 * fetchedColorG - 1, 2 * fetchedColorB - 1);
-                            force.scaleToRef(_this._scaledUpdateSpeed * _this.noiseStrength, scaledForce);
+                            force.copyFromFloats((2 * fetchedColorR - 1) * _this.noiseStrength.x, (2 * fetchedColorG - 1) * _this.noiseStrength.x, (2 * fetchedColorB - 1) * _this.noiseStrength.x);
+                            force.scaleToRef(_this._scaledUpdateSpeed, scaledForce);
                             particle.direction.addInPlace(scaledForce);
                         }
                         _this.gravity.scaleToRef(_this._scaledUpdateSpeed, _this._scaledGravity);

+ 5 - 3
dist/preview release/babylon.no-module.max.js

@@ -55282,8 +55282,10 @@ var BABYLON;
              * automatic start to happen and let you decide when to start emitting particles.
              */
             this.preventAutoStart = false;
+            /** Gets or sets the estimated area used by the system. It will be used to normalize the projection onto the noise texture (default is (1, 1)) */
             this.noiseGridSize = new BABYLON.Vector2(1, 1);
-            this.noiseStrength = 50;
+            /** Gets or sets the strength to apply to the noise value (default is (10, 10, 10)) */
+            this.noiseStrength = new BABYLON.Vector3(10, 10, 10);
             /**
              * Callback triggered when the particle animation is ending.
              */
@@ -55485,8 +55487,8 @@ var BABYLON;
                             var fetchedColorB = BABYLON.Tools.FetchR(particle.position.x / _this.noiseGridSize.x + 0.66, particle.position.y / _this.noiseGridSize.y + 0.33, noiseTextureSize.width, noiseTextureSize.height, noiseTextureData);
                             var force = BABYLON.Tmp.Vector3[0];
                             var scaledForce = BABYLON.Tmp.Vector3[1];
-                            force.copyFromFloats(2 * fetchedColorR - 1, 2 * fetchedColorG - 1, 2 * fetchedColorB - 1);
-                            force.scaleToRef(_this._scaledUpdateSpeed * _this.noiseStrength, scaledForce);
+                            force.copyFromFloats((2 * fetchedColorR - 1) * _this.noiseStrength.x, (2 * fetchedColorG - 1) * _this.noiseStrength.x, (2 * fetchedColorB - 1) * _this.noiseStrength.x);
+                            force.scaleToRef(_this._scaledUpdateSpeed, scaledForce);
                             particle.direction.addInPlace(scaledForce);
                         }
                         _this.gravity.scaleToRef(_this._scaledUpdateSpeed, _this._scaledGravity);

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 4 - 4
dist/preview release/babylon.worker.js


+ 5 - 3
dist/preview release/es6.js

@@ -55282,8 +55282,10 @@ var BABYLON;
              * automatic start to happen and let you decide when to start emitting particles.
              */
             this.preventAutoStart = false;
+            /** Gets or sets the estimated area used by the system. It will be used to normalize the projection onto the noise texture (default is (1, 1)) */
             this.noiseGridSize = new BABYLON.Vector2(1, 1);
-            this.noiseStrength = 50;
+            /** Gets or sets the strength to apply to the noise value (default is (10, 10, 10)) */
+            this.noiseStrength = new BABYLON.Vector3(10, 10, 10);
             /**
              * Callback triggered when the particle animation is ending.
              */
@@ -55485,8 +55487,8 @@ var BABYLON;
                             var fetchedColorB = BABYLON.Tools.FetchR(particle.position.x / _this.noiseGridSize.x + 0.66, particle.position.y / _this.noiseGridSize.y + 0.33, noiseTextureSize.width, noiseTextureSize.height, noiseTextureData);
                             var force = BABYLON.Tmp.Vector3[0];
                             var scaledForce = BABYLON.Tmp.Vector3[1];
-                            force.copyFromFloats(2 * fetchedColorR - 1, 2 * fetchedColorG - 1, 2 * fetchedColorB - 1);
-                            force.scaleToRef(_this._scaledUpdateSpeed * _this.noiseStrength, scaledForce);
+                            force.copyFromFloats((2 * fetchedColorR - 1) * _this.noiseStrength.x, (2 * fetchedColorG - 1) * _this.noiseStrength.x, (2 * fetchedColorB - 1) * _this.noiseStrength.x);
+                            force.scaleToRef(_this._scaledUpdateSpeed, scaledForce);
                             particle.direction.addInPlace(scaledForce);
                         }
                         _this.gravity.scaleToRef(_this._scaledUpdateSpeed, _this._scaledGravity);

+ 1 - 0
dist/preview release/gui/babylon.gui.js

@@ -2149,6 +2149,7 @@ var BABYLON;
             /** @hidden */
             Control.prototype._resetFontCache = function () {
                 this._fontSet = true;
+                this._markAsDirty();
             };
             /**
              * Gets coordinates in local control space

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 4 - 4
dist/preview release/gui/babylon.gui.min.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 53 - 53
dist/preview release/viewer/babylon.viewer.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 2658 - 2299
dist/preview release/viewer/babylon.viewer.max.js


+ 5 - 3
src/Particles/babylon.particleSystem.ts

@@ -161,9 +161,11 @@
          */
         public noiseTexture: Texture;
 
+        /** Gets or sets the estimated area used by the system. It will be used to normalize the projection onto the noise texture (default is (1, 1)) */
         public noiseGridSize = new Vector2(1, 1);
 
-        public noiseStrength = 50;
+        /** Gets or sets the strength to apply to the noise value (default is (10, 10, 10)) */
+        public noiseStrength = new Vector3(10, 10, 10);
 
         /**
          * This function can be defined to provide custom update for active particles.
@@ -595,9 +597,9 @@
                             let force = Tmp.Vector3[0];
                             let scaledForce = Tmp.Vector3[1];
 
-                            force.copyFromFloats(2 * fetchedColorR - 1, 2 * fetchedColorG - 1, 2 * fetchedColorB - 1);
+                            force.copyFromFloats((2 * fetchedColorR - 1) * this.noiseStrength.x, (2 * fetchedColorG - 1) * this.noiseStrength.x, (2 * fetchedColorB - 1) * this.noiseStrength.x);
 
-                            force.scaleToRef(this._scaledUpdateSpeed * this.noiseStrength, scaledForce);
+                            force.scaleToRef(this._scaledUpdateSpeed, scaledForce);
                             particle.direction.addInPlace(scaledForce);
                         }