David Catuhe 7 years ago
parent
commit
0b462534ac

File diff suppressed because it is too large
+ 12058 - 12057
Playground/babylon.d.txt


File diff suppressed because it is too large
+ 12062 - 12061
dist/preview release/babylon.d.ts


File diff suppressed because it is too large
+ 4 - 4
dist/preview release/babylon.js


File diff suppressed because it is too large
+ 6 - 4
dist/preview release/babylon.max.js


File diff suppressed because it is too large
+ 6 - 4
dist/preview release/babylon.no-module.max.js


File diff suppressed because it is too large
+ 4 - 4
dist/preview release/babylon.worker.js


File diff suppressed because it is too large
+ 6 - 4
dist/preview release/es6.js


File diff suppressed because it is too large
+ 4 - 4
dist/preview release/viewer/babylon.viewer.js


File diff suppressed because it is too large
+ 6 - 4
dist/preview release/viewer/babylon.viewer.max.js


+ 4 - 2
src/Materials/Textures/babylon.videoTexture.ts

@@ -32,6 +32,7 @@
 
 
         private _generateMipMaps: boolean;
         private _generateMipMaps: boolean;
         private _engine: Engine;
         private _engine: Engine;
+        private _stillImageCaptured = false;
 
 
         /**
         /**
          * Creates a video texture.
          * Creates a video texture.
@@ -141,8 +142,8 @@
             );
             );
 
 
             this._texture.isReady = true;
             this._texture.isReady = true;
-            this._updateInternalTexture();
 
 
+            this._updateInternalTexture();
             if (this._onLoadObservable && this._onLoadObservable.hasObservers()) {
             if (this._onLoadObservable && this._onLoadObservable.hasObservers()) {
                 this.onLoadObservable.notifyObservers(this);
                 this.onLoadObservable.notifyObservers(this);
             }
             }
@@ -183,9 +184,10 @@
             if (!isVisible) {
             if (!isVisible) {
                 return;
                 return;
             }
             }
-            if (this.video.paused) {
+            if (this.video.paused && this._stillImageCaptured) {
                 return;
                 return;
             }
             }
+            this._stillImageCaptured = true;
             this._updateInternalTexture();
             this._updateInternalTexture();
         }
         }