docstring_tokens stringlengths 0 76.5k | code_tokens stringlengths 75 1.81M | label_window listlengths 4 2.12k | html_url stringlengths 74 116 | file_name stringlengths 3 311 |
|---|---|---|---|---|
} else { | <mask> if (bpp == 24) {
<mask> dataLength = width * height * 3;
<mask> byteArray = DDSTools.GetRGBArrayBuffer(width, height, dataOffset, dataLength, arrayBuffer);
<mask> gl.texImage2D(sampler, i, gl.RGB, width, height, 0, gl.RGB, gl.UNSIGNED_BYTE, byteArray);
<mask> }
<mask> else {
<mask> dataLength = width * height * 4;
<mask> byteArray = DDSTools.GetRGBAArrayBuffer(width, height, dataOffset, dataLength, arrayBuffer);
<mask> gl.texImage2D(sampler, i, gl.RGBA, width, height, 0, gl.RGBA, gl.UNSIGNED_BYTE, byteArray);
<mask> }
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (info.isLuminance) {
</s> add } else if (info.isLuminance) { </s> remove }
else {
</s> add } else { </s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
</s> remove }
else if (!isNaN(size)) {
</s> add } else if (!isNaN(size)) {
</s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.dds.js |
} else if (info.isLuminance) { | <mask> dataLength = width * height * 4;
<mask> byteArray = DDSTools.GetRGBAArrayBuffer(width, height, dataOffset, dataLength, arrayBuffer);
<mask> gl.texImage2D(sampler, i, gl.RGBA, width, height, 0, gl.RGBA, gl.UNSIGNED_BYTE, byteArray);
<mask> }
<mask> }
<mask> else if (info.isLuminance) {
<mask> var unpackAlignment = gl.getParameter(gl.UNPACK_ALIGNMENT);
<mask> var unpaddedRowSize = width;
<mask> var paddedRowSize = Math.floor((width + unpackAlignment - 1) / unpackAlignment) * unpackAlignment;
<mask> dataLength = paddedRowSize * (height - 1) + unpaddedRowSize;
<mask> byteArray = DDSTools.GetLuminanceArrayBuffer(width, height, dataOffset, dataLength, arrayBuffer);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.dds.js |
} else { | <mask> var paddedRowSize = Math.floor((width + unpackAlignment - 1) / unpackAlignment) * unpackAlignment;
<mask> dataLength = paddedRowSize * (height - 1) + unpaddedRowSize;
<mask> byteArray = DDSTools.GetLuminanceArrayBuffer(width, height, dataOffset, dataLength, arrayBuffer);
<mask> gl.texImage2D(sampler, i, gl.LUMINANCE, width, height, 0, gl.LUMINANCE, gl.UNSIGNED_BYTE, byteArray);
<mask> }
<mask> else {
<mask> dataLength = Math.max(4, width) / 4 * Math.max(4, height) / 4 * blockBytes;
<mask> byteArray = new Uint8Array(arrayBuffer, dataOffset, dataLength);
<mask> gl.compressedTexImage2D(sampler, i, internalFormat, width, height, 0, byteArray);
<mask> }
<mask> dataOffset += dataLength;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (info.isLuminance) {
</s> add } else if (info.isLuminance) { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.dds.js |
})(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | <mask> };
<mask> return DDSTools;
<mask> })();
<mask> Internals.DDSTools = DDSTools;
<mask> })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.dds.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove //# sourceMappingURL=babylon.tools.dds.js.map </s> add </s> remove //# sourceMappingURL=babylon.tools.tga.js.map </s> add </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.dds.js |
<mask> })();
<mask> Internals.DDSTools = DDSTools;
<mask> })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.dds.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove //# sourceMappingURL=babylon.tools.tga.js.map </s> add </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove //# sourceMappingURL=babylon.babylonFileLoader.js.map </s> add | [
"keep",
"keep",
"keep",
"keep",
"replace"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.dds.js | |
} else if (source.clone) {
| <mask> return null;
<mask> }
<mask> if (source instanceof BABYLON.SubMesh) {
<mask> return source.clone(destinationObject);
<mask> }
<mask> else if (source.clone) {
<mask> return source.clone();
<mask> }
<mask> return null;
<mask> };
<mask> var Tools = (function () {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (this._pausedDelay) {
</s> add } else if (this._pausedDelay) {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove if (samplingMode === void 0) { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (onLoad === void 0) { onLoad = null; }
if (onError === void 0) { onError = null; }
if (buffer === void 0) { buffer = null; }
if (deleteBuffer === void 0) { deleteBuffer = false; }
</s> add if (typeof samplingMode === "undefined") { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (typeof onLoad === "undefined") { onLoad = null; }
if (typeof onError === "undefined") { onError = null; }
if (typeof buffer === "undefined") { buffer = null; }
if (typeof deleteBuffer === "undefined") { deleteBuffer = false; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (document.mozCancelFullScreen) {
| <mask> };
<mask> Tools.ExitFullscreen = function () {
<mask> if (document.exitFullscreen) {
<mask> document.exitFullscreen();
<mask> }
<mask> else if (document.mozCancelFullScreen) {
<mask> document.mozCancelFullScreen();
<mask> }
<mask> else if (document.webkitCancelFullScreen) {
<mask> document.webkitCancelFullScreen();
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (document.webkitCancelFullScreen) {
</s> add } else if (document.webkitCancelFullScreen) {
</s> remove }
else if (document.msCancelFullScreen) {
</s> add } else if (document.msCancelFullScreen) {
</s> remove }
else {
</s> add } else { </s> remove }
else if (window.webkitRequestAnimationFrame) {
</s> add } else if (window.webkitRequestAnimationFrame) { </s> remove }
else if (window.mozRequestAnimationFrame) {
</s> add } else if (window.mozRequestAnimationFrame) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (document.webkitCancelFullScreen) {
| <mask> document.exitFullscreen();
<mask> }
<mask> else if (document.mozCancelFullScreen) {
<mask> document.mozCancelFullScreen();
<mask> }
<mask> else if (document.webkitCancelFullScreen) {
<mask> document.webkitCancelFullScreen();
<mask> }
<mask> else if (document.msCancelFullScreen) {
<mask> document.msCancelFullScreen();
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (document.mozCancelFullScreen) {
</s> add } else if (document.mozCancelFullScreen) {
</s> remove }
else if (document.msCancelFullScreen) {
</s> add } else if (document.msCancelFullScreen) {
</s> remove }
else if (window.webkitRequestAnimationFrame) {
</s> add } else if (window.webkitRequestAnimationFrame) { </s> remove }
else if (geometry instanceof BABYLON.Geometry.Primitives.Ground) {
</s> add } else if (geometry instanceof BABYLON.Geometry.Primitives.Ground) { </s> remove }
else if (geometry instanceof BABYLON.Geometry.Primitives.Plane) {
</s> add } else if (geometry instanceof BABYLON.Geometry.Primitives.Plane) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (document.msCancelFullScreen) {
| <mask> document.mozCancelFullScreen();
<mask> }
<mask> else if (document.webkitCancelFullScreen) {
<mask> document.webkitCancelFullScreen();
<mask> }
<mask> else if (document.msCancelFullScreen) {
<mask> document.msCancelFullScreen();
<mask> }
<mask> };
<mask> // External files
<mask> Tools.CleanUrl = function (url) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (document.webkitCancelFullScreen) {
</s> add } else if (document.webkitCancelFullScreen) {
</s> remove }
else if (document.mozCancelFullScreen) {
</s> add } else if (document.mozCancelFullScreen) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> };
<mask> //ANY database to do!
<mask> if (database && database.enableTexturesOffline && BABYLON.Database.isUASupportingBlobStorage) {
<mask> database.openAsync(loadFromIndexedDB, noIndexedDB);
<mask> }
<mask> else {
<mask> if (url.indexOf("file:") === -1) {
<mask> noIndexedDB();
<mask> }
<mask> else {
<mask> try {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
try {
| <mask> }
<mask> else {
<mask> if (url.indexOf("file:") === -1) {
<mask> noIndexedDB();
<mask> }
<mask> else {
<mask> try {
<mask> var textureName = url.substring(5);
<mask> var blobURL;
<mask> try {
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName], { oneTimeOnly: true });
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove try {
</s> add try {
</s> remove }
catch (ex) {
</s> add } catch (ex) {
</s> remove }
else {
</s> add } else {
</s> remove try {
</s> add try { </s> remove }
catch (ex) {
</s> add } catch (ex) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
try {
| <mask> else {
<mask> try {
<mask> var textureName = url.substring(5);
<mask> var blobURL;
<mask> try {
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName], { oneTimeOnly: true });
<mask> }
<mask> catch (ex) {
<mask> // Chrome doesn't support oneTimeOnly parameter
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName]);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
catch (ex) {
</s> add } catch (ex) {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
catch (e) {
</s> add } catch (e) {
</s> remove try {
</s> add try { </s> remove }
catch (ex) {
</s> add } catch (ex) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} catch (ex) {
| <mask> var textureName = url.substring(5);
<mask> var blobURL;
<mask> try {
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName], { oneTimeOnly: true });
<mask> }
<mask> catch (ex) {
<mask> // Chrome doesn't support oneTimeOnly parameter
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName]);
<mask> }
<mask> img.src = blobURL;
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove try {
</s> add try {
</s> remove }
catch (e) {
</s> add } catch (e) {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove try {
</s> add try { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} catch (e) {
| <mask> // Chrome doesn't support oneTimeOnly parameter
<mask> blobURL = URL.createObjectURL(BABYLON.FilesInput.FilesTextures[textureName]);
<mask> }
<mask> img.src = blobURL;
<mask> }
<mask> catch (e) {
<mask> Tools.Log("Error while trying to load texture: " + textureName);
<mask> img.src = null;
<mask> }
<mask> }
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
catch (ex) {
</s> add } catch (ex) {
</s> remove try {
</s> add try {
</s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove }
catch (e) {
</s> add } catch (e) { </s> remove }
catch (ex) {
</s> add } catch (ex) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> request.onreadystatechange = function () {
<mask> if (request.readyState == 4) {
<mask> if (request.status == 200 || BABYLON.Tools.ValidateXHRData(request, !useArrayBuffer ? 1 : 6)) {
<mask> callback(!useArrayBuffer ? request.responseText : request.response);
<mask> }
<mask> else {
<mask> if (onError) {
<mask> onError();
<mask> }
<mask> else {
<mask> throw new Error("Error status: " + request.status + " - Unable to load " + loadUrl);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove try {
</s> add try { </s> remove }
else {
</s> add } else { </s> remove var padStr = function (i) { return (i < 10) ? "0" + i : "" + i; };
</s> add var padStr = function (i) {
return (i < 10) ? "0" + i : "" + i;
};
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> }
<mask> else {
<mask> if (onError) {
<mask> onError();
<mask> }
<mask> else {
<mask> throw new Error("Error status: " + request.status + " - Unable to load " + loadUrl);
<mask> }
<mask> }
<mask> }
<mask> };
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
</s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> };
<mask> if (url.indexOf("file:") !== -1) {
<mask> var fileName = url.substring(5);
<mask> BABYLON.Tools.ReadFile(BABYLON.FilesInput.FilesToLoad[fileName], callback, progressCallBack, true);
<mask> }
<mask> else {
<mask> // Caching all files
<mask> if (database && database.enableSceneOffline) {
<mask> database.openAsync(loadFromIndexedDB, noIndexedDB);
<mask> }
<mask> else {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> else {
<mask> // Caching all files
<mask> if (database && database.enableSceneOffline) {
<mask> database.openAsync(loadFromIndexedDB, noIndexedDB);
<mask> }
<mask> else {
<mask> noIndexedDB();
<mask> }
<mask> }
<mask> };
<mask> Tools.ReadFileAsDataURL = function (fileToLoad, callback, progressCallback) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else if (document.msCancelFullScreen) {
</s> add } else if (document.msCancelFullScreen) {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> reader.onprogress = progressCallBack;
<mask> if (!useArrayBuffer) {
<mask> // Asynchronous read
<mask> reader.readAsText(fileToLoad);
<mask> }
<mask> else {
<mask> reader.readAsArrayBuffer(fileToLoad);
<mask> }
<mask> };
<mask> // Misc.
<mask> Tools.Clamp = function (value, min, max) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Misc.
</s> add
// Misc.
</s> remove if (min === void 0) { min = 0; }
if (max === void 0) { max = 1; }
</s> add if (typeof min === "undefined") { min = 0; }
if (typeof max === "undefined") { max = 1; }
</s> remove } while (count < value);
</s> add } while(count < value);
</s> remove if (decimals === void 0) { decimals = 2; }
</s> add if (typeof decimals === "undefined") { decimals = 2; }
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
// Misc.
| <mask> else {
<mask> reader.readAsArrayBuffer(fileToLoad);
<mask> }
<mask> };
<mask> // Misc.
<mask> Tools.Clamp = function (value, min, max) {
<mask> if (min === void 0) { min = 0; }
<mask> if (max === void 0) { max = 1; }
<mask> return Math.min(max, Math.max(min, value));
<mask> };
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (min === void 0) { min = 0; }
if (max === void 0) { max = 1; }
</s> add if (typeof min === "undefined") { min = 0; }
if (typeof max === "undefined") { max = 1; }
</s> remove }
else {
</s> add } else {
</s> remove if (x1 === void 0) { x1 = 0; }
if (y1 === void 0) { y1 = 0; }
if (x2 === void 0) { x2 = 1; }
if (y2 === void 0) { y2 = 1; }
</s> add if (typeof x1 === "undefined") { x1 = 0; }
if (typeof y1 === "undefined") { y1 = 0; }
if (typeof x2 === "undefined") { x2 = 1; }
if (typeof y2 === "undefined") { y2 = 1; } </s> remove if (decimals === void 0) { decimals = 2; }
</s> add if (typeof decimals === "undefined") { decimals = 2; }
</s> remove if (maxCapacity === void 0) { maxCapacity = 64; }
if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxCapacity === "undefined") { maxCapacity = 64; }
if (typeof maxDepth === "undefined") { maxDepth = 2; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof min === "undefined") { min = 0; }
if (typeof max === "undefined") { max = 1; }
| <mask> }
<mask> };
<mask> // Misc.
<mask> Tools.Clamp = function (value, min, max) {
<mask> if (min === void 0) { min = 0; }
<mask> if (max === void 0) { max = 1; }
<mask> return Math.min(max, Math.max(min, value));
<mask> };
<mask> // Returns -1 when value is a negative number and
<mask> // +1 when value is a positive number.
<mask> Tools.Sign = function (value) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Misc.
</s> add
// Misc.
</s> remove }
else {
</s> add } else {
</s> remove if (decimals === void 0) { decimals = 2; }
</s> add if (typeof decimals === "undefined") { decimals = 2; }
</s> remove if (x1 === void 0) { x1 = 0; }
if (y1 === void 0) { y1 = 0; }
if (x2 === void 0) { x2 = 1; }
if (y2 === void 0) { y2 = 1; }
</s> add if (typeof x1 === "undefined") { x1 = 0; }
if (typeof y1 === "undefined") { y1 = 0; }
if (typeof x2 === "undefined") { x2 = 1; }
if (typeof y2 === "undefined") { y2 = 1; } </s> remove if (maxCapacity === void 0) { maxCapacity = 64; }
if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxCapacity === "undefined") { maxCapacity = 64; }
if (typeof maxDepth === "undefined") { maxDepth = 2; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof decimals === "undefined") { decimals = 2; }
| <mask> return value;
<mask> return value > 0 ? 1 : -1;
<mask> };
<mask> Tools.Format = function (value, decimals) {
<mask> if (decimals === void 0) { decimals = 2; }
<mask> return value.toFixed(decimals);
<mask> };
<mask> Tools.CheckExtends = function (v, min, max) {
<mask> if (v.x < min.x)
<mask> min.x = v.x;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Misc.
</s> add
// Misc.
</s> remove if (min === void 0) { min = 0; }
if (max === void 0) { max = 1; }
</s> add if (typeof min === "undefined") { min = 0; }
if (typeof max === "undefined") { max = 1; }
</s> remove } while (count < value);
</s> add } while(count < value);
</s> remove }
else {
</s> add } else {
</s> remove if (insertAt === void 0) { insertAt = null; }
</s> add if (typeof insertAt === "undefined") { insertAt = null; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof epsilon === "undefined") { epsilon = 1.401298E-45; }
| <mask> if (v.z > max.z)
<mask> max.z = v.z;
<mask> };
<mask> Tools.WithinEpsilon = function (a, b, epsilon) {
<mask> if (epsilon === void 0) { epsilon = 1.401298E-45; }
<mask> var num = a - b;
<mask> return -epsilon <= num && num <= epsilon;
<mask> };
<mask> Tools.DeepCopy = function (source, destination, doNotCopyList, mustCopyList) {
<mask> for (var prop in source) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (amplitude === void 0) { amplitude = 1; }
</s> add if (typeof amplitude === "undefined") { amplitude = 1; } </s> remove if (exponent === void 0) { exponent = 2; }
</s> add if (typeof exponent === "undefined") { exponent = 2; } </s> remove }
else {
</s> add } else { </s> remove if (insertAt === void 0) { insertAt = null; }
</s> add if (typeof insertAt === "undefined") { insertAt = null; }
</s> remove if (atIndices === void 0) { atIndices = null; }
</s> add if (typeof atIndices === "undefined") { atIndices = null; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> if (destination[prop].indexOf(clonedValue) === -1) {
<mask> destination[prop].push(clonedValue);
<mask> }
<mask> }
<mask> }
<mask> else {
<mask> destination[prop] = sourceValue.slice(0);
<mask> }
<mask> }
<mask> }
<mask> else {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> else {
<mask> destination[prop] = sourceValue.slice(0);
<mask> }
<mask> }
<mask> }
<mask> else {
<mask> destination[prop] = cloneValue(sourceValue, destination);
<mask> }
<mask> }
<mask> else {
<mask> destination[prop] = sourceValue;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> add } else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> }
<mask> else {
<mask> destination[prop] = cloneValue(sourceValue, destination);
<mask> }
<mask> }
<mask> else {
<mask> destination[prop] = sourceValue;
<mask> }
<mask> }
<mask> };
<mask> Tools.IsEmpty = function (obj) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
try {
| <mask> Tools.RegisterTopRootEvents = function (events) {
<mask> for (var index = 0; index < events.length; index++) {
<mask> var event = events[index];
<mask> window.addEventListener(event.name, event.handler, false);
<mask> try {
<mask> if (window.parent) {
<mask> window.parent.addEventListener(event.name, event.handler, false);
<mask> }
<mask> }
<mask> catch (e) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
catch (e) {
</s> add } catch (e) {
// Silently fails...
</s> remove try {
</s> add
try {
</s> remove }
else if (texture instanceof BABYLON.RenderTargetTexture) {
</s> add } else if (texture instanceof BABYLON.RenderTargetTexture) { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} catch (e) {
// Silently fails...
| <mask> try {
<mask> if (window.parent) {
<mask> window.parent.addEventListener(event.name, event.handler, false);
<mask> }
<mask> }
<mask> catch (e) {
<mask> }
<mask> }
<mask> };
<mask> Tools.UnregisterTopRootEvents = function (events) {
<mask> for (var index = 0; index < events.length; index++) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove try {
</s> add
try {
</s> remove try {
</s> add
try {
</s> remove }
else {
</s> add } else { </s> remove }
else if (texture instanceof BABYLON.RenderTargetTexture) {
</s> add } else if (texture instanceof BABYLON.RenderTargetTexture) { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
try {
| <mask> Tools.UnregisterTopRootEvents = function (events) {
<mask> for (var index = 0; index < events.length; index++) {
<mask> var event = events[index];
<mask> window.removeEventListener(event.name, event.handler);
<mask> try {
<mask> if (window.parent) {
<mask> window.parent.removeEventListener(event.name, event.handler);
<mask> }
<mask> }
<mask> catch (e) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove try {
</s> add
try {
</s> remove }
catch (e) {
</s> add } catch (e) {
// Silently fails...
</s> remove }
catch (e) {
</s> add } catch (e) {
// Silently fails...
</s> remove }
else if (texture instanceof BABYLON.RenderTargetTexture) {
</s> add } else if (texture instanceof BABYLON.RenderTargetTexture) { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} catch (e) {
// Silently fails...
| <mask> try {
<mask> if (window.parent) {
<mask> window.parent.removeEventListener(event.name, event.handler);
<mask> }
<mask> }
<mask> catch (e) {
<mask> }
<mask> }
<mask> };
<mask> Tools.CreateScreenshot = function (engine, camera, size) {
<mask> var width;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove try {
</s> add
try {
</s> remove }
catch (e) {
</s> add } catch (e) {
// Silently fails...
</s> remove try {
</s> add
try {
</s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove }
catch (ex) {
</s> add } catch (ex) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (size.width && size.height) {
| <mask> if (size.precision) {
<mask> width = Math.round(engine.getRenderWidth() * size.precision);
<mask> height = Math.round(width / engine.getAspectRatio(camera));
<mask> size = { width: width, height: height };
<mask> }
<mask> else if (size.width && size.height) {
<mask> width = size.width;
<mask> height = size.height;
<mask> }
<mask> else if (size.width && !size.height) {
<mask> width = size.width;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
</s> remove }
else if (!isNaN(size)) {
</s> add } else if (!isNaN(size)) {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (size.width && !size.height) {
| <mask> }
<mask> else if (size.width && size.height) {
<mask> width = size.width;
<mask> height = size.height;
<mask> }
<mask> else if (size.width && !size.height) {
<mask> width = size.width;
<mask> height = Math.round(width / engine.getAspectRatio(camera));
<mask> size = { width: width, height: height };
<mask> }
<mask> else if (size.height && !size.width) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
</s> remove }
else if (!isNaN(size)) {
</s> add } else if (!isNaN(size)) {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (size.height && !size.width) {
| <mask> else if (size.width && !size.height) {
<mask> width = size.width;
<mask> height = Math.round(width / engine.getAspectRatio(camera));
<mask> size = { width: width, height: height };
<mask> }
<mask> else if (size.height && !size.width) {
<mask> height = size.height;
<mask> width = Math.round(height * engine.getAspectRatio(camera));
<mask> size = { width: width, height: height };
<mask> }
<mask> else if (!isNaN(size)) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove }
else if (!isNaN(size)) {
</s> add } else if (!isNaN(size)) {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (!isNaN(size)) {
| <mask> else if (size.height && !size.width) {
<mask> height = size.height;
<mask> width = Math.round(height * engine.getAspectRatio(camera));
<mask> size = { width: width, height: height };
<mask> }
<mask> else if (!isNaN(size)) {
<mask> height = size;
<mask> width = size;
<mask> }
<mask> else {
<mask> Tools.Error("Invalid 'size' parameter !");
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> }
<mask> else if (!isNaN(size)) {
<mask> height = size;
<mask> width = size;
<mask> }
<mask> else {
<mask> Tools.Error("Invalid 'size' parameter !");
<mask> return;
<mask> }
<mask> //At this point size can be a number, or an object (according to engine.prototype.createRenderTargetTexture method)
<mask> var texture = new BABYLON.RenderTargetTexture("screenShot", size, scene, false, false);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (!isNaN(size)) {
</s> add } else if (!isNaN(size)) {
</s> remove }
else if (size.height && !size.width) {
</s> add } else if (size.height && !size.width) {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
//Or opening a new tab with the image if it is not possible to automatically start download.
} else {
| <mask> a.addEventListener("click", function () {
<mask> a.parentElement.removeChild(a);
<mask> });
<mask> a.click();
<mask> }
<mask> else {
<mask> var newWindow = window.open("");
<mask> var img = newWindow.document.createElement("img");
<mask> img.src = base64Image;
<mask> newWindow.document.body.appendChild(img);
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
catch (ex) {
</s> add } catch (ex) {
</s> remove try {
</s> add try { </s> remove }
else {
</s> add } else {
</s> remove }
else {
try {
</s> add } else {
try {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof dataType === "undefined") { dataType = 7; }
try {
| <mask> }
<mask> };
<mask> // XHR response validator for local file scenario
<mask> Tools.ValidateXHRData = function (xhr, dataType) {
<mask> // 1 for text (.babylon, manifest and shaders), 2 for TGA, 4 for DDS, 7 for all
<mask> if (dataType === void 0) { dataType = 7; }
<mask> try {
<mask> if (dataType & 1) {
<mask> if (xhr.responseText && xhr.responseText.length > 0) {
<mask> return true;
<mask> }
<mask> else if (dataType === 1) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (dataType === 1) {
</s> add } else if (dataType === 1) {
</s> remove }
else if (dataType === 2) {
</s> add } else if (dataType === 2) {
</s> remove }
else {
</s> add } else { </s> remove }
else if (from instanceof BABYLON.Color3) {
</s> add } else if (from instanceof BABYLON.Color3) {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (dataType === 1) {
| <mask> try {
<mask> if (dataType & 1) {
<mask> if (xhr.responseText && xhr.responseText.length > 0) {
<mask> return true;
<mask> }
<mask> else if (dataType === 1) {
<mask> return false;
<mask> }
<mask> }
<mask> if (dataType & 2) {
<mask> // Check header width and height since there is no "TGA" magic number
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (dataType === 2) {
</s> add } else if (dataType === 2) {
</s> remove // 1 for text (.babylon, manifest and shaders), 2 for TGA, 4 for DDS, 7 for all
if (dataType === void 0) { dataType = 7; }
try {
</s> add if (typeof dataType === "undefined") { dataType = 7; }
try {
</s> remove }
else {
</s> add } else {
</s> remove }
else if (from instanceof BABYLON.Color3) {
</s> add } else if (from instanceof BABYLON.Color3) {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else if (dataType === 2) {
| <mask> // Check header width and height since there is no "TGA" magic number
<mask> var tgaHeader = BABYLON.Internals.TGATools.GetTGAHeader(xhr.response);
<mask> if (tgaHeader.width && tgaHeader.height && tgaHeader.width > 0 && tgaHeader.height > 0) {
<mask> return true;
<mask> }
<mask> else if (dataType === 2) {
<mask> return false;
<mask> }
<mask> }
<mask> if (dataType & 4) {
<mask> // Check for the "DDS" magic number
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (dataType === 1) {
</s> add } else if (dataType === 1) {
</s> remove }
else {
</s> add } else {
</s> remove // 1 for text (.babylon, manifest and shaders), 2 for TGA, 4 for DDS, 7 for all
if (dataType === void 0) { dataType = 7; }
try {
</s> add if (typeof dataType === "undefined") { dataType = 7; }
try {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> // Check for the "DDS" magic number
<mask> var ddsHeader = new Uint8Array(xhr.response, 0, 3);
<mask> if (ddsHeader[0] == 68 && ddsHeader[1] == 68 && ddsHeader[2] == 83) {
<mask> return true;
<mask> }
<mask> else {
<mask> return false;
<mask> }
<mask> }
<mask> }
<mask> catch (e) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (dataType === 2) {
</s> add } else if (dataType === 2) {
</s> remove }
else if (dataType === 1) {
</s> add } else if (dataType === 1) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} catch (e) {
// Global protection
| <mask> return false;
<mask> }
<mask> }
<mask> }
<mask>
<mask> return false;
<mask> };
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove catch (e) {
}
</s> add
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
<mask> return false;
<mask> }
<mask> }
<mask> }
<mask> catch (e) {
<mask> }
<mask> return false;
<mask> };
<mask> Object.defineProperty(Tools, "NoneLogLevel", {
<mask> get: function () {
<mask> return Tools._NoneLogLevel;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
catch (e) {
</s> add } catch (e) { </s> remove }
catch (e) {
</s> add } catch (e) {
// Silently fails...
</s> remove }
catch (e) {
</s> add } catch (e) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js | |
var padStr = function (i) {
return (i < 10) ? "0" + i : "" + i;
};
| <mask> Tools.OnNewCacheEntry(entry);
<mask> }
<mask> };
<mask> Tools._FormatMessage = function (message) {
<mask> var padStr = function (i) { return (i < 10) ? "0" + i : "" + i; };
<mask> var date = new Date();
<mask> return "[" + padStr(date.getHours()) + ":" + padStr(date.getMinutes()) + ":" + padStr(date.getSeconds()) + "]: " + message;
<mask> };
<mask> Tools._LogDisabled = function (message) {
<mask> // nothing to do
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> Object.defineProperty(Tools, "LogLevels", {
<mask> set: function (level) {
<mask> if ((level & Tools.MessageLogLevel) === Tools.MessageLogLevel) {
<mask> Tools.Log = Tools._LogEnabled;
<mask> }
<mask> else {
<mask> Tools.Log = Tools._LogDisabled;
<mask> }
<mask> if ((level & Tools.WarningLogLevel) === Tools.WarningLogLevel) {
<mask> Tools.Warn = Tools._WarnEnabled;
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> add } else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> Tools.Log = Tools._LogDisabled;
<mask> }
<mask> if ((level & Tools.WarningLogLevel) === Tools.WarningLogLevel) {
<mask> Tools.Warn = Tools._WarnEnabled;
<mask> }
<mask> else {
<mask> Tools.Warn = Tools._WarnDisabled;
<mask> }
<mask> if ((level & Tools.ErrorLogLevel) === Tools.ErrorLogLevel) {
<mask> Tools.Error = Tools._ErrorEnabled;
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove // Performances
</s> add
</s> remove }
else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> add } else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> Tools.Warn = Tools._WarnDisabled;
<mask> }
<mask> if ((level & Tools.ErrorLogLevel) === Tools.ErrorLogLevel) {
<mask> Tools.Error = Tools._ErrorEnabled;
<mask> }
<mask> else {
<mask> Tools.Error = Tools._ErrorDisabled;
<mask> }
<mask> },
<mask> enumerable: true,
<mask> configurable: true
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove // Statics
</s> add </s> remove // Performances
</s> add
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof condition === "undefined") { condition = true; }
| <mask> };
<mask> Tools._EndPerformanceCounterDisabled = function (counterName, condition) {
<mask> };
<mask> Tools._StartUserMark = function (counterName, condition) {
<mask> if (condition === void 0) { condition = true; }
<mask> if (!condition || !Tools._performance.mark) {
<mask> return;
<mask> }
<mask> Tools._performance.mark(counterName + "-Begin");
<mask> };
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (triggerOptions === void 0) { triggerOptions = BABYLON.ActionManager.NothingTrigger; }
</s> add if (typeof triggerOptions === "undefined") { triggerOptions = BABYLON.ActionManager.NothingTrigger; } </s> remove if (showUI === void 0) { showUI = true; }
</s> add if (typeof showUI === "undefined") { showUI = true; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof condition === "undefined") { condition = true; }
| <mask> }
<mask> Tools._performance.mark(counterName + "-Begin");
<mask> };
<mask> Tools._EndUserMark = function (counterName, condition) {
<mask> if (condition === void 0) { condition = true; }
<mask> if (!condition || !Tools._performance.mark) {
<mask> return;
<mask> }
<mask> Tools._performance.mark(counterName + "-End");
<mask> Tools._performance.measure(counterName, counterName + "-Begin", counterName + "-End");
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove }
else {
</s> add } else { </s> remove }
else if (this.value instanceof BABYLON.Quaternion) {
</s> add } else if (this.value instanceof BABYLON.Quaternion) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof condition === "undefined") { condition = true; }
| <mask> Tools._performance.mark(counterName + "-End");
<mask> Tools._performance.measure(counterName, counterName + "-Begin", counterName + "-End");
<mask> };
<mask> Tools._StartPerformanceConsole = function (counterName, condition) {
<mask> if (condition === void 0) { condition = true; }
<mask> if (!condition) {
<mask> return;
<mask> }
<mask> Tools._StartUserMark(counterName, condition);
<mask> if (console.time) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (triggerOptions === void 0) { triggerOptions = BABYLON.ActionManager.NothingTrigger; }
</s> add if (typeof triggerOptions === "undefined") { triggerOptions = BABYLON.ActionManager.NothingTrigger; } </s> remove if (showUI === void 0) { showUI = true; }
</s> add if (typeof showUI === "undefined") { showUI = true; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof condition === "undefined") { condition = true; }
| <mask> console.time(counterName);
<mask> }
<mask> };
<mask> Tools._EndPerformanceConsole = function (counterName, condition) {
<mask> if (condition === void 0) { condition = true; }
<mask> if (!condition) {
<mask> return;
<mask> }
<mask> Tools._EndUserMark(counterName, condition);
<mask> if (console.time) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
</s> remove if (triggerOptions === void 0) { triggerOptions = BABYLON.ActionManager.NothingTrigger; }
</s> add if (typeof triggerOptions === "undefined") { triggerOptions = BABYLON.ActionManager.NothingTrigger; } </s> remove if (showUI === void 0) { showUI = true; }
</s> add if (typeof showUI === "undefined") { showUI = true; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} while(count < value);
| <mask> Tools.GetExponantOfTwo = function (value, max) {
<mask> var count = 1;
<mask> do {
<mask> count *= 2;
<mask> } while (count < value);
<mask> if (count > max)
<mask> count = max;
<mask> return count;
<mask> };
<mask> // Logs
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Logs
</s> add
</s> remove }
else {
</s> add } else { </s> remove if (decimals === void 0) { decimals = 2; }
</s> add if (typeof decimals === "undefined") { decimals = 2; }
</s> remove // Misc.
</s> add
// Misc.
</s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
<mask> if (count > max)
<mask> count = max;
<mask> return count;
<mask> };
<mask> // Logs
<mask> Tools._NoneLogLevel = 0;
<mask> Tools._MessageLogLevel = 1;
<mask> Tools._WarningLogLevel = 2;
<mask> Tools._ErrorLogLevel = 4;
<mask> Tools._LogCache = "";
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove } while (count < value);
</s> add } while(count < value);
</s> remove // Performances
</s> add
</s> remove // Statics
</s> add </s> remove // Statics
</s> add </s> remove // Statics
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js | |
<mask> Tools._LogCache = "";
<mask> Tools.Log = Tools._LogEnabled;
<mask> Tools.Warn = Tools._WarnEnabled;
<mask> Tools.Error = Tools._ErrorEnabled;
<mask> // Performances
<mask> Tools._PerformanceNoneLogLevel = 0;
<mask> Tools._PerformanceUserMarkLogLevel = 1;
<mask> Tools._PerformanceConsoleLogLevel = 2;
<mask> Tools._performance = window.performance;
<mask> Tools.StartPerformanceCounter = Tools._StartPerformanceCounterDisabled;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove // Logs
</s> add
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove // Statics
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js | |
* An implementation of a loop for asynchronous functions.
*/
| <mask> return Tools;
<mask> })();
<mask> BABYLON.Tools = Tools;
<mask> /**
<mask> * An implementation of a loop for asynchronous functions.
<mask> */
<mask> var AsyncLoop = (function () {
<mask> /**
<mask> * Constroctor.
<mask> * @param iterations the number of iterations.
<mask> * @param _fn the function to run each iteration
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> add * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> remove * Break the loop and run the success callback.
*/
</s> add * Break the loop and run the success callback.
*/
</s> remove * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> add * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> remove * Helper function
*/
</s> add * Helper function
*/
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
* Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
| <mask> * An implementation of a loop for asynchronous functions.
<mask> */
<mask> var AsyncLoop = (function () {
<mask> /**
<mask> * Constroctor.
<mask> * @param iterations the number of iterations.
<mask> * @param _fn the function to run each iteration
<mask> * @param _successCallback the callback that will be called upon succesful execution
<mask> * @param offset starting offset.
<mask> */
<mask> function AsyncLoop(iterations, _fn, _successCallback, offset) {
<mask> if (offset === void 0) { offset = 0; }
<mask> this.iterations = iterations;
<mask> this._fn = _fn;
<mask> this._successCallback = _successCallback;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * An implementation of a loop for asynchronous functions.
*/
</s> add * An implementation of a loop for asynchronous functions.
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> add * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> remove * Helper function
*/
</s> add * Helper function
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof offset === "undefined") { offset = 0; }
| <mask> * @param _successCallback the callback that will be called upon succesful execution
<mask> * @param offset starting offset.
<mask> */
<mask> function AsyncLoop(iterations, _fn, _successCallback, offset) {
<mask> if (offset === void 0) { offset = 0; }
<mask> this.iterations = iterations;
<mask> this._fn = _fn;
<mask> this._successCallback = _successCallback;
<mask> this.index = offset - 1;
<mask> this._done = false;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Helper function
*/
</s> add * Helper function
*/
</s> remove * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> add * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> remove * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> add * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
* Execute the next iteration. Must be called after the last iteration was finished.
*/
| <mask> this.index = offset - 1;
<mask> this._done = false;
<mask> }
<mask> /**
<mask> * Execute the next iteration. Must be called after the last iteration was finished.
<mask> */
<mask> AsyncLoop.prototype.executeNext = function () {
<mask> if (!this._done) {
<mask> if (this.index + 1 < this.iterations) {
<mask> ++this.index;
<mask> this._fn(this);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove * Break the loop and run the success callback.
*/
</s> add * Break the loop and run the success callback.
*/
</s> remove * Helper function
*/
</s> add * Helper function
*/
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
} else {
| <mask> if (!this._done) {
<mask> if (this.index + 1 < this.iterations) {
<mask> ++this.index;
<mask> this._fn(this);
<mask> }
<mask> else {
<mask> this.breakLoop();
<mask> }
<mask> }
<mask> };
<mask> /**
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> add * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> remove }
else {
</s> add } else {
</s> remove }
else if (this._positionY > globalViewport.y + globalViewport.height - this.borderLimit) {
</s> add } else if (this._positionY > globalViewport.y + globalViewport.height - this.borderLimit) { </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
* Break the loop and run the success callback.
*/
| <mask> }
<mask> }
<mask> };
<mask> /**
<mask> * Break the loop and run the success callback.
<mask> */
<mask> AsyncLoop.prototype.breakLoop = function () {
<mask> this._done = true;
<mask> this._successCallback();
<mask> };
<mask> /**
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Helper function
*/
</s> add * Helper function
*/
</s> remove * An implementation of a loop for asynchronous functions.
*/
</s> add * An implementation of a loop for asynchronous functions.
*/
</s> remove * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> add * Execute the next iteration. Must be called after the last iteration was finished.
*/
</s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
* Helper function
*/
| <mask> this._done = true;
<mask> this._successCallback();
<mask> };
<mask> /**
<mask> * Helper function
<mask> */
<mask> AsyncLoop.Run = function (iterations, _fn, _successCallback, offset) {
<mask> if (offset === void 0) { offset = 0; }
<mask> var loop = new AsyncLoop(iterations, _fn, _successCallback, offset);
<mask> loop.executeNext();
<mask> return loop;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove * Break the loop and run the success callback.
*/
</s> add * Break the loop and run the success callback.
*/
</s> remove if (cx === void 0) { cx = 0; }
if (cy === void 0) { cy = 0; }
if (numberOfSides === void 0) { numberOfSides = 32; }
</s> add if (typeof cx === "undefined") { cx = 0; }
if (typeof cy === "undefined") { cy = 0; }
if (typeof numberOfSides === "undefined") { numberOfSides = 32; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof offset === "undefined") { offset = 0; }
| <mask> /**
<mask> * Helper function
<mask> */
<mask> AsyncLoop.Run = function (iterations, _fn, _successCallback, offset) {
<mask> if (offset === void 0) { offset = 0; }
<mask> var loop = new AsyncLoop(iterations, _fn, _successCallback, offset);
<mask> loop.executeNext();
<mask> return loop;
<mask> };
<mask> /**
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Helper function
*/
</s> add * Helper function
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove * Break the loop and run the success callback.
*/
</s> add * Break the loop and run the success callback.
*/
</s> remove * An implementation of a loop for asynchronous functions.
*/
</s> add * An implementation of a loop for asynchronous functions.
*/
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
* A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
| <mask> loop.executeNext();
<mask> return loop;
<mask> };
<mask> /**
<mask> * A for-loop that will run a given number of iterations synchronous and the rest async.
<mask> * @param iterations total number of iterations
<mask> * @param syncedIterations number of synchronous iterations in each async iteration.
<mask> * @param fn the function to call each iteration.
<mask> * @param callback a success call back that will be called when iterating stops.
<mask> * @param breakFunction a break condition (optional)
<mask> * @param timeout timeout settings for the setTimeout function. default - 0.
<mask> * @constructor
<mask> */
<mask> AsyncLoop.SyncAsyncForLoop = function (iterations, syncedIterations, fn, callback, breakFunction, timeout) {
<mask> if (timeout === void 0) { timeout = 0; }
<mask> AsyncLoop.Run(Math.ceil(iterations / syncedIterations), function (loop) {
<mask> if (breakFunction && breakFunction())
<mask> loop.breakLoop();
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove if (timeout === void 0) { timeout = 0; }
</s> add if (typeof timeout === "undefined") { timeout = 0; }
</s> remove * An implementation of a loop for asynchronous functions.
*/
</s> add * An implementation of a loop for asynchronous functions.
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Break the loop and run the success callback.
*/
</s> add * Break the loop and run the success callback.
*/
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
if (typeof timeout === "undefined") { timeout = 0; }
| <mask> * @param timeout timeout settings for the setTimeout function. default - 0.
<mask> * @constructor
<mask> */
<mask> AsyncLoop.SyncAsyncForLoop = function (iterations, syncedIterations, fn, callback, breakFunction, timeout) {
<mask> if (timeout === void 0) { timeout = 0; }
<mask> AsyncLoop.Run(Math.ceil(iterations / syncedIterations), function (loop) {
<mask> if (breakFunction && breakFunction())
<mask> loop.breakLoop();
<mask> else {
<mask> setTimeout(function () {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> add * A for-loop that will run a given number of iterations synchronous and the rest async.
* @param iterations total number of iterations
* @param syncedIterations number of synchronous iterations in each async iteration.
* @param fn the function to call each iteration.
* @param callback a success call back that will be called when iterating stops.
* @param breakFunction a break condition (optional)
* @param timeout timeout settings for the setTimeout function. default - 0.
* @constructor
*/
</s> remove * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> add * Constroctor.
* @param iterations the number of iterations.
* @param _fn the function to run each iteration
* @param _successCallback the callback that will be called upon succesful execution
* @param offset starting offset.
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
</s> remove * Helper function
*/
</s> add * Helper function
*/
</s> remove if (offset === void 0) { offset = 0; }
</s> add if (typeof offset === "undefined") { offset = 0; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js |
<mask> return AsyncLoop;
<mask> })();
<mask> BABYLON.AsyncLoop = AsyncLoop;
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove //# sourceMappingURL=babylon.scene.js.map </s> add </s> remove //# sourceMappingURL=babylon.smartArray.js.map </s> add </s> remove //# sourceMappingURL=babylon.pickingInfo.js.map </s> add </s> remove //# sourceMappingURL=babylon.octree.js.map </s> add </s> remove //# sourceMappingURL=babylon.octreeBlock.js.map </s> add | [
"keep",
"keep",
"keep",
"keep",
"replace"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.js | |
<mask> var BABYLON;
<mask> (function (BABYLON) {
<mask> var Internals;
<mask> (function (Internals) {
<mask> /*
<mask> * Based on jsTGALoader - Javascript loader for TGA file
<mask> * By Vincent Thibault
<mask> * @blog http://blog.robrowser.com/javascript-tga-loader.html
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove var Internals;
</s> add </s> remove var Internals;
</s> add </s> remove var Internals;
</s> add </s> remove * An implementation of a loop for asynchronous functions.
*/
</s> add * An implementation of a loop for asynchronous functions.
*/
</s> remove var VirtualJoystick;
</s> add | [
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js | |
} else { | <mask> for (i = 0; i < count; ++i) {
<mask> pixel_data.set(pixels, localOffset + i * pixel_size);
<mask> }
<mask> localOffset += pixel_size * count;
<mask> }
<mask> else {
<mask> count *= pixel_size;
<mask> for (i = 0; i < count; ++i) {
<mask> pixel_data[localOffset + i] = data[offset++];
<mask> }
<mask> localOffset += count;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove // Statics
</s> add </s> remove } while (count < value);
</s> add } while(count < value);
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js |
} else { | <mask> }
<mask> localOffset += count;
<mask> }
<mask> }
<mask> }
<mask> else {
<mask> pixel_data = data.subarray(offset, offset += (use_pal ? header.width * header.height : pixel_total));
<mask> }
<mask> // Load to texture
<mask> var x_start, y_start, x_step, y_step, y_end, x_end;
<mask> switch ((header.flags & TGATools._ORIGIN_MASK) >> TGATools._ORIGIN_SHIFT) {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (this._pausedDelay) {
</s> add } else if (this._pausedDelay) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js |
})(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | <mask> TGATools._ORIGIN_UR = 0x03;
<mask> return TGATools;
<mask> })();
<mask> Internals.TGATools = TGATools;
<mask> })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.tga.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove //# sourceMappingURL=babylon.tools.tga.js.map </s> add </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add </s> remove //# sourceMappingURL=babylon.tools.dds.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js |
<mask> })();
<mask> Internals.TGATools = TGATools;
<mask> })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.tga.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove //# sourceMappingURL=babylon.tools.dds.js.map </s> add </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | [
"keep",
"keep",
"keep",
"keep",
"replace"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js | |
//# sourceMappingURL=babylon.tools.tga.js.map | <mask> })(BABYLON.Internals || (BABYLON.Internals = {}));
<mask> var Internals = BABYLON.Internals;
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.tools.tga.js.map
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove //# sourceMappingURL=babylon.tools.tga.js.map </s> add | [
"keep",
"keep",
"keep",
"add"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.tools.tga.js |
} else { | <mask> function VirtualJoystick(leftJoystick) {
<mask> var _this = this;
<mask> if (leftJoystick) {
<mask> this._leftJoystick = true;
<mask> }
<mask> else {
<mask> this._leftJoystick = false;
<mask> }
<mask> this._joystickIndex = VirtualJoystick._globalJoystickIndex;
<mask> VirtualJoystick._globalJoystickIndex++;
<mask> // By default left & right arrow keys are moving the X
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove var _this = this;
</s> add </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else { | <mask> var positionOnScreenCondition;
<mask> e.preventDefault();
<mask> if (this._leftJoystick === true) {
<mask> positionOnScreenCondition = (e.clientX < VirtualJoystick.halfWidth);
<mask> }
<mask> else {
<mask> positionOnScreenCondition = (e.clientX > VirtualJoystick.halfWidth);
<mask> }
<mask> if (positionOnScreenCondition && this._joystickPointerID < 0) {
<mask> // First contact will be dedicated to the virtual joystick
<mask> this._joystickPointerID = e.pointerId;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove if (insertAt === void 0) { insertAt = null; }
</s> add if (typeof insertAt === "undefined") { insertAt = null; }
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else { | <mask> this._deltaJoystickVector.x = 0;
<mask> this._deltaJoystickVector.y = 0;
<mask> this.pressed = true;
<mask> this._touches.add(e.pointerId.toString(), e);
<mask> }
<mask> else {
<mask> // You can only trigger the action buttons with a joystick declared
<mask> if (VirtualJoystick._globalJoystickIndex < 2 && this._action) {
<mask> this._action();
<mask> this._touches.add(e.pointerId.toString(), e);
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove if (priority === void 0) { priority = 0; }
</s> add if (typeof priority === "undefined") { priority = 0; } </s> remove }
else
</s> add } else </s> remove }
else if (parsedAction.properties[i].name != "propertyPath") {
</s> add } else if (parsedAction.properties[i].name != "propertyPath") { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else { | <mask> case 2 /* Z */:
<mask> this.deltaPosition.z = Math.min(1, Math.max(-1, deltaJoystickY));
<mask> break;
<mask> }
<mask> }
<mask> else {
<mask> if (this._touches.item(e.pointerId.toString())) {
<mask> this._touches.item(e.pointerId.toString()).x = e.clientX;
<mask> this._touches.item(e.pointerId.toString()).y = e.clientY;
<mask> }
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else { | <mask> };
<mask> VirtualJoystick.prototype._clearCanvas = function () {
<mask> if (this._leftJoystick) {
<mask> VirtualJoystick.vjCanvasContext.clearRect(0, 0, VirtualJoystick.vjCanvasWidth / 2, VirtualJoystick.vjCanvasHeight);
<mask> }
<mask> else {
<mask> VirtualJoystick.vjCanvasContext.clearRect(VirtualJoystick.vjCanvasWidth / 2, 0, VirtualJoystick.vjCanvasWidth, VirtualJoystick.vjCanvasHeight);
<mask> }
<mask> };
<mask> VirtualJoystick.prototype._drawVirtualJoystick = function () {
<mask> var _this = this;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (event.detail) {
</s> add } else if (event.detail) {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else { | <mask> VirtualJoystick.vjCanvasContext.beginPath();
<mask> VirtualJoystick.vjCanvasContext.strokeStyle = _this._joystickColor;
<mask> VirtualJoystick.vjCanvasContext.arc(_this._joystickPointerPos.x, _this._joystickPointerPos.y, 40, 0, Math.PI * 2, true);
<mask> VirtualJoystick.vjCanvasContext.stroke();
<mask> }
<mask> else {
<mask> VirtualJoystick.vjCanvasContext.beginPath();
<mask> VirtualJoystick.vjCanvasContext.fillStyle = "white";
<mask> VirtualJoystick.vjCanvasContext.beginPath();
<mask> VirtualJoystick.vjCanvasContext.strokeStyle = "red";
<mask> VirtualJoystick.vjCanvasContext.lineWidth = 6;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else if (info.isLuminance) {
</s> add } else if (info.isLuminance) { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
<mask> document.body.removeChild(VirtualJoystick.vjCanvas);
<mask> VirtualJoystick.vjCanvas = null;
<mask> }
<mask> };
<mask> // Used to draw the virtual joystick inside a 2D canvas on top of the WebGL rendering canvas
<mask> VirtualJoystick._globalJoystickIndex = 0;
<mask> return VirtualJoystick;
<mask> })();
<mask> BABYLON.VirtualJoystick = VirtualJoystick;
<mask> })(BABYLON || (BABYLON = {}));
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove var VirtualJoystick;
</s> add </s> remove try {
</s> add try { </s> remove try {
</s> add try { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js | |
<mask> BABYLON.VirtualJoystick = VirtualJoystick;
<mask> })(BABYLON || (BABYLON = {}));
<mask> var BABYLON;
<mask> (function (BABYLON) {
<mask> var VirtualJoystick;
<mask> (function (VirtualJoystick) {
<mask> var Collection = (function () {
<mask> function Collection() {
<mask> this._count = 0;
<mask> this._collection = new Array();
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove var Internals;
</s> add </s> remove if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxDepth === "undefined") { maxDepth = 2; } </s> remove var Internals;
</s> add </s> remove if (doNotChangeAspectRatio === void 0) { doNotChangeAspectRatio = true; }
</s> add if (typeof doNotChangeAspectRatio === "undefined") { doNotChangeAspectRatio = true; } </s> remove if (priority === void 0) { priority = 0; }
</s> add if (typeof priority === "undefined") { priority = 0; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js | |
})(BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
var VirtualJoystick = BABYLON.VirtualJoystick; | <mask> };
<mask> return Collection;
<mask> })();
<mask> VirtualJoystick.Collection = Collection;
<mask> })(VirtualJoystick = BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.virtualJoystick.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove //# sourceMappingURL=babylon.virtualJoystick.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
<mask> })();
<mask> VirtualJoystick.Collection = Collection;
<mask> })(VirtualJoystick = BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.virtualJoystick.js.map </s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove })(VirtualJoystick = BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
</s> add })(BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
var VirtualJoystick = BABYLON.VirtualJoystick; </s> remove //# sourceMappingURL=babylon.tools.tga.js.map </s> add </s> remove //# sourceMappingURL=babylon.tools.dds.js.map </s> add </s> remove //# sourceMappingURL=babylon.andOrNotEvaluator.js.map </s> add | [
"keep",
"keep",
"keep",
"keep",
"replace"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js | |
//# sourceMappingURL=babylon.virtualJoystick.js.map | <mask> })(BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
<mask> var VirtualJoystick = BABYLON.VirtualJoystick;
<mask> })(BABYLON || (BABYLON = {}));
<mask> //# sourceMappingURL=babylon.virtualJoystick.js.map
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove })(VirtualJoystick = BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
</s> add })(BABYLON.VirtualJoystick || (BABYLON.VirtualJoystick = {}));
var VirtualJoystick = BABYLON.VirtualJoystick; </s> remove //# sourceMappingURL=babylon.virtualJoystick.js.map </s> add </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; </s> remove })(Internals = BABYLON.Internals || (BABYLON.Internals = {}));
</s> add })(BABYLON.Internals || (BABYLON.Internals = {}));
var Internals = BABYLON.Internals; | [
"keep",
"keep",
"keep",
"add"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/Tools/babylon.virtualJoystick.js |
} else {
| <mask> // Cull
<mask> if (this._isCullDirty) {
<mask> if (this.cull) {
<mask> gl.enable(gl.CULL_FACE);
<mask> }
<mask> else {
<mask> gl.disable(gl.CULL_FACE);
<mask> }
<mask> this._isCullDirty = false;
<mask> }
<mask> // Cull face
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (this._pausedDelay) {
</s> add } else if (this._pausedDelay) {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
} else {
| <mask> // Depth test
<mask> if (this._isDepthTestDirty) {
<mask> if (this.depthTest) {
<mask> gl.enable(gl.DEPTH_TEST);
<mask> }
<mask> else {
<mask> gl.disable(gl.DEPTH_TEST);
<mask> }
<mask> this._isDepthTestDirty = false;
<mask> }
<mask> // Depth func
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (this._pausedDelay) {
</s> add } else if (this._pausedDelay) {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
} else {
| <mask> // Alpha blend
<mask> if (this._isAlphaBlendDirty) {
<mask> if (this._alphaBlend) {
<mask> gl.enable(gl.BLEND);
<mask> }
<mask> else {
<mask> gl.disable(gl.BLEND);
<mask> }
<mask> this._isAlphaBlendDirty = false;
<mask> }
<mask> // Alpha function
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (this._pausedDelay) {
</s> add } else if (this._pausedDelay) {
</s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
} else {
| <mask> if (samplingMode === BABYLON.Texture.BILINEAR_SAMPLINGMODE) {
<mask> magFilter = gl.LINEAR;
<mask> if (generateMipMaps) {
<mask> minFilter = gl.LINEAR_MIPMAP_NEAREST;
<mask> }
<mask> else {
<mask> minFilter = gl.LINEAR;
<mask> }
<mask> }
<mask> else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
<mask> magFilter = gl.LINEAR;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> add } else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> remove if (generateMipMaps === void 0) { generateMipMaps = true; }
if (invertY === void 0) { invertY = false; }
if (samplingMode === void 0) { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; }
</s> add if (typeof generateMipMaps === "undefined") { generateMipMaps = true; }
if (typeof invertY === "undefined") { invertY = false; }
if (typeof samplingMode === "undefined") { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; } </s> remove if (generateMipMaps === void 0) { generateMipMaps = true; }
if (invertY === void 0) { invertY = false; }
if (samplingMode === void 0) { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; }
</s> add if (typeof generateMipMaps === "undefined") { generateMipMaps = true; }
if (typeof invertY === "undefined") { invertY = false; }
if (typeof samplingMode === "undefined") { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; } </s> remove if (generateMipMaps === void 0) { generateMipMaps = true; }
if (invertY === void 0) { invertY = false; }
if (samplingMode === void 0) { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; }
</s> add if (typeof generateMipMaps === "undefined") { generateMipMaps = true; }
if (typeof invertY === "undefined") { invertY = false; }
if (typeof samplingMode === "undefined") { samplingMode = BABYLON.Texture.TRILINEAR_SAMPLINGMODE; } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
} else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
| <mask> }
<mask> else {
<mask> minFilter = gl.LINEAR;
<mask> }
<mask> }
<mask> else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
<mask> magFilter = gl.LINEAR;
<mask> if (generateMipMaps) {
<mask> minFilter = gl.LINEAR_MIPMAP_LINEAR;
<mask> }
<mask> else {
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
} else {
| <mask> else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
<mask> magFilter = gl.LINEAR;
<mask> if (generateMipMaps) {
<mask> minFilter = gl.LINEAR_MIPMAP_LINEAR;
<mask> }
<mask> else {
<mask> minFilter = gl.LINEAR;
<mask> }
<mask> }
<mask> else if (samplingMode === BABYLON.Texture.NEAREST_SAMPLINGMODE) {
<mask> magFilter = gl.NEAREST;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> add } else if (samplingMode === BABYLON.Texture.TRILINEAR_SAMPLINGMODE) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (parsedCamera.type === "OculusCamera") {
</s> add } else if (parsedCamera.type === "OculusCamera") { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.engine.js |
this.cameraToUseForPointers = null;
| <mask> this.forceWireframe = false;
<mask> this.forcePointsCloud = false;
<mask> this.forceShowBoundingBoxes = false;
<mask> this.animationsEnabled = true;
<mask> this.cameraToUseForPointers = null; // Define this parameter if you are using multiple cameras and you want to specify which one should be used for pointer position
<mask> // Fog
<mask> this.fogEnabled = true;
<mask> this.fogMode = Scene.FOGMODE_NONE;
<mask> this.fogColor = new BABYLON.Color3(0.2, 0.2, 0.3);
<mask> this.fogDensity = 0.1;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Members
</s> add </s> remove }
catch (ex) {
</s> add } catch (ex) { </s> remove // Flags
</s> add </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
this._pendingData = [];
| <mask> this._renderId = 0;
<mask> this._executeWhenReadyTimeoutId = -1;
<mask> this._toBeDisposed = new BABYLON.SmartArray(256);
<mask> this._onReadyCallbacks = new Array();
<mask> this._pendingData = []; //ANY
<mask> this._onBeforeRenderCallbacks = new Array();
<mask> this._onAfterRenderCallbacks = new Array();
<mask> this._activeMeshes = new BABYLON.SmartArray(256);
<mask> this._processedMaterials = new BABYLON.SmartArray(256);
<mask> this._renderTargets = new BABYLON.SmartArray(256);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove // Members
</s> add </s> remove // Flags
</s> add </s> remove var VirtualJoystick;
</s> add </s> remove if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxDepth === "undefined") { maxDepth = 2; } </s> remove this._vertexStrideSize = 15 * 4; // 15 floats per sprite (x, y, z, angle, size, offsetX, offsetY, invertU, invertV, cellIndexX, cellIndexY, color)
</s> add this._vertexStrideSize = 15 * 4;
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
var pickResult = _this.pick(_this._pointerX, _this._pointerY, function (mesh) {
return mesh.isPickable && mesh.isVisible && mesh.isReady() && mesh.actionManager && mesh.actionManager.hasPointerTriggers;
}, false, _this.cameraToUseForPointers);
| <mask> var _this = this;
<mask> this._onPointerMove = function (evt) {
<mask> var canvas = _this._engine.getRenderingCanvas();
<mask> _this._updatePointerPosition(evt);
<mask> var pickResult = _this.pick(_this._pointerX, _this._pointerY, function (mesh) { return mesh.isPickable && mesh.isVisible && mesh.isReady() && mesh.actionManager && mesh.actionManager.hasPointerTriggers; }, false, _this.cameraToUseForPointers);
<mask> if (pickResult.hit) {
<mask> _this._meshUnderPointer = pickResult.pickedMesh;
<mask> _this.setPointerOverMesh(pickResult.pickedMesh);
<mask> canvas.style.cursor = "pointer";
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
</s> remove if (useOverlay === void 0) { useOverlay = false; }
</s> add if (typeof useOverlay === "undefined") { useOverlay = false; } </s> remove }
else if (size.width && size.height) {
</s> add } else if (size.width && size.height) {
</s> remove this.meshesSelectionPredicate = function (m) { return m.material && m.isVisible && m.isEnabled() && m.isBlocker && ((m.layerMask & scene.activeCamera.layerMask) != 0); };
</s> add this.meshesSelectionPredicate = function (m) {
return m.material && m.isVisible && m.isEnabled() && m.isBlocker && ((m.layerMask & scene.activeCamera.layerMask) != 0);
};
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> if (pickResult.hit) {
<mask> _this._meshUnderPointer = pickResult.pickedMesh;
<mask> _this.setPointerOverMesh(pickResult.pickedMesh);
<mask> canvas.style.cursor = "pointer";
<mask> }
<mask> else {
<mask> _this.setPointerOverMesh(null);
<mask> canvas.style.cursor = "";
<mask> _this._meshUnderPointer = null;
<mask> }
<mask> };
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove var pickResult = _this.pick(_this._pointerX, _this._pointerY, function (mesh) { return mesh.isPickable && mesh.isVisible && mesh.isReady() && mesh.actionManager && mesh.actionManager.hasPointerTriggers; }, false, _this.cameraToUseForPointers);
</s> add
var pickResult = _this.pick(_this._pointerX, _this._pointerY, function (mesh) {
return mesh.isPickable && mesh.isVisible && mesh.isReady() && mesh.actionManager && mesh.actionManager.hasPointerTriggers;
}, false, _this.cameraToUseForPointers);
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> this._activeSkeletons.reset();
<mask> this._boundingBoxRenderer.reset();
<mask> if (!this._frustumPlanes) {
<mask> this._frustumPlanes = BABYLON.Frustum.GetPlanes(this._transformMatrix);
<mask> }
<mask> else {
<mask> BABYLON.Frustum.GetPlanesToRef(this._transformMatrix, this._frustumPlanes);
<mask> }
<mask> // Meshes
<mask> var meshes;
<mask> var len;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else if (material.needAlphaTesting()) {
</s> add } else if (material.needAlphaTesting()) { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> if (this._selectionOctree) {
<mask> var selection = this._selectionOctree.select(this._frustumPlanes);
<mask> meshes = selection.data;
<mask> len = selection.length;
<mask> }
<mask> else {
<mask> len = this.meshes.length;
<mask> meshes = this.meshes;
<mask> }
<mask> for (var meshIndex = 0; meshIndex < len; meshIndex++) {
<mask> var mesh = meshes[meshIndex];
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else if (texture instanceof BABYLON.RenderTargetTexture) {
</s> add } else if (texture instanceof BABYLON.RenderTargetTexture) { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> if (mesh._submeshesOctree && mesh.useOctreeForRenderingSelection) {
<mask> var intersections = mesh._submeshesOctree.select(this._frustumPlanes);
<mask> len = intersections.length;
<mask> subMeshes = intersections.data;
<mask> }
<mask> else {
<mask> subMeshes = mesh.subMeshes;
<mask> len = subMeshes.length;
<mask> }
<mask> for (var subIndex = 0; subIndex < len; subIndex++) {
<mask> var subMesh = subMeshes[subIndex];
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else if (texture instanceof BABYLON.RenderTargetTexture) {
</s> add } else if (texture instanceof BABYLON.RenderTargetTexture) { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else if (!areIntersecting && currentIntersectionInProgress > -1 && action.trigger === BABYLON.ActionManager.OnIntersectionExitTrigger) {
| <mask> var currentIntersectionInProgress = sourceMesh._intersectionsInProgress.indexOf(otherMesh);
<mask> if (areIntersecting && currentIntersectionInProgress === -1 && action.trigger === BABYLON.ActionManager.OnIntersectionEnterTrigger) {
<mask> action._executeCurrent(BABYLON.ActionEvent.CreateNew(sourceMesh));
<mask> sourceMesh._intersectionsInProgress.push(otherMesh);
<mask> }
<mask> else if (!areIntersecting && currentIntersectionInProgress > -1 && action.trigger === BABYLON.ActionManager.OnIntersectionExitTrigger) {
<mask> action._executeCurrent(BABYLON.ActionEvent.CreateNew(sourceMesh));
<mask> var indexOfOther = sourceMesh._intersectionsInProgress.indexOf(otherMesh);
<mask> if (indexOfOther > -1) {
<mask> sourceMesh._intersectionsInProgress.splice(indexOfOther, 1);
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (dataType === 2) {
</s> add } else if (dataType === 2) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else {
</s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> for (var cameraIndex = 0; cameraIndex < this.activeCameras.length; cameraIndex++) {
<mask> this._renderId = currentRenderId;
<mask> this._processSubCameras(this.activeCameras[cameraIndex]);
<mask> }
<mask> }
<mask> else {
<mask> if (!this.activeCamera) {
<mask> throw new Error("No camera defined");
<mask> }
<mask> this._processSubCameras(this.activeCamera);
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { </s> remove }
else {
</s> add } else { | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
} else {
| <mask> var listeningCamera;
<mask> var audioEngine = this._engine.getAudioEngine();
<mask> if (this.activeCameras.length > 0) {
<mask> listeningCamera = this.activeCameras[0];
<mask> }
<mask> else {
<mask> listeningCamera = this.activeCamera;
<mask> }
<mask> if (listeningCamera && audioEngine.canUseWebAudio) {
<mask> audioEngine.audioContext.listener.setPosition(listeningCamera.position.x, listeningCamera.position.y, listeningCamera.position.z);
<mask> var mat = BABYLON.Matrix.Invert(listeningCamera.getViewMatrix());
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove }
else if (parsedGeometry instanceof ArrayBuffer) {
</s> add } else if (parsedGeometry instanceof ArrayBuffer) { </s> remove }
else if (!areIntersecting && currentIntersectionInProgress > -1 && action.trigger === BABYLON.ActionManager.OnIntersectionExitTrigger) {
</s> add } else if (!areIntersecting && currentIntersectionInProgress > -1 && action.trigger === BABYLON.ActionManager.OnIntersectionExitTrigger) {
</s> remove }
else {
</s> add } else {
</s> remove }
else {
</s> add } else { </s> remove }
else if (size.width && !size.height) {
</s> add } else if (size.width && !size.height) {
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
if (typeof excludedMesh === "undefined") { excludedMesh = null; }
| <mask> this._engine.wipeCaches();
<mask> };
<mask> // Collisions
<mask> Scene.prototype._getNewPosition = function (position, velocity, collider, maximumRetry, finalPosition, excludedMesh) {
<mask> if (excludedMesh === void 0) { excludedMesh = null; }
<mask> position.divideToRef(collider.radius, this._scaledPosition);
<mask> velocity.divideToRef(collider.radius, this._scaledVelocity);
<mask> collider.retry = 0;
<mask> collider.initialVelocity = this._scaledVelocity;
<mask> collider.initialPosition = this._scaledPosition;
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (excludedMesh === void 0) { excludedMesh = null; }
</s> add if (typeof excludedMesh === "undefined") { excludedMesh = null; }
</s> remove if (maxCapacity === void 0) { maxCapacity = 64; }
if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxCapacity === "undefined") { maxCapacity = 64; }
if (typeof maxDepth === "undefined") { maxDepth = 2; }
</s> remove if (samplingMode === void 0) { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (onLoad === void 0) { onLoad = null; }
if (onError === void 0) { onError = null; }
if (buffer === void 0) { buffer = null; }
if (deleteBuffer === void 0) { deleteBuffer = false; }
</s> add if (typeof samplingMode === "undefined") { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (typeof onLoad === "undefined") { onLoad = null; }
if (typeof onError === "undefined") { onError = null; }
if (typeof buffer === "undefined") { buffer = null; }
if (typeof deleteBuffer === "undefined") { deleteBuffer = false; } </s> remove if (samplingMode === void 0) { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (onLoad === void 0) { onLoad = null; }
if (onError === void 0) { onError = null; }
</s> add if (typeof samplingMode === "undefined") { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (typeof onLoad === "undefined") { onLoad = null; }
if (typeof onError === "undefined") { onError = null; } </s> remove // Constants
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
if (typeof excludedMesh === "undefined") { excludedMesh = null; }
| <mask> this._collideWithWorld(this._scaledPosition, this._scaledVelocity, collider, maximumRetry, finalPosition, excludedMesh);
<mask> finalPosition.multiplyInPlace(collider.radius);
<mask> };
<mask> Scene.prototype._collideWithWorld = function (position, velocity, collider, maximumRetry, finalPosition, excludedMesh) {
<mask> if (excludedMesh === void 0) { excludedMesh = null; }
<mask> var closeDistance = BABYLON.Engine.CollisionsEpsilon * 10.0;
<mask> if (collider.retry >= maximumRetry) {
<mask> finalPosition.copyFrom(position);
<mask> return;
<mask> }
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (excludedMesh === void 0) { excludedMesh = null; }
</s> add if (typeof excludedMesh === "undefined") { excludedMesh = null; }
</s> remove if (maxCapacity === void 0) { maxCapacity = 64; }
if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxCapacity === "undefined") { maxCapacity = 64; }
if (typeof maxDepth === "undefined") { maxDepth = 2; }
</s> remove if (samplingMode === void 0) { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (onLoad === void 0) { onLoad = null; }
if (onError === void 0) { onError = null; }
if (buffer === void 0) { buffer = null; }
if (deleteBuffer === void 0) { deleteBuffer = false; }
</s> add if (typeof samplingMode === "undefined") { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (typeof onLoad === "undefined") { onLoad = null; }
if (typeof onError === "undefined") { onError = null; }
if (typeof buffer === "undefined") { buffer = null; }
if (typeof deleteBuffer === "undefined") { deleteBuffer = false; } </s> remove if (samplingMode === void 0) { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (onLoad === void 0) { onLoad = null; }
if (onError === void 0) { onError = null; }
</s> add if (typeof samplingMode === "undefined") { samplingMode = Texture.TRILINEAR_SAMPLINGMODE; }
if (typeof onLoad === "undefined") { onLoad = null; }
if (typeof onError === "undefined") { onError = null; } </s> remove if (condition === void 0) { condition = true; }
</s> add if (typeof condition === "undefined") { condition = true; }
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
if (typeof maxCapacity === "undefined") { maxCapacity = 64; }
if (typeof maxDepth === "undefined") { maxDepth = 2; }
| <mask> this._collideWithWorld(position, velocity, collider, maximumRetry, finalPosition, excludedMesh);
<mask> };
<mask> // Octrees
<mask> Scene.prototype.createOrUpdateSelectionOctree = function (maxCapacity, maxDepth) {
<mask> if (maxCapacity === void 0) { maxCapacity = 64; }
<mask> if (maxDepth === void 0) { maxDepth = 2; }
<mask> if (!this._selectionOctree) {
<mask> this._selectionOctree = new BABYLON.Octree(BABYLON.Octree.CreationFuncForMeshes, maxCapacity, maxDepth);
<mask> }
<mask> var min = new BABYLON.Vector3(Number.MAX_VALUE, Number.MAX_VALUE, Number.MAX_VALUE);
<mask> var max = new BABYLON.Vector3(-Number.MAX_VALUE, -Number.MAX_VALUE, -Number.MAX_VALUE);
</s> Update after project rebuild
Former-commit-id: a2d5c6a94ad4c31a48c189703e1214d6166528bf </s> remove if (maxDepth === void 0) { maxDepth = 2; }
</s> add if (typeof maxDepth === "undefined") { maxDepth = 2; } </s> remove if (excludedMesh === void 0) { excludedMesh = null; }
</s> add if (typeof excludedMesh === "undefined") { excludedMesh = null; }
</s> remove if (excludedMesh === void 0) { excludedMesh = null; }
</s> add if (typeof excludedMesh === "undefined") { excludedMesh = null; }
</s> remove if (min === void 0) { min = 0; }
if (max === void 0) { max = 1; }
</s> add if (typeof min === "undefined") { min = 0; }
if (typeof max === "undefined") { max = 1; }
</s> remove // Misc.
</s> add
// Misc.
| [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/edcbda493d762fc8ea70d9f619197c04976ad87e | Babylon/babylon.scene.js |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.