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 |
|---|---|---|---|---|
this._rebuild(undefined, this._textureNames);
| <mask> * @param size Define the new size
<mask> */
<mask> public resize(size: any) {
<mask> this._size = size;
<mask> this._rebuild();
<mask> }
<mask>
<mask> /**
<mask> * Changes the number of render targets in this MRT
<mask> * Be careful as it will recreate a... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/multiRenderTarget.ts |
this._textureNames = textureNames;
| <mask> const layerCounts: number[] = [];
<mask>
<mask> this._initTypes(count, types, samplingModes, useSRGBBuffers, targetTypes, faceIndex, layerIndex, layerCounts, options);
<mask> this._multiRenderTargetOptions.types = types;
<mask> this._multiRenderTargetOptions.samplingModes = ... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/multiRenderTarget.ts |
<mask> }
<mask> }
<mask>
<mask> private _isCubeData: boolean;
<mask> protected _isMulti: boolean;
<mask>
<mask> /**
<mask> * Define if the texture has multiple draw buffers or if false a single draw buffer.
<mask> */
<mask> public get isMulti(): boolean {
</s> Support ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/renderTargetTexture.ts | |
return this._renderTarget?.isMulti ?? false;
| <mask> /**
<mask> * Define if the texture has multiple draw buffers or if false a single draw buffer.
<mask> */
<mask> public get isMulti(): boolean {
<mask> return this._isMulti;
<mask> }
<mask>
<mask> /**
<mask> * Gets render target creation options that were used.
<m... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/renderTargetTexture.ts |
<mask> this.isRenderTarget = true;
<mask> this._initialSizeParameter = size;
<mask> this._renderPassIds = [];
<mask> this._isCubeData = isCube;
<mask> this._isMulti = isMulti;
<mask>
<mask> this._processSizeParameter(size);
<mask>
<mask> this.renderPass... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/renderTargetTexture.ts | |
if (this.is2DArray && !this.isMulti) {
| <mask>
<mask> let returnValue = checkReadiness;
<mask>
<mask> if (!checkReadiness) {
<mask> if (!this._isMulti && this.is2DArray) {
<mask> for (let layer = 0; layer < this.getRenderLayers(); layer++) {
<mask> this._renderToTarget(0, useCameraPostP... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/renderTargetTexture.ts |
} else if (this.isCube && !this.isMulti) {
| <mask> this._renderToTarget(0, useCameraPostProcess, dumpForDebug, layer, camera);
<mask> scene.incrementRenderId();
<mask> scene.resetCachedMaterial();
<mask> }
<mask> } else if (!this._isMulti && this.isCube) {
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/renderTargetTexture.ts |
/** @internal */
public _noMipmap: boolean = false;
| <mask> * @see https://doc.babylonjs.com/toolsAndResources/inspector#extensibility
<mask> */
<mask> public inspectableCustomProperties: Nullable<IInspectable[]> = null;
<mask>
<mask> private _noMipmap: boolean = false;
<mask> /** @internal */
<mask> public _invertY: boolean = false;
<m... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/texture.ts |
/** @internal */
public _useSRGBBuffer?: boolean;
| <mask> private _delayedOnError: Nullable<() => void> = null;
<mask> private _mimeType?: string;
<mask> private _loaderOptions?: any;
<mask> private _creationFlags?: number;
<mask> private _useSRGBBuffer?: boolean;
<mask> private _forcedExtension?: string;
<mask>
<mask> /** Returns t... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/core/src/Materials/Textures/texture.ts |
{texture.is2DArray && (
<TextLineComponent label="Layers" value={texture._texture?.depth.toString() ?? "?"} />
)}
{texture.is3D && (
<TextLineComponent label="Depth" value={texture._texture?.depth.toString() ... | <mask> <LineContainerComponent title="GENERAL" selection={this.props.globalState}>
<mask> <TextLineComponent label="Width" value={texture.getSize().width.toString()} />
<mask> <TextLineComponent label="Height" value={texture.getSize().height.toString()} />
<ma... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b7fe107e526d3a6dd2da3c5be101b3b313223576 | packages/dev/inspector/src/components/actionTabs/tabs/propertyGrids/materials/texturePropertyGridComponent.tsx |
_readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex?: number, level?: number, buffer?: Nullable<ArrayBufferView>, flushRenderer?: boolean): Promise<ArrayBufferView>;
| <mask>
<mask> declare module "../../Engines/thinEngine" {
<mask> export interface ThinEngine {
<mask> /** @hidden */
<mask> _readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex?: number, level?: number, buffer?: Nullable<ArrayBufferView>): Promise<ArrayBufferVi... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/Extensions/engine.readTexture.ts |
ThinEngine.prototype._readTexturePixels = function(texture: InternalTexture, width: number, height: number, faceIndex = -1, level = 0, buffer: Nullable<ArrayBufferView> = null, flushRenderer = true): Promise<ArrayBufferView> {
| <mask> _readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex?: number, level?: number, buffer?: Nullable<ArrayBufferView>): Promise<ArrayBufferView>;
<mask> }
<mask> }
<mask>
<mask> ThinEngine.prototype._readTexturePixels = function(texture: InternalTexture, width: numb... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/Extensions/engine.readTexture.ts |
if (flushRenderer) {
this.flushFramebuffer();
}
| <mask> readType = gl.FLOAT;
<mask> break;
<mask> }
<mask>
<mask> gl.readPixels(0, 0, width, height, gl.RGBA, readType, <DataView>buffer);
<mask> gl.bindFramebuffer(gl.FRAMEBUFFER, this._currentFramebuffer);
<mask>
<mask> return Promise.resolve(buffer);
<mask> }; </s> B... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/Extensions/engine.readTexture.ts |
* @param flushRenderer true to flush the renderer from the pending commands before reading the pixels
| <mask> * @param height defines the height of the rectangle where pixels must be read
<mask> * @param hasAlpha defines whether the output should have alpha or not (defaults to true)
<mask> * @returns a ArrayBufferView (Uint8Array) containing RGBA colors
<mask> */
<mask> public readPixels(x: ... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/thinEngine.ts |
public readPixels(x: number, y: number, width: number, height: number, hasAlpha = true, flushRenderer = true): Promise<ArrayBufferView> {
| <mask> * @param height defines the height of the rectangle where pixels must be read
<mask> * @param hasAlpha defines whether the output should have alpha or not (defaults to true)
<mask> * @returns a ArrayBufferView (Uint8Array) containing RGBA colors
<mask> */
<mask> public readPixels(x: ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/thinEngine.ts |
if (flushRenderer) {
this.flushFramebuffer();
}
| <mask> public readPixels(x: number, y: number, width: number, height: number, hasAlpha = true, flushRenderer = true): Promise<ArrayBufferView> {
<mask> const numChannels = hasAlpha ? 4 : 3;
<mask> const format = hasAlpha ? this._gl.RGBA : this._gl.RGB;
<mask> const data = new Uint8Array(... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/thinEngine.ts |
public readPixels(x: number, y: number, width: number, height: number, hasAlpha = true, flushRenderer = true): Promise<ArrayBufferView> {
| <mask>
<mask> texture.isReady = true;
<mask> }
<mask>
<mask> public readPixels(x: number, y: number, width: number, height: number, hasAlpha = true): Promise<ArrayBufferView> {
<mask> const renderPassWrapper = this._rttRenderPassWrapper.renderPass ? this._rttRenderPassWrapper : this._mai... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/webgpuEngine.ts |
if (flushRenderer) {
this.flushFramebuffer();
}
| <mask> if (!gpuTexture) {
<mask> // we are calling readPixels before startMainRenderPass has been called and no RTT is bound, so swapChainTexture is not setup yet!
<mask> return Promise.resolve(new Uint8Array(0));
<mask> }
<mask> return this._textureHelper.readPixels... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/webgpuEngine.ts |
public _readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex = -1, level = 0, buffer: Nullable<ArrayBufferView> = null, flushRenderer = true): Promise<ArrayBufferView> {
| <mask> return this._textureHelper.readPixels(gpuTexture, x, y, width, height, gpuTextureFormat);
<mask> }
<mask>
<mask> /** @hidden */
<mask> public _readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex = -1, level = 0, buffer: Nullable<ArrayBufferView> = null):... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/webgpuEngine.ts |
if (flushRenderer) {
this.flushFramebuffer();
}
| <mask> public _readTexturePixels(texture: InternalTexture, width: number, height: number, faceIndex = -1, level = 0, buffer: Nullable<ArrayBufferView> = null, flushRenderer = true): Promise<ArrayBufferView> {
<mask> let gpuTextureWrapper = texture._hardwareTexture as WebGPUHardwareTexture;
<mask>
<mask... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Engines/webgpuEngine.ts |
* @param flushRenderer true to flush the renderer from the pending commands before reading the pixels
| <mask> * @param level defines the LOD level of the texture to read (in case of Mip Maps)
<mask> * @param buffer defines a user defined buffer to fill with data (can be null)
<mask> * @returns The Array buffer promise containing the pixels data.
<mask> */
<mask> public readPixels(faceIndex =... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Materials/Textures/baseTexture.ts |
public readPixels(faceIndex = 0, level = 0, buffer: Nullable<ArrayBufferView> = null, flushRenderer = true): Nullable<Promise<ArrayBufferView>> {
| <mask> * @param level defines the LOD level of the texture to read (in case of Mip Maps)
<mask> * @param buffer defines a user defined buffer to fill with data (can be null)
<mask> * @returns The Array buffer promise containing the pixels data.
<mask> */
<mask> public readPixels(faceIndex =... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Materials/Textures/baseTexture.ts |
return engine._readTexturePixels(this._texture, width, height, faceIndex, level, buffer, flushRenderer);
| <mask> }
<mask>
<mask> try {
<mask> if (this._texture.isCube) {
<mask> return engine._readTexturePixels(this._texture, width, height, faceIndex, level, buffer);
<mask> }
<mask>
<mask> return engine._readTexturePixels(this._texture, width, hei... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Materials/Textures/baseTexture.ts |
return engine._readTexturePixels(this._texture, width, height, -1, level, buffer, flushRenderer);
| <mask> if (this._texture.isCube) {
<mask> return engine._readTexturePixels(this._texture, width, height, faceIndex, level, buffer);
<mask> }
<mask>
<mask> return engine._readTexturePixels(this._texture, width, height, -1, level, buffer);
<mask> } catch ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Materials/Textures/baseTexture.ts |
texture.getScene()?.getEngine().flushFramebuffer();
| <mask> // Only supports cube Textures currently.
<mask> return null;
<mask> }
<mask>
<mask> var size = texture.getSize().width;
<mask> var rightPromise = texture.readPixels(0, undefined, undefined, false);
<mask> var leftPromise = texture.readPixels(1, und... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/HighDynamicRange/cubemapToSphericalPolynomial.ts |
var rightPromise = texture.readPixels(0, undefined, undefined, false);
var leftPromise = texture.readPixels(1, undefined, undefined, false);
| <mask> return null;
<mask> }
<mask>
<mask> var size = texture.getSize().width;
<mask> var rightPromise = texture.readPixels(0);
<mask> var leftPromise = texture.readPixels(1);
<mask>
<mask> var upPromise: Nullable<Promise<ArrayBufferView>>;
<mask> v... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/HighDynamicRange/cubemapToSphericalPolynomial.ts |
upPromise = texture.readPixels(3, undefined, undefined, false);
downPromise = texture.readPixels(2, undefined, undefined, false);
| <mask>
<mask> var upPromise: Nullable<Promise<ArrayBufferView>>;
<mask> var downPromise: Nullable<Promise<ArrayBufferView>>;
<mask> if (texture.isRenderTarget) {
<mask> upPromise = texture.readPixels(3);
<mask> downPromise = texture.readPixels(2);
<mask> }... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/HighDynamicRange/cubemapToSphericalPolynomial.ts |
upPromise = texture.readPixels(2, undefined, undefined, false);
downPromise = texture.readPixels(3, undefined, undefined, false);
| <mask> upPromise = texture.readPixels(3);
<mask> downPromise = texture.readPixels(2);
<mask> }
<mask> else {
<mask> upPromise = texture.readPixels(2);
<mask> downPromise = texture.readPixels(3);
<mask> }
<mask>
<mask> var frontPro... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/HighDynamicRange/cubemapToSphericalPolynomial.ts |
var frontPromise = texture.readPixels(4, undefined, undefined, false);
var backPromise = texture.readPixels(5, undefined, undefined, false);
| <mask> upPromise = texture.readPixels(2);
<mask> downPromise = texture.readPixels(3);
<mask> }
<mask>
<mask> var frontPromise = texture.readPixels(4);
<mask> var backPromise = texture.readPixels(5);
<mask>
<mask> var gammaSpace = texture.gammaSpace;
<ma... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/HighDynamicRange/cubemapToSphericalPolynomial.ts |
let faceData = await texture.readPixels(face, i, undefined, false);
| <mask> let faceWidth = Math.pow(2, mipmapsCount - i);
<mask>
<mask> // All faces of the cube.
<mask> for (let face = 0; face < 6; face++) {
<mask> let faceData = await texture.readPixels(face, i);
<mask>
<mask> let tempTexture = engine.createR... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/environmentTextureTools.ts |
<mask> let tempTexture = engine.createRawTexture(faceData, faceWidth, faceWidth, Constants.TEXTUREFORMAT_RGBA, false, true, Constants.TEXTURE_NEAREST_SAMPLINGMODE, null, textureType);
<mask>
<mask> await RGBDTextureTools.EncodeTextureToRGBD(tempTexture, hostingScene, textureType);
<... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/environmentTextureTools.ts | |
scene.getEngine()._readTexturePixels(reduction.inputTexture, w, h, -1, 0, buffer, false);
| <mask> let func = (w: number, h: number, reduction: PostProcess) => {
<mask> let buffer = new Float32Array(4 * w * h),
<mask> minmax = { min: 0, max: 0};
<mask> return () => {
<mask> scene.getEngine()._readTextu... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/minMaxReducer.ts |
texture.readPixels(undefined, undefined, undefined, false)!.then((data) => {
| <mask> texture.renderList = null;
<mask> texture.samples = samples;
<mask> texture.renderSprites = renderSprites;
<mask> engine.onEndFrameObservable.addOnce(() => {
<mask> texture.readPixels()!.then((data) => {
<mask> Tools.DumpData(width, height, data, ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b8bee887367799b91f5628036d6887a0a5b1e102 | src/Misc/screenshotTools.ts |
sideOrientation = sideOrientation || options.sideOrientation || Mesh.DEFAULTSIDE; | <mask> depth = options || 1;
<mask> }
<mask>
<mask> for (var f = 0; f < 6; f++) {
<mask> if (faceUV[f] === undefined) {
<mask> faceUV[f] = new Vector4(0, 0, 1, 1);
<mask> }
</s> added colors for doubleside orientation
... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9237b6f6ec74798abacf40dd5ebb547c5f3f517 | src/Mesh/babylon.mesh.vertexData.ts |
} | <mask> }
<mask> if (faceColors[f] === undefined) {
<mask> faceColors[f] = new Color4(1, 1, 1, 1);
<mask> }
<mask> }
<mask>
<mask> sideOrientation = sideOrientation || options.sideOrientation || Mesh.DEFAULTSIDE;
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9237b6f6ec74798abacf40dd5ebb547c5f3f517 | src/Mesh/babylon.mesh.vertexData.ts |
var totalColors = (sideOrientation == Mesh.DOUBLESIDE) ? colors.concat(colors) : colors;
vertexData.colors = totalColors; | <mask> vertexData.indices = indices;
<mask> vertexData.positions = positions;
<mask> vertexData.normals = normals;
<mask> vertexData.uvs = uvs;
<mask> vertexData.colors = colors;
<mask>
<mask> return vertexData;
<mask> }
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9237b6f6ec74798abacf40dd5ebb547c5f3f517 | src/Mesh/babylon.mesh.vertexData.ts |
if (light.getTypeID() === 2) {
| <mask> defines["POINTLIGHT" + lightIndex] = false;
<mask> defines["DIRLIGHT" + lightIndex] = false;
<mask>
<mask> var type;
<mask> if (light.getClassName() === "SpotLight") {
<mask> type = "SPOTLIGHT" + lightI... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
} else if (light.getTypeID() === 3) {
| <mask>
<mask> var type;
<mask> if (light.getClassName() === "SpotLight") {
<mask> type = "SPOTLIGHT" + lightIndex;
<mask> } else if (light.getClassName() === "HemisphericLight") {
<mask> type = "HEMILIGHT"... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
} else if (light.getTypeID() === 0) {
| <mask> if (light.getClassName() === "SpotLight") {
<mask> type = "SPOTLIGHT" + lightIndex;
<mask> } else if (light.getClassName() === "HemisphericLight") {
<mask> type = "HEMILIGHT" + lightIndex;
<mask> } el... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
if (light.getTypeID() === 0) {
| <mask> return depthValuesAlreadySet;
<mask> }
<mask>
<mask> public static BindLightProperties(light: Light, effect: Effect, lightIndex: number): void {
<mask> if (light.getClassName() === "PointLight") {
<mask> // Point Light
<mask> light.t... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
} else if (light.getTypeID() === 1) {
| <mask> public static BindLightProperties(light: Light, effect: Effect, lightIndex: number): void {
<mask> if (light.getClassName() === "PointLight") {
<mask> // Point Light
<mask> light.transferToEffect(effect, "vLightData" + lightIndex);
<mask> } els... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
} else if (light.getTypeID() === 2) {
| <mask> light.transferToEffect(effect, "vLightData" + lightIndex);
<mask> } else if (light.getClassName() === "DirectionalLight") {
<mask> // Directional Light
<mask> light.transferToEffect(effect, "vLightData" + lightIndex);
<mask> } else if (... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
} else if (light.getTypeID() === 3) {
| <mask> light.transferToEffect(effect, "vLightData" + lightIndex);
<mask> } else if (light.getClassName() === "SpotLight") {
<mask> // Spot Light
<mask> light.transferToEffect(effect, "vLightData" + lightIndex, "vLightDirection" + lightIndex);
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/Materials/babylon.materialHelper.ts |
this.loadingScreen.displayLoadingUI();
| <mask> }
<mask>
<mask> // Loading screen
<mask> public displayLoadingUI(): void {
<mask> if (!this._loadingScreen) this._loadingScreen = new DefaultLoadingScreen(this._renderingCanvas)
<mask> this._loadingScreen.displayLoadingUI();
<mask> }
<mask>
<mask... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/babylon.engine.ts |
this.loadingScreen.hideLoadingUI();
| <mask> this._loadingScreen.displayLoadingUI();
<mask> }
<mask>
<mask> public hideLoadingUI(): void {
<mask> if (!this._loadingScreen) this._loadingScreen = new DefaultLoadingScreen(this._renderingCanvas)
<mask> this._loadingScreen.hideLoadingUI();
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/babylon.engine.ts |
<mask> return this._loadingScreen;
<mask> }
<mask>
<mask> public set loadingScreen(loadingScreen: ILoadingScreen) {
<mask> if (!this._loadingScreen) this._loadingScreen = new DefaultLoadingScreen(this._renderingCanvas)
<mask> this._loadingScreen = loadingScreen... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/babylon.engine.ts | |
this.loadingScreen.loadingUIText = text;
| <mask> this._loadingScreen = loadingScreen;
<mask> }
<mask>
<mask> public set loadingUIText(text: string) {
<mask> if (!this._loadingScreen) this._loadingScreen = new DefaultLoadingScreen(this._renderingCanvas)
<mask> this._loadingScreen.loadingUIText = text;
... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/babylon.engine.ts |
this.loadingScreen.loadingUIBackgroundColor = color;
| <mask> this._loadingScreen.loadingUIText = text;
<mask> }
<mask>
<mask> public set loadingUIBackgroundColor(color: string) {
<mask> if (!this._loadingScreen) this._loadingScreen = new DefaultLoadingScreen(this._renderingCanvas)
<mask> this._loadingScreen.loadin... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9454e737f8d0e0955f4d4c2cb877cc535c05264 | src/babylon.engine.ts |
this._unBindEffect();
| <mask> if (!this.subMeshes) {
<mask> return;
<mask> }
<mask>
<mask> for (var subMesh of this.subMeshes) {
<mask> subMesh.setEffect(null);
<mask> }
<mask> }
<mask>
<mask> private _receiveShadows = false;
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9de0cad3977e671bf5a2f6e7f9e1640ebea85c3 | src/Mesh/babylon.abstractMesh.ts |
private _receiveShadows = false;
| <mask> subMesh.setEffect(null);
<mask> }
<mask> }
<mask>
<mask> private _receiveShadows = false;
<mask> public get receiveShadows(): boolean {
<mask> return this._receiveShadows;
<mask> }
<mask> public set receiveShadows(value: bo... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9de0cad3977e671bf5a2f6e7f9e1640ebea85c3 | src/Mesh/babylon.abstractMesh.ts |
/** @ignore */
public _unBindEffect() {
for (var subMesh of this.subMeshes) {
subMesh.setEffect(null);
}
}
| <mask> }
<mask>
<mask> public _removeLightSource(light: Light): void {
<mask> var index = this._lightSources.indexOf(light);
<mask>
<mask> if (index === -1) {
</s> Fix instances + cache issue
Former-commit-id: b07954f2000e9685921c95705f48fce1e392608a </s> remove ... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9de0cad3977e671bf5a2f6e7f9e1640ebea85c3 | src/Mesh/babylon.abstractMesh.ts |
public _unBindEffect() {
super._unBindEffect();
for (var instance of this.instances) {
instance._unBindEffect();
}
}
| <mask> return ret;
<mask> }
<mask>
<mask> /**
<mask> * True if the mesh has some Levels Of Details (LOD).
<mask> * Returns a boolean.
<mask> */
<mask> public get hasLODLevels(): boolean {
<mask> return this._LODLevels.length > 0;
<... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/b9de0cad3977e671bf5a2f6e7f9e1640ebea85c3 | src/Mesh/babylon.mesh.ts |
import { NodeMaterial } from "babylonjs/Materials/Node/nodeMaterial";
import { TextureBlock } from "babylonjs/Materials/Node/Blocks/Dual/textureBlock";
| <mask> import { Tools } from "../tools";
<mask> import { CreateGround } from "babylonjs/Meshes/Builders/groundBuilder";
<mask> require("./workbenchCanvas.scss");
<mask>
<mask> export interface IWorkbenchComponentProps {
<mask> globalState: GlobalState;
<mask> }
</s> working on background texture
Former-c... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/ba30d6791b8d40de0481a4a3b4b2ded93915e4f7 | guiEditor/src/diagram/workbench.tsx |
this.artBoardBackground.background = "transparent";
| <mask> this._textureMesh.showBoundingBox = true;
<mask> this.artBoardBackground = new Rectangle("Art-Board-Background");
<mask> this.artBoardBackground.width = "100%"
<mask> this.artBoardBackground.height = "100%";
<mask> this.artBoardBackground.background = "white";
<mask>... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/ba30d6791b8d40de0481a4a3b4b2ded93915e4f7 | guiEditor/src/diagram/workbench.tsx |
NodeMaterial.ParseFromSnippetAsync("#GZI99M#6", this._scene).then(nodeMaterial => {
this._textureMesh.material = nodeMaterial;
if(nodeMaterial) {
let block = nodeMaterial.getBlockByName("Texture") as TextureBlock;
block.texture = this.globalState.gui... | <mask> this.artBoardBackground.background = "transparent";
<mask> this.artBoardBackground.thickness = 0;
<mask>
<mask> this.globalState.guiTexture.addControl(this.artBoardBackground);
<mask> this.setCameraRadius();
<mask> this._camera = new ArcRotateCamera("Camera", -Math.... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/ba30d6791b8d40de0481a4a3b4b2ded93915e4f7 | guiEditor/src/diagram/workbench.tsx |
import { Tools } from "babylonjs";
| <mask> import { Measure } from "../measure";
<mask> import { Control } from "./control";
<mask>
<mask> /**
<mask> * Class used to create a 2D stack panel container
<mask> */
<mask> export class StackPanel extends Container {
</s> Added warning to help prevnting layout cycles [gui]
Former-commit-id: 38ee361... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd0fd38bd8a371f2456c81ab8e9416110341bdb9 | gui/src/2D/controls/stackPanel.ts |
if (child._height.isPercentage) {
Tools.Warn(`Control (Name:${child.name}, UniqueId:${child.uniqueId}) is using height in percentage mode inside a vertical StackPanel`);
} else {
stackHeight += child._currentMeasure.height + child.paddingTopInPi... | <mask> this._rebuildLayout = true;
<mask> child._top.ignoreAdaptiveScaling = true;
<mask> }
<mask>
<mask> stackHeight += child._currentMeasure.height + child.paddingTopInPixels + child.paddingBottomInPixels;
<mask> } else {
<mas... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd0fd38bd8a371f2456c81ab8e9416110341bdb9 | gui/src/2D/controls/stackPanel.ts |
if (child._width.isPercentage) {
Tools.Warn(`Control (Name:${child.name}, UniqueId:${child.uniqueId}) is using width in percentage mode inside a horizontal StackPanel`);
} else {
stackWidth += child._currentMeasure.width + child.paddingLeftInPix... | <mask> this._rebuildLayout = true;
<mask> child._left.ignoreAdaptiveScaling = true;
<mask> }
<mask>
<mask> stackWidth += child._currentMeasure.width + child.paddingLeftInPixels + child.paddingRightInPixels;
<mask> }
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd0fd38bd8a371f2456c81ab8e9416110341bdb9 | gui/src/2D/controls/stackPanel.ts |
<TextLineComponent label="Unique ID" value={control.uniqueId.toString()} />
| <mask> <LineContainerComponent title="GENERAL">
<mask> <TextLineComponent label="Class" value={control.getClassName()} />
<mask> <SliderLineComponent label="Alpha" target={control} propertyName="alpha" minimum={0} maximum={1} step={0.01} onPropertyChangedObserv... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd0fd38bd8a371f2456c81ab8e9416110341bdb9 | inspector/src/components/actionTabs/tabs/propertyGrids/gui/commonControlPropertyGridComponent.tsx |
<mask> public CLIPPLANE = false;
<mask> public ALPHATEST = false;
<mask> public POINTSIZE = false;
<mask> public FOG = false;
<mask> public LIGHT0 = false;
<mask> public LIGHT1 = false;
<mask> public LIGHT2 = false;
<mask> public LIGHT3 = false;
<... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"re... | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts | |
public NUM_BONE_INFLUENCERS = 0;
| <mask> public UV1 = false;
<mask> public UV2 = false;
<mask> public VERTEXCOLOR = false;
<mask> public VERTEXALPHA = false;
<mask> public BONES = false;
<mask> public BONES4 = false;
<mask> public BonesPerMesh = 0;
<mask> public INSTANCES = false;
... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
this.rebuild();
| <mask> public INSTANCES = false;
<mask>
<mask> constructor() {
<mask> super();
<mask> this._keys = Object.keys(this);
<mask> }
<mask> }
<mask>
<mask> export class TerrainMaterial extends Material {
<mask> @serializeAsTexture()
</s> Updated Ter... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
@serialize()
public maxSimultaneousLights = 4;
| <mask>
<mask> @serialize()
<mask> public disableLighting = false;
<mask>
<mask> private _worldViewProjectionMatrix = Matrix.Zero();
<mask> private _renderId: number;
<mask>
<mask> private _defines = new TerrainMaterialDefines();
<mask> private _cachedD... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
<mask> @serialize()
<mask> public disableLighting = false;
<mask>
<mask> private _worldViewProjectionMatrix = Matrix.Zero();
<mask> private _scaledDiffuse = new Color3();
<mask> private _scaledSpecular = new Color3();
<mask> private _renderId: number;
<mask>
<m... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts | |
<mask> var needUVs = false;
<mask>
<mask> this._defines.reset();
<mask>
<mask> // Textures
<mask> if (scene.texturesEnabled) {
<mask> if (this.mixTexture && StandardMaterial.DiffuseTextureEnabled) {
<mask> if (!this.mixTexture... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts | |
// Lights
| <mask> if (scene.fogEnabled && mesh && mesh.applyFog && scene.fogMode !== Scene.FOGMODE_NONE && this.fogEnabled) {
<mask> this._defines.FOG = true;
<mask> }
<mask>
<mask> var lightIndex = 0;
<mask> if (scene.lightsEnabled && !this.disableLighting) {... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
needNormals = MaterialHelper.PrepareDefinesForLights(scene, mesh, this._defines, this.maxSimultaneousLights);
}
// Textures
if (scene.texturesEnabled) {
if (this.mixTexture && StandardMaterial.DiffuseTextureEnabled) {
... | <mask> }
<mask>
<mask> var lightIndex = 0;
<mask> if (scene.lightsEnabled && !this.disableLighting) {
<mask> for (var index = 0; index < scene.lights.length; index++) {
<mask> var light = scene.lights[index];
<mask>
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"re... | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
needUVs = true;
this._defines.DIFFUSE = true;
| <mask> type = "HEMILIGHT" + lightIndex;
<mask> } else if (light instanceof PointLight) {
<mask> type = "POINTLIGHT" + lightIndex;
<mask> } else {
<mask> type = "DIRLIGHT" + lightIndex;
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"re... | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
}
if ((this.bumpTexture1 || this.bumpTexture2 || this.bumpTexture3) && StandardMaterial.BumpTextureEnabled) {
needUVs = true;
needNormals = true;
this._defines.BUMP = true;
| <mask> this._defines["SHADOWPCF" + lightIndex] = true;
<mask> }
<mask> }
<mask> }
<mask>
<mask> lightIndex++;
<mask> if (lightIndex === maxSimultaneousLights)
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
this._defines.NUM_BONE_INFLUENCERS = mesh.numBoneInfluencers;
| <mask> this._defines.VERTEXALPHA = true;
<mask> }
<mask> }
<mask> if (mesh.useBones && mesh.computeBonesUsingShaders) {
<mask> this._defines.BONES = true;
<mask> this._defines.BonesPerMesh = (mesh.s... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
<mask> }
<mask> if (mesh.useBones && mesh.computeBonesUsingShaders) {
<mask> this._defines.BONES = true;
<mask> this._defines.BonesPerMesh = (mesh.skeleton.bones.length + 1);
<mask> this._defines.BONES4 = true;
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts | |
MaterialHelper.HandleFallbacksForShadows(this._defines, fallbacks, this.maxSimultaneousLights);
| <mask> if (this._defines.FOG) {
<mask> fallbacks.addFallback(1, "FOG");
<mask> }
<mask>
<mask> for (lightIndex = 0; lightIndex < maxSimultaneousLights; lightIndex++) {
<mask> if (!this._defines["LIGHT" + lightIndex]) {
<mask... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"ke... | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
if (this._defines.NUM_BONE_INFLUENCERS > 0) {
fallbacks.addCPUSkinningFallback(0, mesh);
| <mask> fallbacks.addFallback(0, "SHADOWVSM" + lightIndex);
<mask> }
<mask> }
<mask>
<mask> if (this._defines.BONES4) {
<mask> fallbacks.addFallback(0, "BONES4");
<mask> }
<mask>
<mask>... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
MaterialHelper.PrepareAttributesForBones(attribs, mesh, this._defines, fallbacks);
MaterialHelper.PrepareAttributesForInstances(attribs, this._defines);
| <mask> if (this._defines.VERTEXCOLOR) {
<mask> attribs.push(VertexBuffer.ColorKind);
<mask> }
<mask>
<mask> if (this._defines.BONES) {
<mask> attribs.push(VertexBuffer.MatricesIndicesKind);
<mask> attribs... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
var uniforms = ["world", "view", "viewProjection", "vEyePosition", "vLightsType", "vDiffuseColor", "vSpecularColor",
"vFogInfos", "vFogColor", "pointSize",
"vTextureInfos",
"mBones",
"vClipPlane", "textureMatrix",
... | <mask>
<mask> // Legacy browser patch
<mask> var shaderName = "terrain";
<mask> var join = this._defines.toString();
<mask> this._effect = scene.getEngine().createEffect(shaderName,
<mask> attribs, uniforms, samplers,
<mask> ... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bd954d302266b274e336f7a5cfa8104ef91d7f1e | materialsLibrary/materials/terrain/babylon.terrainMaterial.ts |
"doNotAppendNamespace": true,
"prependToNamespaceText": "declare module 'babylonjs' { export = BABYLON; }" | <mask> "path": "babylonjs/Debug",
<mask> "namespace": "BABYLON.Debug"
<mask> }
<mask> ],
<mask> "importsToRemove": [],
<mask> "classMap": {
<mask> "babylonjs": "BABYLON"
<mask>... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/config.json |
##EXPORT_PLACEHOLDER##
| <mask> let name = '##NAME_PLACEHOLDER##';
<mask> let shader = \`##SHADER_PLACEHOLDER##\`;
<mask>
<mask> Effect.##SHADERSTORE_PLACEHOLDER##[name] = shader;
<mask>
<mask> //export { shader, name };
<mask> `;
<mask>
<mask>
<mask> /**
<mask> * Get the shaders name from their path.
</s> Progressing on decla... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/helpers/gulp-processShaders.js |
tsContent = tsContent.replace('##EXPORT_PLACEHOLDER##', `export var ${shaderName} = { name, shader };`)
| <mask> tsContent = tsContent.replace('##INCLUDES_PLACEHOLDER##', includeText);
<mask> tsContent = tsContent.replace('##NAME_PLACEHOLDER##', shaderName);
<mask> tsContent = tsContent.replace('##SHADER_PLACEHOLDER##', fxData);
<mask> tsContent = tsContent.replace('##SHA... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/helpers/gulp-processShaders.js |
var cp = require('child_process');
| <mask> var webpack = require('webpack');
<mask> var webpackStream = require("webpack-stream");
<mask> var dtsBundle = require('dts-bundle');
<mask> var merge2 = require("merge2");
<mask> var path = require("path");
<mask>
<mask> // Gulp Helpers
</s> Progressing on declaration Files
Former-commit-id: 9ac081a0... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
var processAmdDeclarationToModule = require('../helpers/gulp-processAmdDeclarationToModule');
var processModuleDeclarationToNamespace = require('../helpers/gulp-processModuleDeclarationToNamespace');
| <mask>
<mask> // Gulp Helpers
<mask> var uncommentShaders = require('../helpers/gulp-removeShaderComments');
<mask> var processShaders = require("../helpers/gulp-processShaders");
<mask> var processDeclaration = require('../helpers/gulp-processTypescriptDeclaration');
<mask> var rmDir = require("../helpers/gulp-... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
var buildExternalLibrariesMultiEntry = function(libraries, settings, cb) {
// Convert Module to Namespace for globals
| <mask>
<mask> /**
<mask> * Build a single library (one of the material of mat lib) from a module (materialsLibrary for instance)
<mask> */
<mask> var buildExternalLibrary = function(library, settings, cb) {
<mask> const sequence = [];
<mask> var outputDirectory = config.build.outputDirectory + setting... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
wpConfig.entry = { };
wpConfig.output.filename = settings.isCore ? '[name].js' : '[name].min.js';
for (let library of settings.libraries) {
let name = library.output.replace(settings.isCore ? ".js" : ".min.js", "");
wpConfig.entry[name] = path.resolve(wpConfig.context, library.entry);
... | <mask> var outputDirectory = config.build.outputDirectory + settings.build.distOutputDirectory;
<mask>
<mask> // Webpack Config.
<mask> var wpConfig = require(settings.build.webpack);
<mask> wpConfig.entry = {
<mask> 'main': path.resolve(wpConfig.context, library.entry),
<mask> };
<... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
wpConfig.output.filename = settings.isCore ? '[name].max.js' : '[name].js';
//wpConfig.output.filename = library.maxOutput || wpConfig.output.filename.replace(".min", "");
| <mask>
<mask> // Generate unminified file.
<mask> wpConfig.mode = "development";
<mask> // Allow babylon.max.js and babylon.js
<mask> wpConfig.output.filename = library.maxOutput || wpConfig.output.filename.replace(".min", "");
<mask> let wpBuildMax = webpackStream(wpConfig, webpack);
<mask>... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
let library = libraries[0];
| <mask>
<mask> return merge2(sequence)
<mask> .on("end", function() {
<mask> // TODO. Generate all d.ts
<mask> if (!library.preventLoadLibrary) {
<mask> let fileLocation = path.join(outputDirectory, settings.build.processDeclaration.filename);
<mask> ... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
<mask> return merge2(sequence)
<mask> .on("end", function() {
<mask> // TODO. Generate all d.ts
<mask> if (!library.preventLoadLibrary) {
<mask> dtsBundle.bundle(settings.build.dtsBundle);
<mask>
<mask> let fileLocation = path.join(outputDirect... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js | |
// Generate DTS the Dts Bundle way...
// dtsBundle.bundle(settings.build.dtsBundle);
let srcDirectory = settings.build.srcDirectory;
let depthCount = srcDirectory.match(/\//g).length - srcDirectory.match(/\.\.\//g).length;
let tempDir... | <mask> if (!library.preventLoadLibrary) {
<mask> dtsBundle.bundle(settings.build.dtsBundle);
<mask>
<mask> let fileLocation = path.join(outputDirectory, settings.build.processDeclaration.filename);
<mask> processDeclaration(fileLocation, settings.build.p... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
var shaders = function() { return buildShaders(settings); };
var build = function(cb) { return buildExternalLibrariesMultiEntry(settings.libraries, settings, cb) };
| <mask> rmDir(settings.build.dtsBundle.baseDir);
<mask>
<mask> // Creates the required tasks.
<mask> var tasks = [];
<mask> for (let library of settings.libraries) {
<mask> var shaders = function() { return buildShaders(settings); };
<mask> var build = function(cb) { return buildE... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
tasks.push(shaders, build);
| <mask> for (let library of settings.libraries) {
<mask> var shaders = function() { return buildShaders(settings); };
<mask> var build = function(cb) { return buildExternalLibrary(library, settings, cb) };
<mask>
<mask> tasks.push(shaders, build);
<mask> }
<mask>
<mask> retu... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-libraries.js |
var processDeclaration = require('../helpers/gulp-processModuleDeclarationToNamespace');
| <mask> var path = require("path");
<mask> var rename = require("gulp-rename");
<mask>
<mask> // Gulp Helpers
<mask> var processDeclaration = require('../helpers/gulp-processTypescriptDeclaration');
<mask> var addModuleExports = require("../helpers/gulp-addModuleExports");
<mask>
<mask> // Import Build Config
... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | Tools/Gulp/tasks/gulpTasks-viewerLibraries.js |
import { Scene, SceneLoader, ISceneLoaderPlugin, ISceneLoaderPluginExtensions, Nullable, AbstractMesh, IParticleSystem, Skeleton, Mesh, Tools, AssetContainer, VertexBuffer } from "babylonjs";
import "babylonjs/Helpers/sceneHelpers"; | <mask> import { SceneLoader, ISceneLoaderPlugin, ISceneLoaderPluginExtensions, Scene, Nullable, AbstractMesh, IParticleSystem, Skeleton, Mesh, Tools, AssetContainer, VertexBuffer } from "babylonjs";
<mask>
<mask> /**
<mask> * STL file type loader.
<mask> * This is a babylon scene loader plugin.
<mask> */
</s... | [
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | loaders/src/STL/stlFileLoader.ts |
scene.createDefaultLight(); | <mask>
<mask> if (result) {
<mask> scene.createDefaultCameraOrLight();
<mask> }
<mask>
<mask> return result;
</s> Progressing on declaration Files
Former-commit-id: 9ac081a0c87c51a80b06128bd2722f30b7d4692a </s> remove dtsBundle.bundle(settings.build.dtsBund... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | loaders/src/STL/stlFileLoader.ts |
(<any>babylonAnimationTarget.animations).push(babylonAnimation);
| <mask> const babylonBones = targetNode._babylonBones;
<mask> if (babylonBones) {
<mask> const babylonAnimationTargets = [babylonTransformNode, ...babylonBones];
<mask> for (const babylonAnimationTarget of babylonAnimationTargets... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | loaders/src/glTF/2.0/glTFLoader.ts |
"../../dist/preview release/babylon.module.d.ts",
| <mask> "baseUrl": "./src/",
<mask> "rootDir": "./",
<mask> "paths": {
<mask> "babylonjs": [
<mask> "../../dist/preview release/babylon.d.ts",
<mask> ],
<mask> "babylonjs-gltf2interface": [
<mask> "../../dist/preview release/glTF2Interface/b... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | loaders/tsconfig.json |
externals: [
{
babylonjs: {
root: "BABYLON",
commonjs: "babylonjs",
commonjs2: "babylonjs",
amd: "babylonjs"
}
},
/^babylonjs.*$/i
],
| <mask> },
<mask> resolve: {
<mask> extensions: [".js", '.ts']
<mask> },
<mask> externals: {
<mask> babylonjs: {
<mask> root: "BABYLON",
<mask> commonjs: "babylonjs",
<mask> commonjs2: "babylonjs",
<mask> amd: "babylonjs"
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | loaders/webpack.config.js |
Effect.ShadersStore[name + "VertexShader"] = this.VertexShader | <mask> try { fn_afterBind(m, e); }
<mask> catch (e) { }
<mask> };
<mask>
<mask> BABYLON.Effect.ShadersStore[name + "VertexShader"] = this.VertexShader
<mask> .replace('#define CUSTOM_VERTEX_BEGIN', (this.CustomParts.Vertex_Begin ? this.CustomParts.Vertex_Begin ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/custom/customMaterial.ts |
Effect.ShadersStore[name + "PixelShader"] = this.FragmentShader | <mask> .replace('#define CUSTOM_VERTEX_UPDATE_NORMAL', (this.CustomParts.Vertex_Before_NormalUpdated ? this.CustomParts.Vertex_Before_NormalUpdated : ""));
<mask>
<mask> // #define CUSTOM_VERTEX_MAIN_END
<mask>
<mask> BABYLON.Effect.ShadersStore[name + "PixelShader"] = this.Fragme... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/custom/customMaterial.ts |
this.FragmentShader = Effect.ShadersStore["defaultPixelShader"];
this.VertexShader = Effect.ShadersStore["defaultVertexShader"]; | <mask> super(name, scene);
<mask> this.CustomParts = new ShaderSpecialParts();
<mask> this.customShaderNameResolve = this.Builder;
<mask>
<mask> this.FragmentShader = BABYLON.Effect.ShadersStore["defaultPixelShader"];
<mask> this.VertexShader = BABYLON.Effect.ShadersStore[... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/custom/customMaterial.ts |
import { PushMaterial, MaterialDefines, serializeAsColor3, serializeAsTexture, expandToProperty, Color3, serialize, Vector3, Vector4, Scene, AbstractMesh, SubMesh, MaterialHelper, VertexBuffer, Matrix, Mesh, SerializationHelper, BaseTexture, StandardMaterial } from "babylonjs";
| <mask> import { MaterialDefines, serializeAsColor3, serializeAsTexture, expandToProperty, Color3, serialize, Vector3, Vector4, Scene, AbstractMesh, SubMesh, MaterialHelper, VertexBuffer, Matrix, Mesh, SerializationHelper, BaseTexture, StandardMaterial } from "babylonjs";
<mask>
<mask> import "./grid.fragment";
<ma... | [
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/grid/gridMaterial.ts |
export class GridMaterial extends PushMaterial {
| <mask> /**
<mask> * The grid materials allows you to wrap any shape with a grid.
<mask> * Colors are customizable.
<mask> */
<mask> export class GridMaterial extends BABYLON.PushMaterial {
<mask>
<mask> /**
<mask> * Main color of the grid (e.g. between lines)
<mask> */
<mask> @serializeA... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/grid/gridMaterial.ts |
import { MaterialDefines, PushMaterial, IShadowLight, Scene, Nullable, BaseTexture, AbstractMesh, SubMesh, MaterialHelper, EffectFallbacks, VertexBuffer, EffectCreationOptions, Matrix, Mesh, SerializationHelper, Color3 } from "babylonjs";
| <mask> import { MaterialDefines, PushMaterial, IShadowLight, Scene, Nullable, BaseTexture, AbstractMesh, SubMesh, MaterialHelper, EffectFallbacks, VertexBuffer, EffectCreationOptions, Matrix, Mesh, SerializationHelper } from "babylonjs";
<mask>
<mask> import "./shadowOnly.fragment";
<mask> import "./shadowOnly.ver... | [
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/BabylonJS/Babylon.js/commit/bde7ad1724a5a29346ea4709dea0ebfba103c4d7 | materialsLibrary/src/shadowOnly/shadowOnlyMaterial.ts |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.