@babylonjs/lite-compat 1.31.0-preview → 1.31.1-preview
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -2
- package/index.d.ts +308 -28
- package/index.js +1103 -83
- package/index.js.map +1 -1
- package/meshes-Fu955h5M.js.map +1 -1
- package/navigation.d.ts +69 -16
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -118,7 +118,8 @@ overloads within a supported area may still be absent.
|
|
|
118
118
|
| Feature area | Status | Notes |
|
|
119
119
|
| ----------------------------------------------------------------------------------------------------------------------------------------- | :----: | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
120
120
|
| Math (`Vector*`, `Color*`, `Quaternion`, `Matrix`, `Plane`, `Ray`, `Frustum`, `Scalar`, `Axis`/`Space`, color temperature/white balance) | ✅ | `Angle` / `Curve3` / `Path3D` partial |
|
|
121
|
-
| Engine (`WebGPUEngine`, `Engine`, `ThinEngine`, `NullEngine`) | ⚡ | async startup + render loop; `currentSampleCount` reports the active surface's MSAA count; `beginFrame`/`endFrame`, engine-wide alpha-to-coverage, and manual `scene.render()` unsupported
|
|
121
|
+
| Engine (`WebGPUEngine`, `Engine`, `ThinEngine`, `NullEngine`) | ⚡ | async startup + render loop; `currentSampleCount` reports the active surface's MSAA count; `beginFrame`/`endFrame`, occlusion queries, engine-wide alpha-to-coverage, and manual `scene.render()` unsupported |
|
|
122
|
+
| Compute + GPU buffers (`ComputeShader`, `StorageBuffer`, `UniformBuffer`) | ⚡ | WGSL compute, direct/indirect dispatch, storage buffers, and compute-oriented std140 uniform buffers forward to Lite; shader registries/preprocessing, texture bindings, in-frame immediate dispatch, and Effect-oriented UBO methods remain unsupported |
|
|
122
123
|
| Scene (clear color, cameras/lights, fog, environment, observables, ready state) | ⚡ | sync `scene.pick` forwards to Lite's CPU/AABB picker; triangle-level positions, normals, and UVs still require async `GPUPicker`; `scene.meshes` + `getMeshBy*`/`getNodeBy*` enumerate every mesh via a canonical wrapper registry; exposure/contrast/tone mapping are forwarded, while white balance and fluid rendering throw because Lite lacks their cross-cutting shader/render-pass subsystems |
|
|
123
124
|
| Cameras (`ArcRotateCamera`, `FreeCamera`/`Universal`/`Target`, `FollowCamera`, `GeospatialCamera`) | ✅ | arc controls include pointer, wheel, touch, and BJS-default Arrow-key input; orthographic bounds and projection-mode switching forward to Lite; fully unconfigured orthographic extents use Lite's `halfHeight` + aspect-ratio derivation rather than Babylon.js render dimensions; XR / device-orientation / stereoscopic rigs unsupported |
|
|
124
125
|
| Lights (`Hemispheric`, `Directional`, `Point`, `Spot`) | ✅ | `ClusteredLightContainer` clusters point lights (⚡ partial); `RectAreaLight` unsupported |
|
|
@@ -128,7 +129,7 @@ overloads within a supported area may still be absent.
|
|
|
128
129
|
| Gizmos (position/rotation/scale/bounding-box/light/camera + `GizmoManager`) | ⚡ | over Lite gizmo suite; `isEnabled` toggles per-axis interactivity (display-only when disabled) |
|
|
129
130
|
| Materials (`StandardMaterial`, `PBRMaterial`, metallic-rough / spec-gloss, `NodeMaterial`) | ⚡ | `clone(name)` shares textures with its own renderable; fixed-slot custom WGSL `MaterialPluginBase` injection is supported (`#include`, regex replacement, and custom UBO/sampler hooks are not), while `DitheredTileFadeMaterialPlugin`, GLSL `ShaderMaterial`, `MultiMaterial`, `BackgroundMaterial`, and `OpenPBRMaterial` remain unsupported |
|
|
130
131
|
| Textures (`Texture`, `RawTexture`, `RawTexture2DArray`, `RawTexture3D`, `DynamicTexture`, `HtmlTexture`, `CubeTexture`, `HDRCubeTexture`) | ⚡ | `HDRCubeTexture` routes to native `loadHdrEnvironment`; `RawTexture2DArray` supports raw bytes, image sources/URLs, and single-file KTX2 arrays; `HtmlTexture` forwards native Lite DOM capture/update; `RenderTargetTexture` / `MirrorTexture` unsupported |
|
|
131
|
-
| Animation (keyframe `Animation`, easing, `Animatable`, `AnimationGroup` incl. weighted/additive blend) | ⚡ |
|
|
132
|
+
| Animation (keyframe `Animation`, easing, `Animatable`, `AnimationGroup` incl. weighted/additive blend) | ⚡ | All standard easing classes, including `PowerEase` / `BezierCurveEase`, reuse Lite's native functional curves; `beginAnimation` / `beginDirectAnimation` delegate supported float/vector/quaternion tracks to Lite property animation; unsupported tracks use an explicit compat evaluator; structural groups remain compat-owned; loaded glTF skeletal blending supported |
|
|
132
133
|
| Morph targets (`MorphTarget` / `MorphTargetManager`) | ✅ | over Lite morph targets |
|
|
133
134
|
| Sprites (`SpriteManager` / `Sprite`) | ⚡ | camera-facing billboards; `SpriteMap` / packed atlas unsupported |
|
|
134
135
|
| Behaviors / Actions (`AutoRotation`, `Framing`, `ActionManager`, conditions) | ⚡ | `ActionManager` is manual-dispatch; drag / six-DoF / XR-oriented mesh behaviors throw |
|
package/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { AnisotropyProps } from '@babylonjs/lite';
|
|
|
3
3
|
import { AssetContainer as AssetContainer_2 } from '@babylonjs/lite';
|
|
4
4
|
import { AudioGraphHost } from '@babylonjs/lite';
|
|
5
5
|
import { ClearCoatProps } from '@babylonjs/lite';
|
|
6
|
+
import { ComputeShader as ComputeShader_2 } from '@babylonjs/lite';
|
|
6
7
|
import { EngineContext } from '@babylonjs/lite';
|
|
7
8
|
import { EngineOptions } from '@babylonjs/lite';
|
|
8
9
|
import { IridescenceProps } from '@babylonjs/lite';
|
|
@@ -17,8 +18,10 @@ import { PhysicsWorld } from '@babylonjs/lite';
|
|
|
17
18
|
import { RenderCanvas } from '@babylonjs/lite';
|
|
18
19
|
import { SceneNode } from '@babylonjs/lite';
|
|
19
20
|
import { SheenProps } from '@babylonjs/lite';
|
|
21
|
+
import { StorageBuffer as StorageBuffer_2 } from '@babylonjs/lite';
|
|
20
22
|
import { Texture2D } from '@babylonjs/lite';
|
|
21
23
|
import { Texture2DArray } from '@babylonjs/lite';
|
|
24
|
+
import { UniformBuffer as UniformBuffer_2 } from '@babylonjs/lite';
|
|
22
25
|
|
|
23
26
|
/** Base class for an asset-loading task. Subclasses implement {@link runAsync}. */
|
|
24
27
|
export declare abstract class AbstractAssetTask {
|
|
@@ -217,6 +220,11 @@ export declare abstract class AbstractEngine {
|
|
|
217
220
|
* scoped API cannot reproduce the engine-wide state without a pipeline-owner lifecycle policy.
|
|
218
221
|
*/
|
|
219
222
|
setAlphaToCoverage(_enable: boolean): never;
|
|
223
|
+
/**
|
|
224
|
+
* Babylon.js `engine.isOcclusionQueryVisible(query)` — Lite does not expose
|
|
225
|
+
* occlusion-query allocation, render-pass encoding, or asynchronous result state.
|
|
226
|
+
*/
|
|
227
|
+
isOcclusionQueryVisible(_query: unknown): never;
|
|
220
228
|
/**
|
|
221
229
|
* Babylon.js `engine.updateTextureArrayLayerFromImageSource(texture, source, layer, invertY, premultiplyAlpha)`
|
|
222
230
|
* — the engine extension that uploads a decoded image source into one layer of a 2D array
|
|
@@ -610,9 +618,8 @@ export declare class Angle {
|
|
|
610
618
|
}
|
|
611
619
|
|
|
612
620
|
/**
|
|
613
|
-
* Babylon.js `Animatable`
|
|
614
|
-
*
|
|
615
|
-
* the target's (dotted) property path.
|
|
621
|
+
* Babylon.js `Animatable` facade. Supported direct-animation tracks delegate to a
|
|
622
|
+
* native Lite property group; unsupported tracks retain the compat CPU evaluator.
|
|
616
623
|
*/
|
|
617
624
|
declare class Animatable_2 {
|
|
618
625
|
private readonly _target;
|
|
@@ -620,16 +627,26 @@ declare class Animatable_2 {
|
|
|
620
627
|
private readonly _from;
|
|
621
628
|
private readonly _to;
|
|
622
629
|
private readonly _loop;
|
|
623
|
-
masterFrame: number;
|
|
624
|
-
speedRatio: number;
|
|
630
|
+
masterFrame: number;
|
|
625
631
|
private _speedRatio;
|
|
626
632
|
private _paused;
|
|
627
633
|
private _stopped;
|
|
628
|
-
constructor(_target: unknown, _animations: Animation_2[], _from: number, _to: number, _loop: boolean, speedRatio: number);
|
|
629
634
|
goToFrame(frame: number): void;
|
|
635
|
+
private readonly _nativeManager;
|
|
636
|
+
private readonly _fallbackAnimations;
|
|
637
|
+
private readonly _fallbackFrames;
|
|
638
|
+
private readonly _fallbackElapsedFrames;
|
|
639
|
+
private readonly _fallbackRepeatCounts;
|
|
640
|
+
private readonly _completedFallbackAnimations;
|
|
641
|
+
constructor(target: unknown, animations: Animation_2[], from: number, to: number, loop: boolean, speedRatio: number);
|
|
630
642
|
get speedRatio(): number;
|
|
643
|
+
set speedRatio(value: number);
|
|
631
644
|
goToFrame(frame: number): void;
|
|
632
645
|
pause(): void;
|
|
633
646
|
restart(): void;
|
|
634
647
|
stop(): void;
|
|
635
648
|
get animationStarted(): boolean;
|
|
636
|
-
private
|
|
649
|
+
private _applyFallback;
|
|
650
|
+
private _advanceFallback;
|
|
651
|
+
private _resetFallbackAnimation;
|
|
652
|
+
private _attachLite;
|
|
653
|
+
private _detachLite;
|
|
637
654
|
}
|
|
638
655
|
export { Animatable_2 as Animatable }
|
|
639
656
|
|
|
@@ -644,16 +661,29 @@ declare class Animation_2 {
|
|
|
644
661
|
static readonly ANIMATIONTYPE_QUATERNION: 2;
|
|
645
662
|
static readonly ANIMATIONTYPE_MATRIX: 3;
|
|
646
663
|
static readonly ANIMATIONTYPE_COLOR3: 4;
|
|
664
|
+
static readonly ANIMATIONTYPE_VECTOR2: 5;
|
|
665
|
+
static readonly ANIMATIONTYPE_COLOR4: 6;
|
|
647
666
|
static readonly ANIMATIONLOOPMODE_RELATIVE: 0;
|
|
648
667
|
static readonly ANIMATIONLOOPMODE_CYCLE: 1;
|
|
649
668
|
static readonly ANIMATIONLOOPMODE_CONSTANT: 2;
|
|
650
669
|
private _keys;
|
|
670
|
+
private _easingFunction;
|
|
651
671
|
constructor(name: string, targetProperty: string, framePerSecond: number, dataType?: number, loopMode?: number);
|
|
652
672
|
setKeys(keys: IAnimationKey[]): void;
|
|
653
673
|
getKeys(): IAnimationKey[];
|
|
654
674
|
getHighestFrame(): number;
|
|
655
|
-
/**
|
|
656
|
-
|
|
675
|
+
/**
|
|
676
|
+
* Assigns the easing function used to transform each non-STEP segment's normalized progress.
|
|
677
|
+
* @param easingFunction - A Babylon.js-shaped easing object, or `null` to restore linear progress.
|
|
678
|
+
*/
|
|
679
|
+
setEasingFunction(easingFunction: IEasingFunction | null): void;
|
|
680
|
+
/**
|
|
681
|
+
* Gets the easing function currently assigned to this animation.
|
|
682
|
+
* @returns The assigned easing object, or `null` when interpolation uses linear progress.
|
|
683
|
+
*/
|
|
684
|
+
getEasingFunction(): IEasingFunction | null;
|
|
685
|
+
/** Evaluate the animated value at `frame`, clamped to the key range. */
|
|
686
|
+
evaluate(frame: number): AnimationValue;
|
|
657
687
|
/** Babylon.js helper: build a one-shot float animation between two values. */
|
|
658
688
|
static CreateAndStartAnimation(name: string, _target: unknown, targetProperty: string, framePerSecond: number, totalFrame: number, from: number, to: number): Animation_2;
|
|
659
689
|
}
|
|
@@ -762,6 +792,8 @@ export declare const AnimationTypes: {
|
|
|
762
792
|
readonly ANIMATIONTYPE_COLOR4: 6;
|
|
763
793
|
};
|
|
764
794
|
|
|
795
|
+
export declare type AnimationValue = number | number[] | IAnimationVectorValue;
|
|
796
|
+
|
|
765
797
|
export declare interface AppendOptions extends ISceneLoaderOptions {
|
|
766
798
|
}
|
|
767
799
|
|
|
@@ -984,7 +1016,7 @@ export declare class AxisScaleGizmo extends GizmoBase {
|
|
|
984
1016
|
private _attached;
|
|
985
1017
|
}
|
|
986
1018
|
|
|
987
1019
|
export declare class BackEase extends EasingFunction {
|
|
988
|
-
|
|
1020
|
+
amplitude: number;
|
|
989
1021
|
constructor(amplitude?: number);
|
|
990
1022
|
easeInCore(gradient: number): number;
|
|
991
1023
|
}
|
|
@@ -1020,6 +1052,18 @@ export declare interface Behavior<T> {
|
|
|
1020
1052
|
detach(): void;
|
|
1021
1053
|
}
|
|
1022
1054
|
|
|
1055
|
+
/**
|
|
1056
|
+
* Babylon.js-compatible cubic Bezier easing class.
|
|
1057
|
+
*/
|
|
1058
|
+
export declare class BezierCurveEase extends EasingFunction {
|
|
1059
|
+
x1: number;
|
|
1060
|
+
y1: number;
|
|
1061
|
+
x2: number;
|
|
1062
|
+
y2: number;
|
|
1063
|
+
constructor(x1?: number, y1?: number, x2?: number, y2?: number);
|
|
1064
|
+
easeInCore(gradient: number): number;
|
|
1065
|
+
}
|
|
1066
|
+
|
|
1023
1067
|
export declare const BlackAndWhitePostProcess: new () => never;
|
|
1024
1068
|
|
|
1025
1069
|
export declare const BloomEffect: new () => never;
|
|
@@ -1039,8 +1083,8 @@ export declare class Bone {
|
|
|
1039
1083
|
}
|
|
1040
1084
|
|
|
1041
1085
|
export declare class BounceEase extends EasingFunction {
|
|
1042
|
-
|
|
1043
|
-
|
|
1086
|
+
bounces: number;
|
|
1087
|
+
bounciness: number;
|
|
1044
1088
|
constructor(bounces?: number, bounciness?: number);
|
|
1045
1089
|
easeInCore(gradient: number): number;
|
|
1046
1090
|
}
|
|
@@ -1349,6 +1393,12 @@ export declare class Color3 {
|
|
|
1349
1393
|
static Lerp(start: Color3, end: Color3, amount: number): Color3;
|
|
1350
1394
|
}
|
|
1351
1395
|
|
|
1396
|
+
declare interface Color3Like {
|
|
1397
|
+
readonly r: number;
|
|
1398
|
+
readonly g: number;
|
|
1399
|
+
readonly b: number;
|
|
1400
|
+
}
|
|
1401
|
+
|
|
1352
1402
|
export declare class Color4 {
|
|
1353
1403
|
r: number;
|
|
1354
1404
|
g: number;
|
|
@@ -1366,6 +1416,10 @@ export declare class Color4 {
|
|
|
1366
1416
|
static FromInts(r: number, g: number, b: number, a: number): Color4;
|
|
1367
1417
|
}
|
|
1368
1418
|
|
|
1419
|
+
declare interface Color4Like extends Color3Like {
|
|
1420
|
+
readonly a: number;
|
|
1421
|
+
}
|
|
1422
|
+
|
|
1369
1423
|
/** An RGBA color bound to a [0, 1] position (Babylon.js `ColorGradient`). */
|
|
1370
1424
|
export declare class ColorGradient {
|
|
1371
1425
|
gradient: number;
|
|
@@ -1382,9 +1436,66 @@ export declare function CompleteGreasedLineColorTable(..._args: unknown[]): neve
|
|
|
1382
1436
|
|
|
1383
1437
|
export declare function CompleteGreasedLineWidthTable(..._args: unknown[]): never;
|
|
1384
1438
|
|
|
1439
|
+
export declare interface ComputeBindingLocation {
|
|
1440
|
+
group: number;
|
|
1441
|
+
binding: number;
|
|
1442
|
+
}
|
|
1443
|
+
|
|
1444
|
+
export declare type ComputeBindingMapping = Record<string, ComputeBindingLocation>;
|
|
1445
|
+
|
|
1446
|
+
declare type ComputeEffect = ComputeShader_2;
|
|
1447
|
+
|
|
1385
1448
|
/** Babylon.js `ComputeOverlayCssTransform` — HTML overlay interaction is unsupported by the compat layer. */
|
|
1386
1449
|
export declare function ComputeOverlayCssTransform(): never;
|
|
1387
1450
|
|
|
1451
|
+
/** Babylon.js ComputeShader adapted to Lite's public buffer-backed compute graph. */
|
|
1452
|
+
export declare class ComputeShader {
|
|
1453
|
+
private readonly _engine;
|
|
1454
|
+
private readonly _shaderPath;
|
|
1455
|
+
static readonly Parse: typeof ComputeShaderParse;
|
|
1456
|
+
readonly uniqueId: number;
|
|
1457
|
+
name: string;
|
|
1458
|
+
fastMode: boolean;
|
|
1459
|
+
onCompiled: ((effect: ComputeEffect) => void) | null;
|
|
1460
|
+
onError: ((effect: ComputeEffect, errors: string) => void) | null;
|
|
1461
|
+
readonly gpuTimeInFrame: undefined;
|
|
1462
|
+
triggerContextRebuild: boolean;
|
|
1463
|
+
private readonly _source;
|
|
1464
|
+
private readonly _bindings;
|
|
1465
|
+
private _shader;
|
|
1466
|
+
private _bindingSet;
|
|
1467
|
+
private _bindingsDirty;
|
|
1468
|
+
private _shaderDirty;
|
|
1469
|
+
private _compiled;
|
|
1470
|
+
constructor(name: string, _engine: AbstractEngine, _shaderPath: IComputeShaderPath | string, options?: Partial<IComputeShaderOptions>);
|
|
1471
|
+
private readonly _options;
|
|
1472
|
+
get options(): IComputeShaderOptions;
|
|
1473
|
+
get shaderPath(): string | IComputeShaderPath;
|
|
1474
|
+
getClassName(): string;
|
|
1475
|
+
setTexture(_name: string, _texture: BaseTexture, _bindSampler?: boolean): never;
|
|
1476
|
+
setInternalTexture(_name: string, _texture: unknown): never;
|
|
1477
|
+
setStorageTexture(_name: string, _texture: BaseTexture): never;
|
|
1478
|
+
setExternalTexture(_name: string, _texture: unknown): never;
|
|
1479
|
+
setVideoTexture(_name: string, _texture: unknown): false;
|
|
1480
|
+
setUniformBuffer(name: string, buffer: UniformBuffer | UniformBuffer_2): void;
|
|
1481
|
+
setStorageBuffer(name: string, buffer: StorageBuffer | StorageBuffer_2): void;
|
|
1482
|
+
setTextureSampler(_name: string, _sampler: unknown): never;
|
|
1483
|
+
isReady(): boolean;
|
|
1484
|
+
dispatch(x: number, y?: number, z?: number): boolean;
|
|
1485
|
+
dispatchIndirect(buffer: StorageBuffer | StorageBuffer_2, offset?: number): boolean;
|
|
1486
|
+
dispatchWhenReady(x: number, y?: number, z?: number, delay?: number): Promise<void>;
|
|
1487
|
+
serialize(): Record<string, unknown>;
|
|
1488
|
+
private _createGraph;
|
|
1489
|
+
private _createShader;
|
|
1490
|
+
private _createBindingSet;
|
|
1491
|
+
private _submit;
|
|
1492
|
+
private _invalidateBindings;
|
|
1493
|
+
}
|
|
1494
|
+
|
|
1495
|
+
export declare function ComputeShaderParse(source: Record<string, unknown>, scene: {
|
|
1496
|
+
getEngine(): AbstractEngine;
|
|
1497
|
+
}, _rootUrl: string): ComputeShader;
|
|
1498
|
+
|
|
1388
1499
|
/** Base class for action conditions. */
|
|
1389
1500
|
export declare abstract class Condition {
|
|
1390
1501
|
abstract isValid(): boolean;
|
|
@@ -1417,6 +1528,14 @@ export declare const Constants: {
|
|
|
1417
1528
|
readonly TEXTURE_TRILINEAR_SAMPLINGMODE: 3;
|
|
1418
1529
|
readonly TEXTUREFORMAT_RGBA: 5;
|
|
1419
1530
|
readonly TEXTURETYPE_UNSIGNED_BYTE: 0;
|
|
1531
|
+
readonly BUFFER_CREATIONFLAG_READ: 1;
|
|
1532
|
+
readonly BUFFER_CREATIONFLAG_WRITE: 2;
|
|
1533
|
+
readonly BUFFER_CREATIONFLAG_READWRITE: 3;
|
|
1534
|
+
readonly BUFFER_CREATIONFLAG_UNIFORM: 4;
|
|
1535
|
+
readonly BUFFER_CREATIONFLAG_VERTEX: 8;
|
|
1536
|
+
readonly BUFFER_CREATIONFLAG_INDEX: 16;
|
|
1537
|
+
readonly BUFFER_CREATIONFLAG_STORAGE: 32;
|
|
1538
|
+
readonly BUFFER_CREATIONFLAG_INDIRECT: 64;
|
|
1420
1539
|
};
|
|
1421
1540
|
|
|
1422
1541
|
/** Babylon.js `CreateAudioBusAsync`. */
|
|
@@ -1634,6 +1753,8 @@ declare interface DashedLinesBuilderOptions {
|
|
|
1634
1753
|
material?: unknown;
|
|
1635
1754
|
}
|
|
1636
1755
|
|
|
1756
|
+
export declare type DataArray = number[] | ArrayBufferLike | ArrayBufferView;
|
|
1757
|
+
|
|
1637
1758
|
declare interface DefaultEnvironmentOptions {
|
|
1638
1759
|
createSkybox?: boolean;
|
|
1639
1760
|
createGround?: boolean;
|
|
@@ -1749,7 +1870,7 @@ export declare class DynamicTexture extends BaseTexture {
|
|
|
1749
1870
|
whenReadyAsync(): Promise<void>;
|
|
1750
1871
|
}
|
|
1751
1872
|
|
|
1752
|
-
export declare abstract class EasingFunction {
|
|
1873
|
+
export declare abstract class EasingFunction implements IEasingFunction {
|
|
1753
1874
|
static readonly EASINGMODE_EASEIN = 0;
|
|
1754
1875
|
static readonly EASINGMODE_EASEOUT = 1;
|
|
1755
1876
|
static readonly EASINGMODE_EASEINOUT = 2;
|
|
@@ -1762,10 +1883,10 @@ export declare abstract class EasingFunction {
|
|
|
1762
1883
|
}
|
|
1763
1884
|
|
|
1764
1885
|
/**
|
|
1765
|
-
* Babylon.js-compatible easing functions
|
|
1886
|
+
* Babylon.js-compatible easing functions over Babylon Lite's functional curves.
|
|
1766
1887
|
*
|
|
1767
|
-
* These
|
|
1768
|
-
*
|
|
1888
|
+
* These retain Babylon.js's class hierarchy and easing modes for porting while
|
|
1889
|
+
* delegating curve math to tree-shakable native Lite functions.
|
|
1769
1890
|
*/
|
|
1770
1891
|
export declare const EASINGMODE_EASEIN = 0;
|
|
1771
1892
|
|
|
@@ -1782,8 +1903,8 @@ export declare class EffectLayer {
|
|
|
1782
1903
|
}
|
|
1783
1904
|
|
|
1784
1905
|
export declare class ElasticEase extends EasingFunction {
|
|
1785
|
-
|
|
1786
|
-
|
|
1906
|
+
oscillations: number;
|
|
1907
|
+
springiness: number;
|
|
1787
1908
|
constructor(oscillations?: number, springiness?: number);
|
|
1788
1909
|
easeInCore(gradient: number): number;
|
|
1789
1910
|
}
|
|
@@ -1808,7 +1929,7 @@ export declare class ExecuteCodeAction extends Action {
|
|
|
1808
1929
|
}
|
|
1809
1930
|
|
|
1810
1931
|
export declare class ExponentialEase extends EasingFunction {
|
|
1811
|
-
|
|
1932
|
+
exponent: number;
|
|
1812
1933
|
constructor(exponent?: number);
|
|
1813
1934
|
easeInCore(gradient: number): number;
|
|
1814
1935
|
}
|
|
@@ -1943,6 +2064,8 @@ export declare interface FBXLoaderWarning {
|
|
|
1943
2064
|
|
|
1944
2065
|
export declare type FBXNormalMapCoordinateSystem = "y-up" | "y-down";
|
|
1945
2066
|
|
|
2067
|
+
declare type FloatArray = number[] | Float32Array;
|
|
2068
|
+
|
|
1946
2069
|
export declare enum FlowGraphValidationSeverity {
|
|
1947
2070
|
Error = 0,
|
|
1948
2071
|
Warning = 1
|
|
@@ -2610,11 +2733,21 @@ export declare interface IAbstractSoundOptions extends Partial<IVolumeAudioOptio
|
|
|
2610
2733
|
|
|
2611
2734
|
export declare interface IAnimationKey {
|
|
2612
2735
|
frame: number;
|
|
2613
|
-
value:
|
|
2736
|
+
value: AnimationValue;
|
|
2614
2737
|
/** Babylon.js per-key interpolation hint (`AnimationKeyInterpolation`). */
|
|
2615
2738
|
interpolation?: number;
|
|
2616
2739
|
}
|
|
2617
2740
|
|
|
2741
|
+
/** Structural vector/quaternion value accepted by Babylon.js animation keys. */
|
|
2742
|
+
export declare interface IAnimationVectorValue {
|
|
2743
|
+
readonly x: number;
|
|
2744
|
+
readonly y: number;
|
|
2745
|
+
readonly z?: number;
|
|
2746
|
+
readonly w?: number;
|
|
2747
|
+
clone(): IAnimationVectorValue;
|
|
2748
|
+
asArray(): number[];
|
|
2749
|
+
}
|
|
2750
|
+
|
|
2618
2751
|
/** Babylon.js `IAudioAnalyzerOptions`. */
|
|
2619
2752
|
export declare interface IAudioAnalyzerOptions {
|
|
2620
2753
|
/** Build the analyzer immediately. Defaults to `false`. */
|
|
@@ -2668,6 +2801,20 @@ export declare interface ICharacterControllerCollisionEvent {
|
|
|
2668
2801
|
impulsePosition: Vector3;
|
|
2669
2802
|
}
|
|
2670
2803
|
|
|
2804
|
+
export declare interface IComputeShaderOptions {
|
|
2805
|
+
bindingsMapping: ComputeBindingMapping;
|
|
2806
|
+
defines?: string[];
|
|
2807
|
+
entryPoint?: string;
|
|
2808
|
+
processFinalCode?: ((code: string) => string) | null;
|
|
2809
|
+
useExplicitComputePipelineLayout?: boolean;
|
|
2810
|
+
}
|
|
2811
|
+
|
|
2812
|
+
export declare interface IComputeShaderPath {
|
|
2813
|
+
computeSource?: string;
|
|
2814
|
+
compute?: string;
|
|
2815
|
+
computeElement?: string;
|
|
2816
|
+
}
|
|
2817
|
+
|
|
2671
2818
|
/** Babylon.js `ICreateTexture2DArrayFromImageUrlsOptions`. */
|
|
2672
2819
|
export declare interface ICreateTexture2DArrayFromImageUrlsOptions extends IUploadImageToTexture2DArrayLayerOptions {
|
|
2673
2820
|
/** Generate a full mip chain (true by default). */
|
|
@@ -2695,6 +2842,20 @@ export declare interface IDitheredTileFadeBounds {
|
|
|
2695
2842
|
upperBound: number;
|
|
2696
2843
|
}
|
|
2697
2844
|
|
|
2845
|
+
/**
|
|
2846
|
+
* Contract implemented by Babylon.js easing functions.
|
|
2847
|
+
*
|
|
2848
|
+
* Custom easing objects only need to transform a normalized segment gradient.
|
|
2849
|
+
*/
|
|
2850
|
+
export declare interface IEasingFunction {
|
|
2851
|
+
/**
|
|
2852
|
+
* Transform a segment-local gradient.
|
|
2853
|
+
* @param gradient - Linear progress through the current keyframe segment.
|
|
2854
|
+
* @returns The progress used for interpolation. Values are not clamped.
|
|
2855
|
+
*/
|
|
2856
|
+
ease(gradient: number): number;
|
|
2857
|
+
}
|
|
2858
|
+
|
|
2698
2859
|
export declare interface IFlowGraphValidationIssue {
|
|
2699
2860
|
severity: FlowGraphValidationSeverity;
|
|
2700
2861
|
message: string;
|
|
@@ -3372,6 +3533,11 @@ export declare class Matrix {
|
|
|
3372
3533
|
markAsUpdated(): this;
|
|
3373
3534
|
}
|
|
3374
3535
|
|
|
3536
|
+
declare interface MatrixLike {
|
|
3537
|
+
asArray(): ArrayLike<number>;
|
|
3538
|
+
readonly updateFlag?: number;
|
|
3539
|
+
}
|
|
3540
|
+
|
|
3375
3541
|
export { MaxTintMagnitude }
|
|
3376
3542
|
|
|
3377
3543
|
/** Babylon.js `Mesh` — a concrete renderable mesh with geometry. */
|
|
@@ -4557,6 +4723,15 @@ export declare class PostProcess {
|
|
|
4557
4723
|
constructor();
|
|
4558
4724
|
}
|
|
4559
4725
|
|
|
4726
|
+
/**
|
|
4727
|
+
* Babylon.js-compatible power easing class.
|
|
4728
|
+
*/
|
|
4729
|
+
export declare class PowerEase extends EasingFunction {
|
|
4730
|
+
power: number;
|
|
4731
|
+
constructor(power?: number);
|
|
4732
|
+
easeInCore(gradient: number): number;
|
|
4733
|
+
}
|
|
4734
|
+
|
|
4560
4735
|
/** Babylon.js `PrecisionDate` — high-resolution timestamp source. */
|
|
4561
4736
|
export declare const PrecisionDate: {
|
|
4562
4737
|
readonly Now: number;
|
|
@@ -4778,6 +4953,8 @@ export declare function RegisterAbstractEngineTextureLoaders(): void;
|
|
|
4778
4953
|
*/
|
|
4779
4954
|
export declare function registerBuiltInLoaders(): void;
|
|
4780
4955
|
|
|
4956
|
+
export declare function RegisterComputeShader(): void;
|
|
4957
|
+
|
|
4781
4958
|
/** Pure-build registration shim; compat wires the Lite array upload directly. */
|
|
4782
4959
|
export declare function RegisterEnginesExtensionsEngineTexture2DArrayImageSource(): void;
|
|
4783
4960
|
|
|
@@ -4874,8 +5051,8 @@ export declare class Scene extends AbstractScene {
|
|
|
4874
5051
|
/** Babylon.js fog-mode c
|
|
4875
5052
|
* Babylon.js `scene.animationGroups` / `scene.animatables`. Loaded glTF /
|
|
4876
5053
|
* `.babylon` animation clips live on the Lite scene; `animationGroups` returns
|
|
4877
5054
|
* BJS-shaped `AnimationGroup`s over them (so scenes can `goToFrame`/`pause`/`stop`
|
|
4878
|
-
* to freeze a model at a deterministic frame). `animatables` surfaces the
|
|
4879
|
-
*
|
|
5055
|
+
* to freeze a model at a deterministic frame). `animatables` surfaces the
|
|
5056
|
+
* native-backed and fallback `Animatable`s started through the scene.
|
|
4880
5057
|
*/
|
|
4881
5058
|
get animationGroups(): AnimationGroup[];
|
|
4882
5059
|
/** Babylon.js `scene.getAnimationGroupByName(name)` — first loaded animation group with a matching name, else `null`. */
|
|
@@ -4899,8 +5076,7 @@ export declare class Scene extends AbstractScene {
|
|
|
4899
5076
|
/** Babylon.js fog-mode c
|
|
4900
5077
|
private readonly _pendingMorphBuilds;
|
|
4901
5078
|
private _materialPluginsRequested;
|
|
4902
5079
|
private readonly _pendingMaterialPluginReconciliations;
|
|
4903
|
-
private readonly _runningAnimatables;
|
|
4904
|
-
private readonly _animationGroupCache;
|
|
4905
5080
|
private _ambientColor;
|
|
5081
|
+
private readonly _runningAnimatables;
|
|
4906
5082
|
private readonly _animationGroupCache;
|
|
4907
5083
|
private _ambientColor;
|
|
4908
5084
|
private _environmentIntensity;
|
|
4909
5085
|
private _imageProcessingConfiguration;
|
|
4910
5086
|
/** Babylon.js `scene.uniqueId` — a process-unique numeric id. */
|
|
4911
5087
|
readonly uniqueId: number;
|
|
@@ -5062,8 +5238,9 @@ export declare class Scene extends AbstractScene {
|
|
|
5062
5238
|
/** Babylon.js fog-mode c
|
|
5063
5239
|
disablePhysicsEngine(): void;
|
|
5064
5240
|
/**
|
|
5065
5241
|
* Babylon.js `scene.beginDirectAnimation(target, animations, from, to, loop, speedRatio?)`.
|
|
5066
|
-
*
|
|
5067
|
-
*
|
|
5242
|
+
* Delegates supported tracks to Babylon Lite property animation and retains
|
|
5243
|
+
* explicit compat evaluation only for unsupported tracks. Returns one facade
|
|
5244
|
+
* coordinating both subsets.
|
|
5068
5245
|
*/
|
|
5069
5246
|
beginDirectAnimation(target: unknown, animations: Animation_2[], from: number, to: number, loop?: boolean, speedRatio?: number): Animatable_2;
|
|
5070
5247
|
/**
|
|
5071
5248
|
* Babylon.js `scene.beginAnimation(target, from, to, loop, speedRatio?)`. Runs
|
|
@@ -5432,7 +5609,9 @@ export declare class SpriteManager {
|
|
|
5432
5609
|
disableDepthWrite: boolean;
|
|
5433
5610
|
/** Babylon.js `manager.blendMode` (`Constants.ALPHA_*`). Mapped to a Lite billboard blend at build. */
|
|
5434
5611
|
blendMode: number;
|
|
5435
5612
|
private _atlas?;
|
|
5436
|
-
constructor(name: string, url: string, capacity: number, cellSize: CellSize, scene: Scene, _epsilon?: number, samplingMode?: number);
|
|
5613
|
+
constructor(name: string, url: string, capacity: number, cellSize: CellSize, scene: Scene, _epsilon?: number, samplingMode?: number);
|
|
5614
|
+
/** Babylon.js `SpriteManager.isReady()` — an empty manager is ready without renderer preparation. */
|
|
5615
|
+
isReady(): boolean;
|
|
5437
5616
|
|
|
5438
5617
|
export declare class SpriteMap {
|
|
5439
5618
|
constructor();
|
|
@@ -5478,7 +5657,9 @@ export declare class SpriteRenderer {
|
|
|
5478
5657
|
private _built;
|
|
5479
5658
|
private readonly _indices;
|
|
5480
5659
|
private _sprites;
|
|
5481
|
-
constructor(engine: WebGPUEngine, capacity?: number, _epsilon?: number, _scene?: unknown);
|
|
5482
5660
|
/**
|
|
5661
|
+
constructor(engine: WebGPUEngine, capacity?: number, _epsilon?: number, _scene?: unknown);
|
|
5662
|
+
/** Babylon.js `SpriteRenderer.isReady()` — the next render can build once its atlas is loaded. */
|
|
5663
|
+
isReady(): boolean;
|
|
5483
5664
|
/**
|
|
5484
5665
|
* Babylon.js `renderer.render(sprites, deltaTime, viewMatrix, projectionMatrix)`.
|
|
5485
5666
|
* The matrices are owned by Babylon Lite's pixel-space sprite pass, so they are
|
|
5486
5667
|
* accepted for API parity but not consumed. First call builds + registers the
|
|
@@ -5610,6 +5791,18 @@ export declare class STLFileLoader {
|
|
|
5610
5791
|
constructor();
|
|
5611
5792
|
}
|
|
5612
5793
|
|
|
5794
|
+
/** Babylon.js-shaped wrapper over Lite's public opaque storage allocation. */
|
|
5795
|
+
export declare class StorageBuffer {
|
|
5796
|
+
private readonly _engine;
|
|
5613
5797
|
private readonly _copyReadable;
|
|
5798
|
+
private readonly _copyWritable;
|
|
5799
|
+
constructor(_engine: WebGPUEngine, size: number, creationFlags?: number, label?: string);
|
|
5614
5800
|
getBuffer(): StorageBuffer_2 | null;
|
|
5801
|
+
clear(byteOffset?: number, byteLength?: number): void;
|
|
5802
|
+
update(data: DataArray, byteOffset?: number, byteLength?: number): void;
|
|
5803
|
+
read(offset?: number, size?: number, buffer?: ArrayBufferView, noDelay?: boolean): Promise<ArrayBufferView>;
|
|
5804
|
+
dispose(): void;
|
|
5615
5805
|
private _requireBuffer;
|
|
5806
|
+
private _assertCopyWritable;
|
|
5807
|
+
}
|
|
5808
|
+
|
|
5616
5809
|
/** Babylon.js `StreamingSound` — a media-element-backed sound. */
|
|
5617
5810
|
export declare class StreamingSound extends AbstractSound {
|
|
5618
5811
|
private readonly _autoplay;
|
|
5619
5812
|
private _loop;
|
|
@@ -5857,6 +6050,83 @@ export declare class TransformNode extends Node_2 {
|
|
|
5857
6050
|
physicsBody: PhysicsBody
|
|
5858
6051
|
|
|
5859
6052
|
export declare function transformNormal(vector: Vector3, transformation: Matrix): Vector3;
|
|
5860
6053
|
|
|
6054
|
+
/** Minimum Babylon.js UniformBuffer surface needed to author compute bindings. */
|
|
6055
|
+
export declare class UniformBuffer {
|
|
6056
|
+
private readonly _engine;
|
|
6057
|
+
private readonly _data;
|
|
6058
|
+
private readonly _dynamic;
|
|
6059
|
+
private readonly _uniformLocations;
|
|
6060
|
+
private readonly _uniformSizes;
|
|
6061
|
+
private readonly _uniformArraySizes;
|
|
6062
|
+
private readonly _uniformNames;
|
|
6063
|
+
private _uniformLocationPointer;
|
|
6064
|
+
private _bufferData;
|
|
6065
|
+
private _buffer;
|
|
6066
|
+
private _needSync;
|
|
6067
|
+
private _name;
|
|
6068
|
+
constructor(_engine: AbstractEngine, data?: number[], dynamic?: boolean, name?: string, forceNoUniformBuffer?: boolean, _trackUBOsInFrame?: boolean);
|
|
6069
|
+
readonly updateMatrix3x3: (name: string, matrix: Float32Array) => void;
|
|
6070
|
+
readonly updateMatrix2x2: (name: string, matrix: Float32Array) => void;
|
|
6071
|
+
readonly updateFloat: (name: string, x: number, _suffix?: string) => void;
|
|
6072
|
+
readonly updateFloat2: (name: string, x: number, y: number, _suffix?: string) => void;
|
|
6073
|
+
readonly updateFloat3: (name: string, x: number, y: number, z: number, _suffix?: string) => void;
|
|
6074
|
+
readonly updateFloat4: (name: string, x: number, y: number, z: number, w: number, _suffix?: string) => void;
|
|
6075
|
+
readonly updateFloatArray: (name: string, array: Float32Array, _suffix?: string) => void;
|
|
6076
|
+
readonly updateArray: (name: string, array: number[]) => void;
|
|
6077
|
+
readonly updateIntArray: (name: string, array: Int32Array) => void;
|
|
6078
|
+
readonly updateUIntArray: (name: string, array: Uint32Array) => void;
|
|
6079
|
+
readonly updateMatrix: (name: string, matrix: MatrixLike) => void;
|
|
6080
|
+
readonly updateMatrices: (name: string, matrices: Float32Array) => void;
|
|
6081
|
+
readonly updateVector3: (name: string, vector: Vector3Like) => void;
|
|
6082
|
+
readonly updateVector4: (name: string, vector: Vector4Like) => void;
|
|
6083
|
+
readonly updateColor3: (name: string, color: Color3Like, suffix?: string) => void;
|
|
6084
|
+
readonly updateColor4: (name: string, color: Color3Like, alpha: number, suffix?: string) => void;
|
|
6085
|
+
readonly updateDirectColor4: (name: string, color: Color4Like, suffix?: string) => void;
|
|
6086
|
+
readonly updateInt: (name: string, x: number, _suffix?: string) => void;
|
|
6087
|
+
readonly updateInt2: (name: string, x: number, y: number, _suffix?: string) => void;
|
|
6088
|
+
readonly updateInt3: (name: string, x: number, y: number, z: number, _suffix?: string) => void;
|
|
6089
|
+
readonly updateInt4: (name: string, x: number, y: number, z: number, w: number, _suffix?: string) => void;
|
|
6090
|
+
readonly updateUInt: (name: string, x: number, _suffix?: string) => void;
|
|
6091
|
+
readonly updateUInt2: (name: string, x: number, y: number, _suffix?: string) => void;
|
|
6092
|
+
readonly updateUInt3: (name: string, x: number, y: number, z: number, _suffix?: string) => void;
|
|
6093
|
+
readonly updateUInt4: (name: string, x: number, y: number, z: number, w: number, _suffix?: string) => void;
|
|
6094
|
+
get useUbo(): boolean;
|
|
6095
|
+
get isSync(): boolean;
|
|
6096
|
+
isDynamic(): boolean;
|
|
6097
|
+
getData(): Float32Array;
|
|
6098
|
+
getBuffer(): UniformBuffer_2 | null;
|
|
6099
|
+
getUniformNames(): string[];
|
|
6100
|
+
addUniform(name: string, sizeOrData: number | number[], arraySize?: number): void;
|
|
6101
|
+
addMatrix(name: string, matrix: MatrixLike): void;
|
|
6102
|
+
addFloat2(name: string, x: number, y: number): void;
|
|
6103
|
+
addFloat3(name: string, x: number, y: number, z: number): void;
|
|
6104
|
+
addColor3(name: string, color: Color3Like): void;
|
|
6105
|
+
addColor4(name: string, color: Color3Like, alpha: number): void;
|
|
6106
|
+
addVector3(name: string, vector: Vector3Like): void;
|
|
6107
|
+
addMatrix3x3(name: string): void;
|
|
6108
|
+
addMatrix2x2(name: string): void;
|
|
6109
|
+
create(): void;
|
|
5861
6110
|
get name(): string;
|
|
6111
|
+
set name(value: string);
|
|
6112
|
+
get currentEffect(): unknown | null;
|
|
6113
|
+
update(): void;
|
|
6114
|
+
updateUniform(uniformName: string, data: FloatArray, size: number): void;
|
|
6115
|
+
updateUniformArray(uniformName: string, data: FloatArray, size: number): void;
|
|
6116
|
+
setTexture(_name: string, _texture: BaseTexture | null): never;
|
|
6117
|
+
setTextureArray(_name: string, _textures: BaseTexture[]): never;
|
|
6118
|
+
bindTexture(_name: string, _texture: unknown | null): never;
|
|
6119
|
+
updateUniformDirectly(uniformName: string, data: FloatArray): void;
|
|
6120
|
+
bindToEffect(_effect: unknown, _name: string): never;
|
|
6121
|
+
bindUniformBuffer(): never;
|
|
6122
|
+
unbindEffect(): void;
|
|
6123
|
+
setDataBuffer(dataBuffer: UniformBuffer_2): boolean;
|
|
6124
|
+
has(name: string): boolean;
|
|
6125
|
+
dispose(): void;
|
|
6126
|
+
private _align;
|
|
6127
|
+
private _updateIntegerUniform;
|
|
6128
|
+
private _updateIntegerUniformArray;
|
|
6129
|
+
private _setInteger;
|
|
6130
|
+
}
|
|
6131
|
+
|
|
5862
6132
|
/** Babylon.js `UninstallHtmlInCanvasPolyfill` — the HTML-in-canvas polyfill is unsupported by the compat layer. */
|
|
5863
6133
|
export declare function UninstallHtmlInCanvasPolyfill(): never;
|
|
5864
6134
|
|
|
@@ -6065,6 +6335,12 @@ export declare class Vector3 {
|
|
|
6065
6335
|
static TransformNormalToRef<T extends Vector3>(vector: Vector3, transformation: Matrix, result: T): T;
|
|
6066
6336
|
}
|
|
6067
6337
|
|
|
6338
|
+
declare interface Vector3Like {
|
|
6339
|
+
readonly x: number;
|
|
6340
|
+
readonly y: number;
|
|
6341
|
+
readonly z: number;
|
|
6342
|
+
}
|
|
6343
|
+
|
|
6068
6344
|
export declare class Vector4 {
|
|
6069
6345
|
x: number;
|
|
6070
6346
|
y: number;
|
|
@@ -6082,6 +6358,10 @@ export declare class Vector4 {
|
|
|
6082
6358
|
static Zero(): Vector4;
|
|
6083
6359
|
}
|
|
6084
6360
|
|
|
6361
|
+
declare interface Vector4Like extends Vector3Like {
|
|
6362
|
+
readonly w: number;
|
|
6363
|
+
}
|
|
6364
|
+
|
|
6085
6365
|
/**
|
|
6086
6366
|
* Babylon.js `VertexBuffer` — the per-attribute geometry buffer. Only the `kind`
|
|
6087
6367
|
* string constants are surfaced (used with `mesh.getVerticesData` /
|