|
@@ -5477,7 +5477,7 @@ var BABYLON;
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Returns a new Vector3 set from the index "offset" of the given Float32Array
|
|
* Returns a new Vector3 set from the index "offset" of the given Float32Array
|
|
- * This function is deprecated. Use FromArray instead
|
|
|
|
|
|
+ * This function is deprecated. Use FromArray instead
|
|
* @param array defines the source array
|
|
* @param array defines the source array
|
|
* @param offset defines the offset in the source array
|
|
* @param offset defines the offset in the source array
|
|
* @returns the new Vector3
|
|
* @returns the new Vector3
|
|
@@ -13236,24 +13236,6 @@ var BABYLON;
|
|
Engine.prototype.getCaps = function () {
|
|
Engine.prototype.getCaps = function () {
|
|
return this._caps;
|
|
return this._caps;
|
|
};
|
|
};
|
|
- Object.defineProperty(Engine.prototype, "drawCalls", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("drawCalls is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- Object.defineProperty(Engine.prototype, "drawCallsPerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("drawCallsPerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
/**
|
|
/**
|
|
* Gets the current depth function
|
|
* Gets the current depth function
|
|
* @returns a number defining the depth function
|
|
* @returns a number defining the depth function
|
|
@@ -26553,48 +26535,6 @@ var BABYLON;
|
|
enumerable: true,
|
|
enumerable: true,
|
|
configurable: true
|
|
configurable: true
|
|
});
|
|
});
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getInterFramePerfCounter = function () {
|
|
|
|
- BABYLON.Tools.Warn("getInterFramePerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "interFramePerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("interFramePerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getLastFrameDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getLastFrameDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "lastFramePerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("lastFramePerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getEvaluateActiveMeshesDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getEvaluateActiveMeshesDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "evaluateActiveMeshesDurationPerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("evaluateActiveMeshesDurationPerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
/**
|
|
/**
|
|
* Gets the array of active meshes
|
|
* Gets the array of active meshes
|
|
* @returns an array of AbstractMesh
|
|
* @returns an array of AbstractMesh
|
|
@@ -26602,53 +26542,6 @@ var BABYLON;
|
|
Scene.prototype.getActiveMeshes = function () {
|
|
Scene.prototype.getActiveMeshes = function () {
|
|
return this._activeMeshes;
|
|
return this._activeMeshes;
|
|
};
|
|
};
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getRenderTargetsDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getRenderTargetsDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getRenderDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getRenderDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "renderDurationPerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("renderDurationPerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getParticlesDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getParticlesDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "particlesDurationPerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("particlesDurationPerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- /** @hidden */
|
|
|
|
- Scene.prototype.getSpritesDuration = function () {
|
|
|
|
- BABYLON.Tools.Warn("getSpritesDuration is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return 0;
|
|
|
|
- };
|
|
|
|
- Object.defineProperty(Scene.prototype, "spriteDuractionPerfCounter", {
|
|
|
|
- /** @hidden */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("spriteDuractionPerfCounter is deprecated. Please use SceneInstrumentation class");
|
|
|
|
- return null;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
/**
|
|
/**
|
|
* Gets the animation ratio (which is 1.0 is the scene renders at 60fps and 2 if the scene renders at 30fps, etc.)
|
|
* Gets the animation ratio (which is 1.0 is the scene renders at 60fps and 2 if the scene renders at 30fps, etc.)
|
|
* @returns a number
|
|
* @returns a number
|
|
@@ -37295,20 +37188,27 @@ var BABYLON;
|
|
* @param flag defines a flag used to determine which parts of the material have to be marked as dirty
|
|
* @param flag defines a flag used to determine which parts of the material have to be marked as dirty
|
|
*/
|
|
*/
|
|
Material.prototype.markAsDirty = function (flag) {
|
|
Material.prototype.markAsDirty = function (flag) {
|
|
|
|
+ if (this.getScene().blockMaterialDirtyMechanism) {
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ Material._DirtyCallbackArray.length = 0;
|
|
if (flag & Material.TextureDirtyFlag) {
|
|
if (flag & Material.TextureDirtyFlag) {
|
|
- this._markAllSubMeshesAsTexturesDirty();
|
|
|
|
|
|
+ Material._DirtyCallbackArray.push(Material._TextureDirtyCallBack);
|
|
}
|
|
}
|
|
if (flag & Material.LightDirtyFlag) {
|
|
if (flag & Material.LightDirtyFlag) {
|
|
- this._markAllSubMeshesAsLightsDirty();
|
|
|
|
|
|
+ Material._DirtyCallbackArray.push(Material._LightsDirtyCallBack);
|
|
}
|
|
}
|
|
if (flag & Material.FresnelDirtyFlag) {
|
|
if (flag & Material.FresnelDirtyFlag) {
|
|
- this._markAllSubMeshesAsFresnelDirty();
|
|
|
|
|
|
+ Material._DirtyCallbackArray.push(Material._FresnelDirtyCallBack);
|
|
}
|
|
}
|
|
if (flag & Material.AttributesDirtyFlag) {
|
|
if (flag & Material.AttributesDirtyFlag) {
|
|
- this._markAllSubMeshesAsAttributesDirty();
|
|
|
|
|
|
+ Material._DirtyCallbackArray.push(Material._AttributeDirtyCallBack);
|
|
}
|
|
}
|
|
if (flag & Material.MiscDirtyFlag) {
|
|
if (flag & Material.MiscDirtyFlag) {
|
|
- this._markAllSubMeshesAsMiscDirty();
|
|
|
|
|
|
+ Material._DirtyCallbackArray.push(Material._MiscDirtyCallBack);
|
|
|
|
+ }
|
|
|
|
+ if (Material._DirtyCallbackArray.length) {
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._RunDirtyCallBacks);
|
|
}
|
|
}
|
|
this.getScene().resetCachedMaterial();
|
|
this.getScene().resetCachedMaterial();
|
|
};
|
|
};
|
|
@@ -37317,13 +37217,17 @@ var BABYLON;
|
|
* @param func defines a function which checks material defines against the submeshes
|
|
* @param func defines a function which checks material defines against the submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsDirty = function (func) {
|
|
Material.prototype._markAllSubMeshesAsDirty = function (func) {
|
|
- for (var _i = 0, _a = this.getScene().meshes; _i < _a.length; _i++) {
|
|
|
|
- var mesh = _a[_i];
|
|
|
|
|
|
+ if (this.getScene().blockMaterialDirtyMechanism) {
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ var meshes = this.getScene().meshes;
|
|
|
|
+ for (var _i = 0, meshes_1 = meshes; _i < meshes_1.length; _i++) {
|
|
|
|
+ var mesh = meshes_1[_i];
|
|
if (!mesh.subMeshes) {
|
|
if (!mesh.subMeshes) {
|
|
continue;
|
|
continue;
|
|
}
|
|
}
|
|
- for (var _b = 0, _c = mesh.subMeshes; _b < _c.length; _b++) {
|
|
|
|
- var subMesh = _c[_b];
|
|
|
|
|
|
+ for (var _a = 0, _b = mesh.subMeshes; _a < _b.length; _a++) {
|
|
|
|
+ var subMesh = _b[_a];
|
|
if (subMesh.getMaterial() !== this) {
|
|
if (subMesh.getMaterial() !== this) {
|
|
continue;
|
|
continue;
|
|
}
|
|
}
|
|
@@ -37338,55 +37242,49 @@ var BABYLON;
|
|
* Indicates that image processing needs to be re-calculated for all submeshes
|
|
* Indicates that image processing needs to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsImageProcessingDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsImageProcessingDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsImageProcessingDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._ImageProcessingDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that textures need to be re-calculated for all submeshes
|
|
* Indicates that textures need to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsTexturesDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsTexturesDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsTexturesDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._TextureDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that fresnel needs to be re-calculated for all submeshes
|
|
* Indicates that fresnel needs to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsFresnelDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsFresnelDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsFresnelDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._FresnelDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that fresnel and misc need to be re-calculated for all submeshes
|
|
* Indicates that fresnel and misc need to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsFresnelAndMiscDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsFresnelAndMiscDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) {
|
|
|
|
- defines.markAsFresnelDirty();
|
|
|
|
- defines.markAsMiscDirty();
|
|
|
|
- });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._FresnelAndMiscDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that lights need to be re-calculated for all submeshes
|
|
* Indicates that lights need to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsLightsDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsLightsDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsLightDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._LightsDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that attributes need to be re-calculated for all submeshes
|
|
* Indicates that attributes need to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsAttributesDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsAttributesDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsAttributesDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._AttributeDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that misc needs to be re-calculated for all submeshes
|
|
* Indicates that misc needs to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsMiscDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsMiscDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) { return defines.markAsMiscDirty(); });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._MiscDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Indicates that textures and misc need to be re-calculated for all submeshes
|
|
* Indicates that textures and misc need to be re-calculated for all submeshes
|
|
*/
|
|
*/
|
|
Material.prototype._markAllSubMeshesAsTexturesAndMiscDirty = function () {
|
|
Material.prototype._markAllSubMeshesAsTexturesAndMiscDirty = function () {
|
|
- this._markAllSubMeshesAsDirty(function (defines) {
|
|
|
|
- defines.markAsTexturesDirty();
|
|
|
|
- defines.markAsMiscDirty();
|
|
|
|
- });
|
|
|
|
|
|
+ this._markAllSubMeshesAsDirty(Material._TextureAndMiscDirtyCallBack);
|
|
};
|
|
};
|
|
/**
|
|
/**
|
|
* Disposes the material
|
|
* Disposes the material
|
|
@@ -37414,8 +37312,8 @@ var BABYLON;
|
|
}
|
|
}
|
|
else {
|
|
else {
|
|
var meshes = scene.meshes;
|
|
var meshes = scene.meshes;
|
|
- for (var _i = 0, meshes_1 = meshes; _i < meshes_1.length; _i++) {
|
|
|
|
- var mesh = meshes_1[_i];
|
|
|
|
|
|
+ for (var _i = 0, meshes_2 = meshes; _i < meshes_2.length; _i++) {
|
|
|
|
+ var mesh = meshes_2[_i];
|
|
if (mesh.material === this) {
|
|
if (mesh.material === this) {
|
|
mesh.material = null;
|
|
mesh.material = null;
|
|
this.releaseVertexArrayObject(mesh, forceDisposeEffect);
|
|
this.releaseVertexArrayObject(mesh, forceDisposeEffect);
|
|
@@ -37554,6 +37452,27 @@ var BABYLON;
|
|
* The all dirty flag value
|
|
* The all dirty flag value
|
|
*/
|
|
*/
|
|
Material.AllDirtyFlag = 31;
|
|
Material.AllDirtyFlag = 31;
|
|
|
|
+ Material._ImageProcessingDirtyCallBack = function (defines) { return defines.markAsImageProcessingDirty(); };
|
|
|
|
+ Material._TextureDirtyCallBack = function (defines) { return defines.markAsTexturesDirty(); };
|
|
|
|
+ Material._FresnelDirtyCallBack = function (defines) { return defines.markAsFresnelDirty(); };
|
|
|
|
+ Material._MiscDirtyCallBack = function (defines) { return defines.markAsMiscDirty(); };
|
|
|
|
+ Material._LightsDirtyCallBack = function (defines) { return defines.markAsLightDirty(); };
|
|
|
|
+ Material._AttributeDirtyCallBack = function (defines) { return defines.markAsAttributesDirty(); };
|
|
|
|
+ Material._FresnelAndMiscDirtyCallBack = function (defines) {
|
|
|
|
+ Material._FresnelDirtyCallBack(defines);
|
|
|
|
+ Material._MiscDirtyCallBack(defines);
|
|
|
|
+ };
|
|
|
|
+ Material._TextureAndMiscDirtyCallBack = function (defines) {
|
|
|
|
+ Material._TextureDirtyCallBack(defines);
|
|
|
|
+ Material._MiscDirtyCallBack(defines);
|
|
|
|
+ };
|
|
|
|
+ Material._DirtyCallbackArray = [];
|
|
|
|
+ Material._RunDirtyCallBacks = function (defines) {
|
|
|
|
+ for (var _i = 0, _a = Material._DirtyCallbackArray; _i < _a.length; _i++) {
|
|
|
|
+ var cb = _a[_i];
|
|
|
|
+ cb(defines);
|
|
|
|
+ }
|
|
|
|
+ };
|
|
__decorate([
|
|
__decorate([
|
|
BABYLON.serialize()
|
|
BABYLON.serialize()
|
|
], Material.prototype, "id", void 0);
|
|
], Material.prototype, "id", void 0);
|
|
@@ -66902,7 +66821,6 @@ var BABYLON;
|
|
_this._started = false;
|
|
_this._started = false;
|
|
_this._stopped = false;
|
|
_this._stopped = false;
|
|
_this._timeDelta = 0;
|
|
_this._timeDelta = 0;
|
|
- _this._attributesStrideSize = 21;
|
|
|
|
_this._actualFrame = 0;
|
|
_this._actualFrame = 0;
|
|
_this._rawTextureWidth = 256;
|
|
_this._rawTextureWidth = 256;
|
|
/**
|
|
/**
|
|
@@ -67518,6 +67436,8 @@ var BABYLON;
|
|
}
|
|
}
|
|
var engine = this._scene.getEngine();
|
|
var engine = this._scene.getEngine();
|
|
var data = new Array();
|
|
var data = new Array();
|
|
|
|
+ this._attributesStrideSize = 21;
|
|
|
|
+ this._targetIndex = 0;
|
|
if (!this.isBillboardBased) {
|
|
if (!this.isBillboardBased) {
|
|
this._attributesStrideSize += 3;
|
|
this._attributesStrideSize += 3;
|
|
}
|
|
}
|
|
@@ -76609,46 +76529,6 @@ var BABYLON;
|
|
enumerable: true,
|
|
enumerable: true,
|
|
configurable: true
|
|
configurable: true
|
|
});
|
|
});
|
|
- Object.defineProperty(ShadowGenerator.prototype, "useVarianceShadowMap", {
|
|
|
|
- /**
|
|
|
|
- * Gets if the current filter is set to VSM.
|
|
|
|
- * DEPRECATED. Should use useExponentialShadowMap instead.
|
|
|
|
- */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("VSM are now replaced by ESM. Please use useExponentialShadowMap instead.");
|
|
|
|
- return this.useExponentialShadowMap;
|
|
|
|
- },
|
|
|
|
- /**
|
|
|
|
- * Sets the current filter is to VSM.
|
|
|
|
- * DEPRECATED. Should use useExponentialShadowMap instead.
|
|
|
|
- */
|
|
|
|
- set: function (value) {
|
|
|
|
- BABYLON.Tools.Warn("VSM are now replaced by ESM. Please use useExponentialShadowMap instead.");
|
|
|
|
- this.useExponentialShadowMap = value;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
- Object.defineProperty(ShadowGenerator.prototype, "useBlurVarianceShadowMap", {
|
|
|
|
- /**
|
|
|
|
- * Gets if the current filter is set to blurred VSM.
|
|
|
|
- * DEPRECATED. Should use useBlurExponentialShadowMap instead.
|
|
|
|
- */
|
|
|
|
- get: function () {
|
|
|
|
- BABYLON.Tools.Warn("VSM are now replaced by ESM. Please use useBlurExponentialShadowMap instead.");
|
|
|
|
- return this.useBlurExponentialShadowMap;
|
|
|
|
- },
|
|
|
|
- /**
|
|
|
|
- * Sets the current filter is to blurred VSM.
|
|
|
|
- * DEPRECATED. Should use useBlurExponentialShadowMap instead.
|
|
|
|
- */
|
|
|
|
- set: function (value) {
|
|
|
|
- BABYLON.Tools.Warn("VSM are now replaced by ESM. Please use useBlurExponentialShadowMap instead.");
|
|
|
|
- this.useBlurExponentialShadowMap = value;
|
|
|
|
- },
|
|
|
|
- enumerable: true,
|
|
|
|
- configurable: true
|
|
|
|
- });
|
|
|
|
Object.defineProperty(ShadowGenerator.prototype, "useExponentialShadowMap", {
|
|
Object.defineProperty(ShadowGenerator.prototype, "useExponentialShadowMap", {
|
|
/**
|
|
/**
|
|
* Gets if the current filter is set to ESM.
|
|
* Gets if the current filter is set to ESM.
|
|
@@ -109191,7 +109071,7 @@ var BABYLON;
|
|
this._tmpMatrix = new BABYLON.Matrix();
|
|
this._tmpMatrix = new BABYLON.Matrix();
|
|
this._frameObserver = helper._sessionManager.onXRFrameObservable.add(function () {
|
|
this._frameObserver = helper._sessionManager.onXRFrameObservable.add(function () {
|
|
if (!helper._sessionManager._currentXRFrame || !helper._sessionManager._currentXRFrame.getDevicePose) {
|
|
if (!helper._sessionManager._currentXRFrame || !helper._sessionManager._currentXRFrame.getDevicePose) {
|
|
- return false;
|
|
|
|
|
|
+ return;
|
|
}
|
|
}
|
|
var xrFrame = helper._sessionManager._currentXRFrame;
|
|
var xrFrame = helper._sessionManager._currentXRFrame;
|
|
var inputSources = helper._sessionManager._xrSession.getInputSources();
|
|
var inputSources = helper._sessionManager._xrSession.getInputSources();
|