ソースを参照

Merge pull request #3157 from BabylonJS/master

Nightly
David Catuhe 7 年 前
コミット
f0b93a1c64

ファイルの差分が大きいため隠しています
+ 21097 - 15435
Playground/babylon.d.txt


+ 6 - 0
Tools/Gulp/config.json

@@ -6,6 +6,12 @@
         "declarationFilename": "babylon.d.ts",
         "declarationModuleFilename": "babylon.module.d.ts",
         "outputDirectory": "../../dist/preview release",
+        "playgroundDirectory": "../../Playground/",
+        "intellisenseFile": "babylon.d.txt",
+        "intellisenseSources": [
+            "../../dist/preview release/babylon.d.ts",
+            "../../dist/preview release/gui/babylon.gui.d.ts"
+        ],
         "outputCustomConfigurationsDirectory": "../../dist/preview release/customConfigurations",
         "srcOutputDirectory": "../../src/",
         "currentConfig": "all"

+ 14 - 1
Tools/Gulp/gulpfile.js

@@ -415,7 +415,8 @@ var buildExternalLibrary = function (library, settings, watch) {
 /**
  * The default task, concat and min the main BJS files.
  */
-gulp.task("default", ["typescript-all"], function () {
+gulp.task("default", function (cb) {
+    runSequence("typescript-all", "intellisense", cb);
 });
 
 gulp.task("mainBuild", function (cb) {
@@ -500,6 +501,18 @@ gulp.task("watch", [], function () {
     return tasks;
 });
 
+gulp.task("intellisense", function() {
+    gulp.src(config.build.intellisenseSources)
+    .pipe(concat(config.build.intellisenseFile))
+    .pipe(replace(/^\s*_.*?$/gm, ""))
+    .pipe(replace(/^\s*private .*?$/gm, ""))
+    .pipe(replace(/^\s*public _.*?$/gm, ""))
+    .pipe(replace(/^\s*protected .*?$/gm, ""))
+    .pipe(replace(/^\s*public static _.*?$/gm, ""))
+    .pipe(replace(/^\s*static _.*?$/gm, ""))
+    .pipe(gulp.dest(config.build.playgroundDirectory));
+});
+
 /**
  * Embedded local dev env management.
  */

ファイルの差分が大きいため隠しています
+ 3990 - 3991
dist/preview release/babylon.d.ts


ファイルの差分が大きいため隠しています
+ 3 - 3
dist/preview release/babylon.js


+ 1 - 4
dist/preview release/babylon.max.js

@@ -1781,7 +1781,7 @@ var BABYLON;
             matrix.invert();
             var screenSource = MathTmp.Vector3[0];
             screenSource.x = sourceX / viewportWidth * 2 - 1;
-            screenSource.y = sourceY / viewportHeight * 2 - 1;
+            screenSource.y = -(sourceY / viewportHeight * 2 - 1);
             screenSource.z = 2 * sourceZ - 1.0;
             Vector3.TransformCoordinatesToRef(screenSource, matrix, result);
             var num = screenSource.x * matrix.m[3] + screenSource.y * matrix.m[7] + screenSource.z * matrix.m[11] + matrix.m[15];
@@ -17909,7 +17909,6 @@ var BABYLON;
              */
             this.onPointerObservable = new BABYLON.Observable();
             this._meshPickProceed = false;
-            this._previousHasSwiped = false;
             this._currentPickResult = null;
             this._previousPickResult = null;
             this._totalPointersPressed = 0;
@@ -18933,7 +18932,6 @@ var BABYLON;
                                     _this._previousStartingPointerPosition.x = _this._startingPointerPosition.x;
                                     _this._previousStartingPointerPosition.y = _this._startingPointerPosition.y;
                                     _this._previousButtonPressed = btn;
-                                    _this._previousHasSwiped = clickInfo.hasSwiped;
                                     if (Scene.ExclusiveDoubleClickMode) {
                                         if (_this._previousDelayedSimpleClickTimeout) {
                                             clearTimeout(_this._previousDelayedSimpleClickTimeout);
@@ -18952,7 +18950,6 @@ var BABYLON;
                                 _this._previousStartingPointerPosition.x = _this._startingPointerPosition.x;
                                 _this._previousStartingPointerPosition.y = _this._startingPointerPosition.y;
                                 _this._previousButtonPressed = btn;
-                                _this._previousHasSwiped = clickInfo.hasSwiped;
                             }
                         }
                     }

ファイルの差分が大きいため隠しています
+ 3990 - 3991
dist/preview release/babylon.module.d.ts


ファイルの差分が大きいため隠しています
+ 4 - 4
dist/preview release/babylon.worker.js


ファイルの差分が大きいため隠しています
+ 3242 - 3243
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.d.ts


ファイルの差分が大きいため隠しています
+ 3 - 3
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.js


+ 1 - 4
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.max.js

@@ -1781,7 +1781,7 @@ var BABYLON;
             matrix.invert();
             var screenSource = MathTmp.Vector3[0];
             screenSource.x = sourceX / viewportWidth * 2 - 1;
-            screenSource.y = sourceY / viewportHeight * 2 - 1;
+            screenSource.y = -(sourceY / viewportHeight * 2 - 1);
             screenSource.z = 2 * sourceZ - 1.0;
             Vector3.TransformCoordinatesToRef(screenSource, matrix, result);
             var num = screenSource.x * matrix.m[3] + screenSource.y * matrix.m[7] + screenSource.z * matrix.m[11] + matrix.m[15];
@@ -17909,7 +17909,6 @@ var BABYLON;
              */
             this.onPointerObservable = new BABYLON.Observable();
             this._meshPickProceed = false;
-            this._previousHasSwiped = false;
             this._currentPickResult = null;
             this._previousPickResult = null;
             this._totalPointersPressed = 0;
@@ -18933,7 +18932,6 @@ var BABYLON;
                                     _this._previousStartingPointerPosition.x = _this._startingPointerPosition.x;
                                     _this._previousStartingPointerPosition.y = _this._startingPointerPosition.y;
                                     _this._previousButtonPressed = btn;
-                                    _this._previousHasSwiped = clickInfo.hasSwiped;
                                     if (Scene.ExclusiveDoubleClickMode) {
                                         if (_this._previousDelayedSimpleClickTimeout) {
                                             clearTimeout(_this._previousDelayedSimpleClickTimeout);
@@ -18952,7 +18950,6 @@ var BABYLON;
                                 _this._previousStartingPointerPosition.x = _this._startingPointerPosition.x;
                                 _this._previousStartingPointerPosition.y = _this._startingPointerPosition.y;
                                 _this._previousButtonPressed = btn;
-                                _this._previousHasSwiped = clickInfo.hasSwiped;
                             }
                         }
                     }

ファイルの差分が大きいため隠しています
+ 3242 - 3243
dist/preview release/customConfigurations/minimalGLTFViewer/babylon.module.d.ts


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

@@ -212,6 +212,9 @@ var BABYLON;
                 if (this._pointerObserver) {
                     scene.onPointerObservable.remove(this._pointerObserver);
                 }
+                if (this._preKeyboardObserver) {
+                    scene.onPreKeyboardObservable.remove(this._preKeyboardObserver);
+                }
                 if (this._canvasPointerOutObserver) {
                     scene.getEngine().onCanvasPointerOutObservable.remove(this._canvasPointerOutObserver);
                 }

ファイルの差分が大きいため隠しています
+ 3 - 3
dist/preview release/gui/babylon.gui.min.js


+ 2 - 0
dist/preview release/what's new.md

@@ -1,6 +1,8 @@
 # 3.1.0:
 
 ## Major updates
+- Viewer (TODO)
+- EnvironmentHelper + BackgroundMaterial (TODO)
 - Added support for webgl context lost and restored events. [Doc here](http://doc.babylonjs.com/tutorials/optimizing_your_scene#handling-webgl-context-lost) ([deltakosh](https://github.com/deltakosh))
 - Added support for non-pow2 textures when in WebGL2 mode ([deltakosh](https://github.com/deltakosh))
 - Engine can now be initialized with an existing webgl context ([deltakosh](https://github.com/deltakosh))

+ 4 - 0
gui/src/advancedDynamicTexture.ts

@@ -215,6 +215,10 @@ module BABYLON.GUI {
                 scene.onPointerObservable.remove(this._pointerObserver);
             }
 
+            if (this._preKeyboardObserver) {
+                scene.onPreKeyboardObservable.remove(this._preKeyboardObserver);
+            }
+
             if (this._canvasPointerOutObserver) {
                 scene.getEngine().onCanvasPointerOutObservable.remove(this._canvasPointerOutObserver);
             }

+ 1 - 1
src/Math/babylon.math.ts

@@ -1767,7 +1767,7 @@
             matrix.invert();
             var screenSource = MathTmp.Vector3[0];
             screenSource.x = sourceX / viewportWidth * 2 - 1;
-            screenSource.y = sourceY/ viewportHeight * 2 - 1;
+            screenSource.y = -(sourceY/ viewportHeight * 2 - 1);
             screenSource.z = 2 * sourceZ - 1.0;
             Vector3.TransformCoordinatesToRef(screenSource, matrix, result);
             var num = screenSource.x * matrix.m[3] + screenSource.y * matrix.m[7] + screenSource.z * matrix.m[11] + matrix.m[15];

+ 0 - 3
src/babylon.scene.ts

@@ -522,7 +522,6 @@
         private _meshPickProceed = false;
 
         private _previousButtonPressed: number;
-        private _previousHasSwiped = false;
         private _currentPickResult: Nullable<PickingInfo> = null;
         private _previousPickResult: Nullable<PickingInfo> = null;
         private _totalPointersPressed = 0;
@@ -1506,7 +1505,6 @@
                                     this._previousStartingPointerPosition.x = this._startingPointerPosition.x;
                                     this._previousStartingPointerPosition.y = this._startingPointerPosition.y;
                                     this._previousButtonPressed = btn;
-                                    this._previousHasSwiped = clickInfo.hasSwiped;
                                     if (Scene.ExclusiveDoubleClickMode) {
                                         if (this._previousDelayedSimpleClickTimeout) {
                                             clearTimeout(this._previousDelayedSimpleClickTimeout);
@@ -1527,7 +1525,6 @@
                                 this._previousStartingPointerPosition.x = this._startingPointerPosition.x;
                                 this._previousStartingPointerPosition.y = this._startingPointerPosition.y;
                                 this._previousButtonPressed = btn;
-                                this._previousHasSwiped = clickInfo.hasSwiped;
                             }
                         }
                     }