@babylonjs-toolkit/next 9.22.2 → 9.25.1
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/lib/index.d.ts +9 -11
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +9 -11
- package/lib/ipostprocessparameter.d.ts +6 -0
- package/lib/ipostprocessparameter.d.ts.map +1 -0
- package/lib/ipostprocessparameter.js +1 -0
- package/lib/project.d.ts +1 -0
- package/lib/project.d.ts.map +1 -1
- package/lib/project.js +42 -2
- package/lib/scenemanager.d.ts +1567 -81
- package/lib/scenemanager.d.ts.map +1 -1
- package/lib/scenemanager.js +10036 -1067
- package/package.json +14 -14
- package/lib/channelmixerplugin.d.ts +0 -11
- package/lib/channelmixerplugin.d.ts.map +0 -1
- package/lib/channelmixerplugin.js +0 -34
- package/lib/lutblendplugin.d.ts +0 -13
- package/lib/lutblendplugin.d.ts.map +0 -1
- package/lib/lutblendplugin.js +0 -153
package/lib/scenemanager.d.ts
CHANGED
|
@@ -2,19 +2,20 @@ import { AssetContainer, InstantiatedEntries } from '@babylonjs/core/assetContai
|
|
|
2
2
|
import { AbstractEngine } from '@babylonjs/core/Engines/abstractEngine';
|
|
3
3
|
import { Mesh } from '@babylonjs/core/Meshes/mesh';
|
|
4
4
|
import { Scene } from '@babylonjs/core/scene';
|
|
5
|
-
import { AssetsManager, BinaryFileAssetTask, ContainerAssetTask, MeshAssetTask, TextFileAssetTask, ImageAssetTask
|
|
5
|
+
import { AssetsManager, BinaryFileAssetTask, AbstractAssetTask, ContainerAssetTask, MeshAssetTask, TextFileAssetTask, ImageAssetTask } from '@babylonjs/core/Misc/assetsManager';
|
|
6
6
|
import { TransformNode } from '@babylonjs/core/Meshes/transformNode';
|
|
7
7
|
import { ShadowLight, IShadowLight } from '@babylonjs/core/Lights/shadowLight';
|
|
8
8
|
import { AbstractMesh } from '@babylonjs/core/Meshes/abstractMesh';
|
|
9
9
|
import { ISceneLoaderProgressEvent, ISceneLoaderPluginAsync, ISceneLoaderPlugin } from '@babylonjs/core/Loading/sceneLoader';
|
|
10
10
|
import { Node as BabylonNode } from '@babylonjs/core/node';
|
|
11
11
|
import { Light } from '@babylonjs/core/Lights/light';
|
|
12
|
-
import { Vector3, Quaternion, Vector2, Vector4
|
|
12
|
+
import { Vector3, Matrix, Quaternion, Vector2, Vector4 } from '@babylonjs/core/Maths/math.vector';
|
|
13
13
|
import { ICrowd, IAgentParameters } from '@babylonjs/core/Navigation';
|
|
14
14
|
import { FreeCamera } from '@babylonjs/core/Cameras/freeCamera';
|
|
15
15
|
import { IAction } from '@babylonjs/core/Actions/action';
|
|
16
16
|
import { Engine } from '@babylonjs/core/Engines/engine';
|
|
17
|
-
import {
|
|
17
|
+
import { Color3, Color4 } from '@babylonjs/core/Maths/math.color';
|
|
18
|
+
import { SphericalPolynomial, SphericalHarmonics, PostProcess, DefaultRenderingPipeline, SSRRenderingPipeline, MotionBlurPostProcess } from '@babylonjs/core';
|
|
18
19
|
import { Nullable, DeepImmutable } from '@babylonjs/core/types';
|
|
19
20
|
import { Material } from '@babylonjs/core/Materials/material';
|
|
20
21
|
import { InstancedMesh } from '@babylonjs/core/Meshes/instancedMesh';
|
|
@@ -22,11 +23,11 @@ import { RecastNavigationJSPluginV2 } from '@babylonjs/addons';
|
|
|
22
23
|
import { Animation } from '@babylonjs/core/Animations/animation';
|
|
23
24
|
import { EasingFunction } from '@babylonjs/core/Animations/easing';
|
|
24
25
|
import { HavokPluginParameters, HavokPlugin } from '@babylonjs/core/Physics/v2/Plugins/havokPlugin';
|
|
25
|
-
import { Color4, Color3 } from '@babylonjs/core/Maths/math.color';
|
|
26
26
|
import { AnimationGroup, TargetedAnimation } from '@babylonjs/core/Animations/animationGroup';
|
|
27
27
|
import { Space } from '@babylonjs/core/Maths/math.axis';
|
|
28
28
|
import { Observable, Observer, EventState } from '@babylonjs/core/Misc/observable';
|
|
29
29
|
import { StandardMaterial } from '@babylonjs/core/Materials/standardMaterial';
|
|
30
|
+
import { VertexData } from '@babylonjs/core/Meshes/mesh.vertexData';
|
|
30
31
|
import { PBRMaterial } from '@babylonjs/core/Materials/PBR/pbrMaterial';
|
|
31
32
|
import { Animatable } from '@babylonjs/core/Animations/animatable';
|
|
32
33
|
import { WebGPUEngine } from '@babylonjs/core/Engines/webgpuEngine';
|
|
@@ -47,14 +48,16 @@ import { MaterialDefines } from '@babylonjs/core/Materials/materialDefines';
|
|
|
47
48
|
import { UniformBuffer } from '@babylonjs/core/Materials/uniformBuffer';
|
|
48
49
|
import { MaterialPluginBase } from '@babylonjs/core/Materials/materialPluginBase';
|
|
49
50
|
import { IAnimatable } from '@babylonjs/core/Animations';
|
|
50
|
-
import { ShaderLanguage, RawTexture2DArray } from '@babylonjs/core/Materials';
|
|
51
|
+
import { ShaderLanguage, ImageProcessingConfiguration, RawTexture2DArray } from '@babylonjs/core/Materials';
|
|
51
52
|
import { StaticSound, IStaticSoundOptions, AudioEngineV2, StaticSoundBuffer, StreamingSound, IWebAudioEngineOptions, AbstractSpatialAudio, IStaticSoundBufferOptions, IStreamingSoundOptions } from '@babylonjs/core/AudioV2';
|
|
52
|
-
import { VertexData } from '@babylonjs/core/Meshes/mesh.vertexData';
|
|
53
53
|
import { IFileRequest } from '@babylonjs/core/Misc/fileRequest';
|
|
54
54
|
import { Bone } from '@babylonjs/core/Bones/bone';
|
|
55
55
|
import { WebRequest } from '@babylonjs/core/Misc/webRequest';
|
|
56
56
|
import { Gamepad } from '@babylonjs/core/Gamepads/gamepad';
|
|
57
57
|
import { GamepadManager } from '@babylonjs/core/Gamepads/gamepadManager';
|
|
58
|
+
import { IInspectorOptions } from '@babylonjs/core/Debug/debugLayer';
|
|
59
|
+
import { PostProcessRenderPipeline } from '@babylonjs/core/PostProcesses/RenderPipeline/postProcessRenderPipeline';
|
|
60
|
+
import { SSAO2RenderingPipeline } from '@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/ssao2RenderingPipeline';
|
|
58
61
|
import { ParticleSystem } from '@babylonjs/core/Particles/particleSystem';
|
|
59
62
|
import { GPUParticleSystem } from '@babylonjs/core/Particles/gpuParticleSystem';
|
|
60
63
|
import { AdvancedDynamicTexture } from '@babylonjs/gui/2D/advancedDynamicTexture';
|
|
@@ -71,6 +74,7 @@ export declare class SceneManager {
|
|
|
71
74
|
static RenderLoopReady: boolean;
|
|
72
75
|
static PauseRenderLoop: boolean;
|
|
73
76
|
static ScenePlaying: boolean;
|
|
77
|
+
static DeinstanceProbeLitNodes: boolean;
|
|
74
78
|
private static PhysicsTimeStep;
|
|
75
79
|
static LostRenderContext: boolean;
|
|
76
80
|
static AutoUpdateProgress: boolean;
|
|
@@ -83,6 +87,7 @@ export declare class SceneManager {
|
|
|
83
87
|
static PointLightIntensity: number;
|
|
84
88
|
static SpotLightIntensity: number;
|
|
85
89
|
static DirectionalLightIntensity: number;
|
|
90
|
+
static ShadowDarknessScale: number;
|
|
86
91
|
static FogExpDensityScale: number;
|
|
87
92
|
static FogExp2DensityScale: number;
|
|
88
93
|
static FogLinearDensityScale: number;
|
|
@@ -141,6 +146,7 @@ export declare class SceneManager {
|
|
|
141
146
|
static HideLoadingScreen(engine: Engine | WebGPUEngine | AbstractEngine, fade?: boolean): void;
|
|
142
147
|
static ForceHideLoadingScreen(): void;
|
|
143
148
|
private static DoForceHideLoadingScreen;
|
|
149
|
+
static ShowRenderCanvas(scene: Scene): void;
|
|
144
150
|
static FocusRenderCanvas(scene: Scene): void;
|
|
145
151
|
static ShowSplashScreen(): void;
|
|
146
152
|
static HideSplashScreen(scene?: Scene, delayMs?: number): void;
|
|
@@ -155,6 +161,10 @@ export declare class SceneManager {
|
|
|
155
161
|
static HasSceneBeenPreLoaded(scene: Scene): boolean;
|
|
156
162
|
static GetDefaultSkybox(scene: Scene): AbstractMesh;
|
|
157
163
|
static GetIntensityFactor(): number;
|
|
164
|
+
static GetLightmapBakeMode(): string;
|
|
165
|
+
static GetShadowmaskMode(): string;
|
|
166
|
+
static GetSubtractiveShadowColor(): Color3;
|
|
167
|
+
static GetRenderPipeline(): string;
|
|
158
168
|
static GetRenderQuality(): RenderQuality;
|
|
159
169
|
static SetRenderQuality(quality: RenderQuality): void;
|
|
160
170
|
static GetEngineVersionString(scene: Scene): string;
|
|
@@ -238,7 +248,7 @@ export declare class SceneManager {
|
|
|
238
248
|
static GetMaterialWithName(scene: Scene, name: string): Material;
|
|
239
249
|
static GetAllMaterialsWithName(scene: Scene, name: string): Material[];
|
|
240
250
|
static InstantiatePrefabFromScene(scene: Scene, prefabName: string, newName: string, newParent?: Nullable<TransformNode>, newPosition?: Nullable<Vector3>, newRotation?: Nullable<Quaternion>, newScaling?: Nullable<Vector3>, cloneAnimations?: boolean): TransformNode;
|
|
241
|
-
static InstantiatePrefabFromContainer(container: AssetContainer, prefabName: string, newName: string, newParent?: Nullable<TransformNode>, newPosition?: Nullable<Vector3>, newRotation?: Nullable<Quaternion>, newScaling?: Nullable<Vector3>, cloneAnimations?: boolean, makeNewMaterials?: boolean): TransformNode;
|
|
251
|
+
static InstantiatePrefabFromContainer(container: AssetContainer, prefabName: string, newName: string, newParent?: Nullable<TransformNode>, newPosition?: Nullable<Vector3>, newRotation?: Nullable<Quaternion>, newScaling?: Nullable<Vector3>, cloneAnimations?: boolean, makeNewMaterials?: boolean, createInstancedMesh?: Nullable<boolean>): TransformNode;
|
|
242
252
|
static InstantiateModelsFromContainer(container: AssetContainer, nameFunction?: (sourceName: string) => string, createInstances?: boolean, cloneMaterials?: boolean, rebuildBoundingInfo?: boolean, filterPredicate?: any): TransformNode[];
|
|
243
253
|
static CreateInstancedModelsFromContainer(container: AssetContainer, newName?: string, newParent?: Nullable<TransformNode>, newPosition?: Nullable<Vector3>, newRotation?: Nullable<Quaternion>, newScaling?: Nullable<Vector3>, cloneAnimations?: boolean, makeNewMaterials?: boolean, rebuildBoundingInfo?: boolean): InstantiatedEntries;
|
|
244
254
|
static CloneTransformNode(container: AssetContainer, nodeName: string, newName: string, newParent?: Nullable<TransformNode>, newPosition?: Nullable<Vector3>, newRotation?: Nullable<Quaternion>, newScaling?: Nullable<Vector3>): TransformNode;
|
|
@@ -299,6 +309,50 @@ export declare class SceneManager {
|
|
|
299
309
|
static BuildNavigationMeshTileCacheAsync(scene: Scene, tileCacheData: Uint8Array, tileCacheMeshProcess?: any, heightMesh?: Mesh, createDebugMesh?: boolean): Promise<void>;
|
|
300
310
|
static CreateNavigationMeshSceneDataAsync(scene: Scene, properties: IUnityNavigationOptions, geometry: Mesh[], heightMesh?: Mesh, createDebugMesh?: boolean): Promise<void>;
|
|
301
311
|
static DestroyNavigationMeshData(scene?: Scene): void;
|
|
312
|
+
static MAX_NAVIGATION_AREAS: number;
|
|
313
|
+
static NAVIGATION_AREA_WALKABLE: number;
|
|
314
|
+
static NAVIGATION_AREA_NOT_WALKABLE: number;
|
|
315
|
+
static NAVIGATION_AREA_JUMP: number;
|
|
316
|
+
static NAVIGATION_AREA_HEIGHT_TOLERANCE: number;
|
|
317
|
+
static OnNavigationAreasChangedObservable: Observable<number>;
|
|
318
|
+
private static NavAreaNames;
|
|
319
|
+
private static NavAreaCosts;
|
|
320
|
+
private static NavAreaVolumes;
|
|
321
|
+
private static NavAreaMeshes;
|
|
322
|
+
private static NavAreaHandle;
|
|
323
|
+
private static NavAreaBaseline;
|
|
324
|
+
private static NavAreaDebugger;
|
|
325
|
+
private static NavAreaDebugMaterial;
|
|
326
|
+
private static NavAreaShowDebug;
|
|
327
|
+
private static NavAreaScene;
|
|
328
|
+
private static NavAreaWarnings;
|
|
329
|
+
static RegisterNavigationArea(id: number, name: string, cost?: number): void;
|
|
330
|
+
static SetNavigationAreaCost(id: number, cost: number): void;
|
|
331
|
+
static GetNavigationAreaCost(id: number): number;
|
|
332
|
+
static GetNavigationAreaByName(name: string): number;
|
|
333
|
+
static GetNavigationAreaNames(): string[];
|
|
334
|
+
static NavigationAreaToFlags(area: number): number;
|
|
335
|
+
static AreaMaskToIncludeFlags(areaMask: number): number;
|
|
336
|
+
static ConfigureNavigationQueryFilter(filter: any, includeFlags?: number, areaCosts?: Map<number, number>): void;
|
|
337
|
+
static AddNavigationAreaVolume(area: number, minimum: Vector3, maximum: Vector3): number;
|
|
338
|
+
static RemoveNavigationAreaVolume(handle: number): void;
|
|
339
|
+
static ClearNavigationAreaVolumes(): void;
|
|
340
|
+
static AddNavigationAreaMesh(mesh: AbstractMesh, area: number, heightTolerance?: number): void;
|
|
341
|
+
static RemoveNavigationAreaMesh(mesh: AbstractMesh): void;
|
|
342
|
+
static ClearNavigationAreaMeshes(): void;
|
|
343
|
+
static ApplyNavigationAreas(): number;
|
|
344
|
+
static GetNavigationAreaAtPosition(position: Vector3): number;
|
|
345
|
+
static RefreshNavigationAreaDebugMesh(scene: Scene): Mesh;
|
|
346
|
+
static GetNavigationAreaDebug(): Mesh | null;
|
|
347
|
+
private static PrepareNavigationAreas;
|
|
348
|
+
private static RefreshNavigationAreaCosts;
|
|
349
|
+
private static IsValidNavigationArea;
|
|
350
|
+
private static ClampNavigationAreaCost;
|
|
351
|
+
private static ResolveNavigationArea;
|
|
352
|
+
private static GetNavigationAreaColor;
|
|
353
|
+
private static ForEachNavigationPolygon;
|
|
354
|
+
private static CreateNavigationAreaSurface;
|
|
355
|
+
private static IsOverNavigationAreaSurface;
|
|
302
356
|
static ToggleFullscreenMode(scene: Scene, requestPointerLock?: boolean): void;
|
|
303
357
|
static EnterFullscreenMode(scene: Scene, requestPointerLock?: boolean): void;
|
|
304
358
|
static ExitFullscreenMode(scene: Scene): void;
|
|
@@ -361,6 +415,17 @@ export interface IUnityNavigationOptions {
|
|
|
361
415
|
detailsamplemaxerror: number;
|
|
362
416
|
buildheightmesh: boolean;
|
|
363
417
|
}
|
|
418
|
+
export interface INavigationAreaVolume {
|
|
419
|
+
handle: number;
|
|
420
|
+
area: number;
|
|
421
|
+
minimum: Vector3;
|
|
422
|
+
maximum: Vector3;
|
|
423
|
+
}
|
|
424
|
+
export interface INavigationAreaMesh {
|
|
425
|
+
mesh: AbstractMesh;
|
|
426
|
+
area: number;
|
|
427
|
+
heightTolerance: number;
|
|
428
|
+
}
|
|
364
429
|
export declare abstract class ScriptComponent {
|
|
365
430
|
private _update;
|
|
366
431
|
private _late;
|
|
@@ -645,6 +710,7 @@ export declare class UserInputOptions {
|
|
|
645
710
|
export interface IRuntimeOptions {
|
|
646
711
|
enableUserInput?: boolean;
|
|
647
712
|
hardwareScalingLevel?: number;
|
|
713
|
+
trackDevicePixelRatio?: boolean;
|
|
648
714
|
initSceneFileLoaders?: boolean;
|
|
649
715
|
loadAsyncRuntimeLibs?: boolean;
|
|
650
716
|
loadProjectScriptBundle?: boolean;
|
|
@@ -783,12 +849,22 @@ export declare class GlobalMessageBus {
|
|
|
783
849
|
private OnDispatchMessage;
|
|
784
850
|
private ListenerDictionary;
|
|
785
851
|
}
|
|
852
|
+
export declare class PreloadPromiseTask extends AbstractAssetTask {
|
|
853
|
+
promiseFactory: () => Promise<any>;
|
|
854
|
+
timeoutMs: number;
|
|
855
|
+
result: any;
|
|
856
|
+
constructor(name: string, promiseFactory: () => Promise<any>, timeoutMs?: number);
|
|
857
|
+
runTask(scene: Scene, onSuccess: () => void, onError: (message?: string, exception?: any) => void): void;
|
|
858
|
+
}
|
|
786
859
|
export declare class PreloadAssetsManager extends AssetsManager {
|
|
860
|
+
static PreloadContainerSkins: boolean;
|
|
861
|
+
static PreloadContainerAssetsAsync(scene: Scene, container: AssetContainer, rootUrl?: string): Promise<void>;
|
|
787
862
|
addContainerTask(taskName: string, meshesNames: any, rootUrl: string, sceneFilename: string): ContainerAssetTask;
|
|
788
863
|
addMeshTask(taskName: string, meshesNames: any, rootUrl: string, sceneFilename: string): MeshAssetTask;
|
|
789
864
|
addTextFileTask(taskName: string, url: string): TextFileAssetTask;
|
|
790
865
|
addBinaryFileTask(taskName: string, url: string): BinaryFileAssetTask;
|
|
791
866
|
addImageTask(taskName: string, url: string): ImageAssetTask;
|
|
867
|
+
addPromiseTask(taskName: string, promiseFactory: () => Promise<any>, timeoutMs?: number): PreloadPromiseTask;
|
|
792
868
|
private handlePreloadingProgress;
|
|
793
869
|
}
|
|
794
870
|
export declare enum MaterialAlphaMode {
|
|
@@ -833,6 +909,7 @@ export declare class CVTOOLS_unity_metadata implements IGLTFLoaderExtension {
|
|
|
833
909
|
private _animationGroups;
|
|
834
910
|
private _materialMap;
|
|
835
911
|
private _lightmapMap;
|
|
912
|
+
private _shadowmaskMap;
|
|
836
913
|
private _reflectionMap;
|
|
837
914
|
private _reflectionCache;
|
|
838
915
|
private _assetContainer;
|
|
@@ -849,6 +926,8 @@ export declare class CVTOOLS_unity_metadata implements IGLTFLoaderExtension {
|
|
|
849
926
|
private _licenseType;
|
|
850
927
|
private _pendingReflectionTextures;
|
|
851
928
|
private static ScriptBundleCache;
|
|
929
|
+
private static _bundleWarned;
|
|
930
|
+
private _missingMaterialClasses;
|
|
852
931
|
constructor(loader: GLTFLoader);
|
|
853
932
|
dispose(): void;
|
|
854
933
|
static CreateExtensionAsync(loader: GLTFLoader): Promise<CVTOOLS_unity_metadata>;
|
|
@@ -873,6 +952,8 @@ export declare class CVTOOLS_unity_metadata implements IGLTFLoaderExtension {
|
|
|
873
952
|
loadMaterialPropertiesAsync(context: string, material: IMaterial, babylonMaterial: Material): Nullable<Promise<void>>;
|
|
874
953
|
private _getCachedMaterialByIndex;
|
|
875
954
|
private _getCachedLightmapByIndex;
|
|
955
|
+
private _registerShadowmaskSampler;
|
|
956
|
+
private _getCachedShadowmaskByIndex;
|
|
876
957
|
createMaterial(context: string, material: IMaterial, babylonDrawMode: number): Nullable<Material>;
|
|
877
958
|
loadAnimationAsync(context: string, animation: IAnimation): Promise<AnimationGroup>;
|
|
878
959
|
_loadMeshPrimitiveAsync(context: string, name: string, node: INode, mesh: IMesh, primitive: any, assign: (babylonMesh: AbstractMesh) => void): Promise<AbstractMesh>;
|
|
@@ -914,12 +995,12 @@ export declare class CustomShaderMaterial extends PBRMaterial {
|
|
|
914
995
|
private _attributes;
|
|
915
996
|
private _textures;
|
|
916
997
|
private _vectors4;
|
|
998
|
+
private _matrices;
|
|
917
999
|
private _vectors3;
|
|
918
1000
|
private _vectors2;
|
|
919
1001
|
private _floats;
|
|
920
1002
|
private _bools;
|
|
921
1003
|
private _ubos;
|
|
922
|
-
private _wgslSamplers;
|
|
923
1004
|
private _noMatrixTextures;
|
|
924
1005
|
protected shader: string;
|
|
925
1006
|
protected plugin: MaterialPluginBase;
|
|
@@ -930,6 +1011,7 @@ export declare class CustomShaderMaterial extends PBRMaterial {
|
|
|
930
1011
|
private _skinArrayEmissive;
|
|
931
1012
|
private _skinLayerUniform;
|
|
932
1013
|
private _skinArraySwitchingPlugin;
|
|
1014
|
+
private _shadowmaskPlugin;
|
|
933
1015
|
getPlugin(): MaterialPluginBase;
|
|
934
1016
|
getClassName(): string;
|
|
935
1017
|
constructor(name: string, scene: Scene);
|
|
@@ -957,9 +1039,13 @@ export declare class CustomShaderMaterial extends PBRMaterial {
|
|
|
957
1039
|
setTextureValue(name: string, texture: Texture): CustomShaderMaterial;
|
|
958
1040
|
markTextureAsRaw(name: string): void;
|
|
959
1041
|
getTextureValue(name: string): Texture;
|
|
1042
|
+
getShadowmaskTexture(): BaseTexture;
|
|
960
1043
|
addVector4Uniform(name: string, value: Vector4): CustomShaderMaterial;
|
|
961
1044
|
setVector4Value(name: string, value: Vector4): CustomShaderMaterial;
|
|
962
1045
|
getVector4Value(name: string): Vector4;
|
|
1046
|
+
addMatrixUniform(name: string, value: Matrix): CustomShaderMaterial;
|
|
1047
|
+
setMatrixValue(name: string, value: Matrix): CustomShaderMaterial;
|
|
1048
|
+
getMatrixValue(name: string): Matrix;
|
|
963
1049
|
addVector3Uniform(name: string, value: Vector3): CustomShaderMaterial;
|
|
964
1050
|
setVector3Value(name: string, value: Vector3): CustomShaderMaterial;
|
|
965
1051
|
getVector3Value(name: string): Vector3;
|
|
@@ -981,6 +1067,7 @@ export declare class CustomShaderMaterial extends PBRMaterial {
|
|
|
981
1067
|
getCustomVertexCode(wgsl: boolean): string;
|
|
982
1068
|
getCustomFragmentCode(wgsl: boolean): string;
|
|
983
1069
|
prepareCustomDefines(defines: MaterialDefines): void;
|
|
1070
|
+
updateShadowmaskBindings(subMesh: SubMesh): void;
|
|
984
1071
|
updateCustomBindings(effectOrUniformBuffer: UniformBuffer | Effect): void;
|
|
985
1072
|
legacyUpdateCustomBindings(effect: UniformBuffer): void;
|
|
986
1073
|
protected buildUniformProperty(uniformName: string, uniformType: string, uniformValue: any): void;
|
|
@@ -1002,7 +1089,9 @@ export declare class UnityStyleLightingPlugin extends CustomShaderMaterialPlugin
|
|
|
1002
1089
|
getCustomCode(shaderType: string, shaderLanguage: ShaderLanguage): any;
|
|
1003
1090
|
getUniforms(shaderLanguage: ShaderLanguage): any;
|
|
1004
1091
|
prepareDefines(defines: MaterialDefines, scene: Scene, mesh: AbstractMesh): void;
|
|
1092
|
+
hardBindForSubMesh(uniformBuffer: UniformBuffer, scene: Scene, engine: AbstractEngine, subMesh: SubMesh): void;
|
|
1005
1093
|
bindForSubMesh(uniformBuffer: UniformBuffer, scene: Scene, engine: AbstractEngine, subMesh: SubMesh): void;
|
|
1094
|
+
static WriteProbeHarmonics(uniformBuffer: UniformBuffer, subMesh: SubMesh): boolean;
|
|
1006
1095
|
}
|
|
1007
1096
|
export declare class SkinArraySwitchingPlugin extends CustomShaderMaterialPlugin {
|
|
1008
1097
|
constructor(material: CustomShaderMaterial);
|
|
@@ -1029,6 +1118,26 @@ export declare class SkinArraySwitchingPlugin extends CustomShaderMaterialPlugin
|
|
|
1029
1118
|
private getWGSLMetalRoughApplyCode;
|
|
1030
1119
|
private getWGSLEmissiveCode;
|
|
1031
1120
|
}
|
|
1121
|
+
export declare class ShadowmaskPlugin extends CustomShaderMaterialPlugin {
|
|
1122
|
+
constructor(material: CustomShaderMaterial);
|
|
1123
|
+
isCompatible(shaderLanguage: ShaderLanguage): boolean;
|
|
1124
|
+
getClassName(): string;
|
|
1125
|
+
getSamplers(samplers: string[]): void;
|
|
1126
|
+
getAttributes(attributes: string[], scene: Scene, mesh: AbstractMesh): void;
|
|
1127
|
+
prepareDefines(defines: MaterialDefines, scene: Scene, mesh: AbstractMesh): void;
|
|
1128
|
+
updateShadowmaskBindings(mesh: AbstractMesh): void;
|
|
1129
|
+
static IsBakedIntoLightmap(light: any): boolean;
|
|
1130
|
+
private updateSubtractiveBindings;
|
|
1131
|
+
getCustomCode(shaderType: string, shaderLanguage: ShaderLanguage): any;
|
|
1132
|
+
private getSubtractiveCode;
|
|
1133
|
+
private getCombineCode;
|
|
1134
|
+
private getGLSLDefinitions;
|
|
1135
|
+
private getGLSLSample;
|
|
1136
|
+
private getGLSLLightCode;
|
|
1137
|
+
private getWGSLDefinitions;
|
|
1138
|
+
private getWGSLSample;
|
|
1139
|
+
private getWGSLLightCode;
|
|
1140
|
+
}
|
|
1032
1141
|
export type CustomUniformProperty = {
|
|
1033
1142
|
name: string;
|
|
1034
1143
|
size: number;
|
|
@@ -1039,6 +1148,27 @@ export declare class UniversalShaderMaterial extends CustomShaderMaterial {
|
|
|
1039
1148
|
constructor(name: string, scene: Scene);
|
|
1040
1149
|
getShaderName(): string;
|
|
1041
1150
|
}
|
|
1151
|
+
export declare class LightingConversions {
|
|
1152
|
+
static ProbeRiderEpoch: number;
|
|
1153
|
+
static readonly MaxShadowmaskLights: number;
|
|
1154
|
+
static OcclusionSelector(channel: number): Vector4;
|
|
1155
|
+
static BakedShadowStrength(maskValue: number, shadowStrength: number): number;
|
|
1156
|
+
static SrgbToLinear(c: number): number;
|
|
1157
|
+
static SubtractiveShadowColor(exported: any, assumeGamma: boolean): Color3;
|
|
1158
|
+
static MainLightColor(light: any): Color3;
|
|
1159
|
+
private static Warned;
|
|
1160
|
+
static WarnOnce(key: string, message: string): void;
|
|
1161
|
+
static hasWarned(key: string): boolean;
|
|
1162
|
+
static resetWarnings(): void;
|
|
1163
|
+
static IntensityModeFor(lightType: number): number;
|
|
1164
|
+
static IsIntensityModeValid(lightType: number, mode: number): boolean;
|
|
1165
|
+
static readonly UnitySHPreScaled: boolean;
|
|
1166
|
+
static readonly UnitySHStride: number;
|
|
1167
|
+
static SphericalHarmonicsFromUnity(coeffs: ArrayLike<number>, offset: number, scale: number): SphericalHarmonics;
|
|
1168
|
+
static ProbeUniformsFromUnity(coeffs: ArrayLike<number>, offset: number, scale: number, out: Float32Array, outOffset: number): Float32Array;
|
|
1169
|
+
static EvaluateShUniforms(u: ArrayLike<number>, offset: number, nx: number, ny: number, nz: number, out: number[]): number[];
|
|
1170
|
+
static TetrahedronBarycentric(px: number, py: number, pz: number, ax: number, ay: number, az: number, bx: number, by: number, bz: number, cx: number, cy: number, cz: number, dx: number, dy: number, dz: number, out: Float32Array | number[]): boolean;
|
|
1171
|
+
}
|
|
1042
1172
|
export declare class MetadataParser {
|
|
1043
1173
|
private _physicList;
|
|
1044
1174
|
private _shadowList;
|
|
@@ -1046,6 +1176,7 @@ export declare class MetadataParser {
|
|
|
1046
1176
|
private _scriptList;
|
|
1047
1177
|
private _babylonScene;
|
|
1048
1178
|
constructor(scene: Scene);
|
|
1179
|
+
static GetShadowDarkness(shadowstrength: number): number;
|
|
1049
1180
|
parseSceneComponents(entity: TransformNode): void;
|
|
1050
1181
|
postProcessSceneComponents(preloadList: Array<ScriptComponent>, readyList: Array<ScriptComponent>): void;
|
|
1051
1182
|
private static DoParseSceneComponents;
|
|
@@ -1069,7 +1200,6 @@ export declare class StandardShaderMaterial extends StandardMaterial {
|
|
|
1069
1200
|
private _floats;
|
|
1070
1201
|
private _bools;
|
|
1071
1202
|
private _ubos;
|
|
1072
|
-
private _wgslSamplers;
|
|
1073
1203
|
protected shader: string;
|
|
1074
1204
|
protected plugin: MaterialPluginBase;
|
|
1075
1205
|
getClassName(): string;
|
|
@@ -1324,13 +1454,13 @@ export declare class Utilities {
|
|
|
1324
1454
|
static GetNeutralReflectionTexture(scene: Scene, grayValue?: number, level?: number): CubeTexture;
|
|
1325
1455
|
static GetAssetContainerMesh(container: AssetContainer, meshName: string): Mesh;
|
|
1326
1456
|
static GetAssetContainerNode(container: AssetContainer, nodeName: string): TransformNode;
|
|
1327
|
-
static CloneAssetContainerItem(container: AssetContainer, assetName: string, nameFunction?: (sourceName: string) => string, newParent?: Nullable<TransformNode>, makeNewMaterials?: boolean, cloneAnimations?: boolean): TransformNode;
|
|
1457
|
+
static CloneAssetContainerItem(container: AssetContainer, assetName: string, nameFunction?: (sourceName: string) => string, newParent?: Nullable<TransformNode>, makeNewMaterials?: boolean, cloneAnimations?: boolean, createInstancedMesh?: Nullable<boolean>): TransformNode;
|
|
1328
1458
|
static AssignAnimationGroupsToInstance(root: TransformNode, groups: AnimationGroup[]): void;
|
|
1329
1459
|
static AssignAnimationGroupsToNode(transform: TransformNode, groups: AnimationGroup[]): void;
|
|
1330
1460
|
static UnitySlopeAngleToCosine(unitySlopeAngleDegrees: number): number;
|
|
1331
|
-
static InstantiateHierarchy(node: TransformNode, newParent?: Nullable<TransformNode>, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void): Nullable<TransformNode>;
|
|
1332
|
-
static InstantiateNodeHierarchy(node: TransformNode, newParent?: Nullable<TransformNode>, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void): Nullable<TransformNode>;
|
|
1333
|
-
static InstantiateMeshHierarchy(mesh: Mesh, newParent: Nullable<TransformNode>, createInstance: boolean, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void): Nullable<TransformNode>;
|
|
1461
|
+
static InstantiateHierarchy(node: TransformNode, newParent?: Nullable<TransformNode>, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void, createInstancedMesh?: Nullable<boolean>): Nullable<TransformNode>;
|
|
1462
|
+
static InstantiateNodeHierarchy(node: TransformNode, newParent?: Nullable<TransformNode>, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void, createInstancedMesh?: Nullable<boolean>): Nullable<TransformNode>;
|
|
1463
|
+
static InstantiateMeshHierarchy(mesh: Mesh, newParent: Nullable<TransformNode>, createInstance: boolean, onNewNodeCreated?: (source: TransformNode, clone: TransformNode) => void, createInstancedMesh?: Nullable<boolean>): Nullable<TransformNode>;
|
|
1334
1464
|
static PrepareSkeletonForRendering(skeleton: Skeleton, dontCheckFrameId?: boolean): void;
|
|
1335
1465
|
static RetargetAnimationGroupSkeleton(animationGroup: AnimationGroup, targetSkeleton: Skeleton, targetArmatureNode?: TransformNode): void;
|
|
1336
1466
|
static RetargetAnimationGroupBlendShapes(animationGroup: AnimationGroup, targetMesh: Mesh): void;
|
|
@@ -1515,6 +1645,8 @@ export declare class VertexAnimationMaterial extends CustomShaderMaterial {
|
|
|
1515
1645
|
private _vatSkinArrayNormal;
|
|
1516
1646
|
private _vatSkinArrayMetalRough;
|
|
1517
1647
|
private _vatSkinArrayEmissive;
|
|
1648
|
+
private _vatSkinSlot;
|
|
1649
|
+
private _vatSkinLayerUniform;
|
|
1518
1650
|
constructor(name: string, scene: Scene);
|
|
1519
1651
|
awake(): void;
|
|
1520
1652
|
update(): void;
|
|
@@ -1529,6 +1661,12 @@ export declare class VertexAnimationMaterial extends CustomShaderMaterial {
|
|
|
1529
1661
|
disableVatSkinArrayMetalRough(): void;
|
|
1530
1662
|
enableVatSkinArrayEmissive(): VertexAnimationMaterial;
|
|
1531
1663
|
disableVatSkinArrayEmissive(): void;
|
|
1664
|
+
setVatSkinSlot(slot: number): VertexAnimationMaterial;
|
|
1665
|
+
get vatSkinSlot(): number;
|
|
1666
|
+
enableVatSkinLayerUniform(): VertexAnimationMaterial;
|
|
1667
|
+
setVatSkinLayerUniform(layer: number): VertexAnimationMaterial;
|
|
1668
|
+
disableVatSkinLayerUniform(): VertexAnimationMaterial;
|
|
1669
|
+
get vatSkinLayerUniform(): boolean;
|
|
1532
1670
|
get vatSkinArray(): boolean;
|
|
1533
1671
|
get vatSkinArrayNormal(): boolean;
|
|
1534
1672
|
get vatSkinArrayMetalRough(): boolean;
|
|
@@ -1592,8 +1730,11 @@ export declare class VertexAnimationController {
|
|
|
1592
1730
|
static Find(guid: string): VertexAnimationController;
|
|
1593
1731
|
static GetOrCreate(guid: string, scene: Scene, rootUrl?: string, lazyLoadTextures?: boolean): VertexAnimationController;
|
|
1594
1732
|
static CollectRendererTargets(settings: IVertexAnimationSettings[]): IVertexAnimationRendererReference[];
|
|
1595
|
-
static
|
|
1596
|
-
static
|
|
1733
|
+
static readonly MAX_ATLAS_CELL_SLOTS: number;
|
|
1734
|
+
static readonly MAX_ATLAS_CELL_INDEX: number;
|
|
1735
|
+
static SetAtlasCellIndex(mesh: AbstractMesh, cellIndex: number, slot?: number): void;
|
|
1736
|
+
static GetAtlasCellIndex(mesh: AbstractMesh, slot?: number): number;
|
|
1737
|
+
static PackAtlasCells(mesh: AbstractMesh): number;
|
|
1597
1738
|
static DisposeAll(scene?: Scene): void;
|
|
1598
1739
|
readonly guid: string;
|
|
1599
1740
|
readonly scene: Scene;
|
|
@@ -2048,6 +2189,12 @@ export declare class WindowManager {
|
|
|
2048
2189
|
static PopupDebug(scene: Scene): void;
|
|
2049
2190
|
static ToggleDebug(scene: Scene, embed?: boolean, parent?: HTMLElement): void;
|
|
2050
2191
|
private static debugLayerVisible;
|
|
2192
|
+
private static inspectorTokens;
|
|
2193
|
+
static ShowInspector(scene: Scene, options: IInspectorOptions): void;
|
|
2194
|
+
static HideInspector(scene: Scene): void;
|
|
2195
|
+
private static DisposeInspectorToken;
|
|
2196
|
+
static GetInspectorGlobal(): any;
|
|
2197
|
+
static GetInspectorToken(scene: Scene): any;
|
|
2051
2198
|
static GetLocalStorageItem(key: string): string;
|
|
2052
2199
|
static SetLocalStorageItem(key: string, value: string): void;
|
|
2053
2200
|
static GetSessionStorageItem(key: string): string;
|
|
@@ -2058,6 +2205,9 @@ export declare class WindowManager {
|
|
|
2058
2205
|
static SetVirtualRealityEnabled(enabled: boolean): void;
|
|
2059
2206
|
static SetWindowsLaunchMode(mode?: number): void;
|
|
2060
2207
|
static GetHardwareScalingLevel(): number;
|
|
2208
|
+
private static devicePixelRatioWatches;
|
|
2209
|
+
static IsDevicePixelRatioWatched(engine: any): boolean;
|
|
2210
|
+
static WatchDevicePixelRatio(engine: any, onChange?: (ratio: number, level: number) => void): () => void;
|
|
2061
2211
|
static QuitWindowsApplication(): void;
|
|
2062
2212
|
static PrintToScreen(text: string, color?: string, duration?: number): void;
|
|
2063
2213
|
private static PrintElement;
|
|
@@ -2066,6 +2216,8 @@ export declare class AnimationState extends ScriptComponent {
|
|
|
2066
2216
|
static FPS: number;
|
|
2067
2217
|
static EXIT: string;
|
|
2068
2218
|
static TIME: number;
|
|
2219
|
+
static KEEP_PHASE: number;
|
|
2220
|
+
static MAX_LOOP_EVENTS_PER_ADVANCE: number;
|
|
2069
2221
|
private _looptime;
|
|
2070
2222
|
private _loopblend;
|
|
2071
2223
|
private _frametime;
|
|
@@ -2134,6 +2286,7 @@ export declare class AnimationState extends ScriptComponent {
|
|
|
2134
2286
|
delayUpdateUntilReady: boolean;
|
|
2135
2287
|
enableAnimations: boolean;
|
|
2136
2288
|
applyRootMotion: boolean;
|
|
2289
|
+
externalClock: boolean;
|
|
2137
2290
|
awakened(): boolean;
|
|
2138
2291
|
initialized(): boolean;
|
|
2139
2292
|
hasRootMotion(): boolean;
|
|
@@ -2172,17 +2325,26 @@ export declare class AnimationState extends ScriptComponent {
|
|
|
2172
2325
|
protected m_vertexAnimationRenderers: Mesh[];
|
|
2173
2326
|
protected m_vertexAnimationController: VertexAnimationController;
|
|
2174
2327
|
protected m_vertexAnimationDefaultClip: string;
|
|
2328
|
+
protected m_vertexAnimationSearchNodes: AbstractMesh[];
|
|
2329
|
+
protected m_animationPaused: boolean;
|
|
2330
|
+
protected m_warnedInvalidDelta: boolean;
|
|
2175
2331
|
constructor(transform: TransformNode, scene: Scene, properties?: any, alias?: string);
|
|
2176
2332
|
protected awake(): void;
|
|
2177
2333
|
protected update(): void;
|
|
2178
2334
|
protected destroy(): void;
|
|
2179
|
-
playDefault(transitionDuration?: number, animationLayer?: number, frameRate?: number): boolean;
|
|
2180
|
-
playAnimation(state: string, transitionDuration?: number, animationLayer?: number, frameRate?: number): boolean;
|
|
2335
|
+
playDefault(transitionDuration?: number, animationLayer?: number, frameRate?: number, normalizedTimeOffset?: number): boolean;
|
|
2336
|
+
playAnimation(state: string, transitionDuration?: number, animationLayer?: number, frameRate?: number, normalizedTimeOffset?: number): boolean;
|
|
2181
2337
|
stopAnimation(animationLayer?: number): boolean;
|
|
2182
2338
|
killAnimations(): boolean;
|
|
2339
|
+
updateAnimation(deltaSeconds: number): void;
|
|
2340
|
+
pauseAnimation(): void;
|
|
2341
|
+
resumeAnimation(): void;
|
|
2342
|
+
getAnimationPaused(): boolean;
|
|
2183
2343
|
setTimelineScrubbing(isScrubbing: boolean): void;
|
|
2184
2344
|
getIsTimelineScrubbing(): boolean;
|
|
2185
|
-
|
|
2345
|
+
setAnimationNormalizedTime(normal: number, animationLayer?: number): boolean;
|
|
2346
|
+
setAnimationTime(seconds: number, animationLayer?: number): boolean;
|
|
2347
|
+
getCurrentAnimationLength(animationLayer?: number): number;
|
|
2186
2348
|
setAnimationSpeed(speed: number): boolean;
|
|
2187
2349
|
setAnimationLoop(loop: boolean): boolean;
|
|
2188
2350
|
hasBool(name: string): boolean;
|
|
@@ -2204,6 +2366,7 @@ export declare class AnimationState extends ScriptComponent {
|
|
|
2204
2366
|
private getMachineState;
|
|
2205
2367
|
private setMachineState;
|
|
2206
2368
|
getCurrentState(layer: number): MachineState;
|
|
2369
|
+
getCurrentAnimationName(animationLayer?: number): string;
|
|
2207
2370
|
getDefaultClips(): any[];
|
|
2208
2371
|
getDefaultSource(): string;
|
|
2209
2372
|
setLayerWeight(layer: number, weight: number): void;
|
|
@@ -2215,9 +2378,19 @@ export declare class AnimationState extends ScriptComponent {
|
|
|
2215
2378
|
private updateAnimationGroups;
|
|
2216
2379
|
private setupSourceAnimationGroups;
|
|
2217
2380
|
private awakeStateMachine;
|
|
2381
|
+
private resolveVertexAnimationRenderer;
|
|
2382
|
+
private getRelativeTransformPath;
|
|
2218
2383
|
private updateStateMachine;
|
|
2219
2384
|
private destroyStateMachine;
|
|
2220
2385
|
private updateAnimationState;
|
|
2386
|
+
private getPublicLayer;
|
|
2387
|
+
private isLayerLooping;
|
|
2388
|
+
private getLayerClipLength;
|
|
2389
|
+
private computeLayerSpeed;
|
|
2390
|
+
private advanceLayerPhase;
|
|
2391
|
+
private static WrapNormal;
|
|
2392
|
+
private countEventCrossings;
|
|
2393
|
+
private resolveVertexAnimationClips;
|
|
2221
2394
|
private updateVertexAnimationLayer;
|
|
2222
2395
|
private updateAnimationTargets;
|
|
2223
2396
|
private updateBlendableTargets;
|
|
@@ -2378,6 +2551,14 @@ export interface IAvatarMask {
|
|
|
2378
2551
|
transformCount: number;
|
|
2379
2552
|
transformPaths: string[];
|
|
2380
2553
|
}
|
|
2554
|
+
export interface IVertexAnimationClipSelection {
|
|
2555
|
+
primaryName: string;
|
|
2556
|
+
secondaryName: string | null;
|
|
2557
|
+
primaryWeight: number;
|
|
2558
|
+
primaryDuration: number;
|
|
2559
|
+
secondaryDuration: number;
|
|
2560
|
+
primaryLooping: boolean;
|
|
2561
|
+
}
|
|
2381
2562
|
export interface IAnimationLayer {
|
|
2382
2563
|
owner: string;
|
|
2383
2564
|
hash: number;
|
|
@@ -2686,13 +2867,172 @@ export declare class RecastCharacterController extends ScriptComponent {
|
|
|
2686
2867
|
turn(angle: number): void;
|
|
2687
2868
|
rotate(x: number, y: number, z: number, w: number): void;
|
|
2688
2869
|
}
|
|
2870
|
+
export interface IChromaticAberrationUnitySettings {
|
|
2871
|
+
intensity: number;
|
|
2872
|
+
fastMode: boolean;
|
|
2873
|
+
}
|
|
2874
|
+
export declare class ChromaticAberrationPlugin {
|
|
2875
|
+
static readonly AmountScale: number;
|
|
2876
|
+
static readonly MinSamples: number;
|
|
2877
|
+
static readonly MaxSamples: number;
|
|
2878
|
+
static readonly ShaderName: string;
|
|
2879
|
+
static readonly ShaderKey: string;
|
|
2880
|
+
private static DefaultSpectralLuts;
|
|
2881
|
+
static PackAmount(intensity: number): number;
|
|
2882
|
+
static SampleCount(diffX: number, diffY: number, width: number, height: number): number;
|
|
2883
|
+
static CornerDisplacement(amount: number): number;
|
|
2884
|
+
static GetFragmentShader(): string;
|
|
2885
|
+
static GetDefaultSpectralLut(scene: Scene): Texture;
|
|
2886
|
+
static ReleaseDefaultSpectralLut(scene: Scene): boolean;
|
|
2887
|
+
static DefaultSpectralLutCount(scene: Scene): number;
|
|
2888
|
+
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
2889
|
+
textureType?: number;
|
|
2890
|
+
intensity?: number;
|
|
2891
|
+
fastMode?: boolean;
|
|
2892
|
+
spectralLutTexture?: Texture;
|
|
2893
|
+
samplingMode?: number;
|
|
2894
|
+
}): PostProcess;
|
|
2895
|
+
}
|
|
2896
|
+
export interface IColorFilterUnitySettings {
|
|
2897
|
+
color: number[];
|
|
2898
|
+
}
|
|
2689
2899
|
export declare class ColorFilterPlugin {
|
|
2900
|
+
private static channel;
|
|
2690
2901
|
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
2691
2902
|
color?: number[] | Color3 | Color4;
|
|
2903
|
+
colorSrgb?: number[] | Color3 | Color4;
|
|
2904
|
+
textureType?: number;
|
|
2692
2905
|
}): PostProcess;
|
|
2693
2906
|
}
|
|
2907
|
+
export interface IColorGradingHdrUnitySettings {
|
|
2908
|
+
postExposure: number;
|
|
2909
|
+
}
|
|
2910
|
+
export declare class ColorGradingHdrPlugin {
|
|
2911
|
+
static readonly LogC: {
|
|
2912
|
+
cut: number;
|
|
2913
|
+
a: number;
|
|
2914
|
+
b: number;
|
|
2915
|
+
c: number;
|
|
2916
|
+
d: number;
|
|
2917
|
+
e: number;
|
|
2918
|
+
f: number;
|
|
2919
|
+
};
|
|
2920
|
+
static readonly DefaultLutSize: number;
|
|
2921
|
+
static readonly ShaderName: string;
|
|
2922
|
+
static readonly ShaderKey: string;
|
|
2923
|
+
static PackPostExposure(ev: number): number;
|
|
2924
|
+
static LinearToLogC(x: number): number;
|
|
2925
|
+
static LogCToLinear(x: number): number;
|
|
2926
|
+
static SrgbToLinear(v: number): number;
|
|
2927
|
+
static PackLutParams(lutSize: number, use3D: boolean): {
|
|
2928
|
+
x: number;
|
|
2929
|
+
y: number;
|
|
2930
|
+
z: number;
|
|
2931
|
+
};
|
|
2932
|
+
static GetFragmentShader(): string;
|
|
2933
|
+
static CreatePostProcess(scene: Scene, camera: Camera, options: {
|
|
2934
|
+
textureType?: number;
|
|
2935
|
+
lut: BaseTexture;
|
|
2936
|
+
lutSize?: number;
|
|
2937
|
+
use3D?: boolean;
|
|
2938
|
+
postExposure?: number;
|
|
2939
|
+
decodeSrgb?: boolean;
|
|
2940
|
+
samplingMode?: number;
|
|
2941
|
+
}): PostProcess;
|
|
2942
|
+
private static inferLutSize;
|
|
2943
|
+
}
|
|
2944
|
+
export interface IBloomUnitySettings {
|
|
2945
|
+
intensity: number;
|
|
2946
|
+
threshold: number;
|
|
2947
|
+
softKnee: number;
|
|
2948
|
+
diffusion: number;
|
|
2949
|
+
scatter?: number;
|
|
2950
|
+
color: number[];
|
|
2951
|
+
volumetype?: string;
|
|
2952
|
+
clamp?: number;
|
|
2953
|
+
highQualityFiltering?: boolean;
|
|
2954
|
+
downscale?: number;
|
|
2955
|
+
maxIterations?: number;
|
|
2956
|
+
}
|
|
2957
|
+
export interface IBloomPyramidState {
|
|
2958
|
+
iterations: number;
|
|
2959
|
+
sampleScale: number;
|
|
2960
|
+
threshold: number[];
|
|
2961
|
+
intensity: number;
|
|
2962
|
+
tint: number[];
|
|
2963
|
+
width: number;
|
|
2964
|
+
height: number;
|
|
2965
|
+
tw: number;
|
|
2966
|
+
th: number;
|
|
2967
|
+
}
|
|
2968
|
+
export interface IBloomUrpPyramidState {
|
|
2969
|
+
mipCount: number;
|
|
2970
|
+
downres: number;
|
|
2971
|
+
threshold: number;
|
|
2972
|
+
knee: number;
|
|
2973
|
+
clampMax: number;
|
|
2974
|
+
scatter: number;
|
|
2975
|
+
intensity: number;
|
|
2976
|
+
tint: number[];
|
|
2977
|
+
hq: number;
|
|
2978
|
+
width: number;
|
|
2979
|
+
height: number;
|
|
2980
|
+
tw: number;
|
|
2981
|
+
th: number;
|
|
2982
|
+
}
|
|
2694
2983
|
export declare class ColoredBloomPlugin {
|
|
2984
|
+
static readonly PrefilterShaderName: string;
|
|
2985
|
+
static readonly DownsampleShaderName: string;
|
|
2986
|
+
static readonly UpsampleShaderName: string;
|
|
2987
|
+
static readonly CompositeShaderName: string;
|
|
2988
|
+
static IntensityMultiplier(): number;
|
|
2989
|
+
static readonly PrefilterShaderKey: string;
|
|
2990
|
+
static readonly DownsampleShaderKey: string;
|
|
2991
|
+
static readonly UpsampleShaderKey: string;
|
|
2992
|
+
static readonly CompositeShaderKey: string;
|
|
2993
|
+
static readonly MaxIterations: number;
|
|
2994
|
+
static readonly HalfMax: number;
|
|
2995
|
+
static readonly Epsilon: number;
|
|
2996
|
+
static readonly DownsampleTaps: number[][];
|
|
2997
|
+
static readonly DownsampleWeights: number[];
|
|
2998
|
+
static readonly TentWeights: number[];
|
|
2999
|
+
static readonly TentDivisor: number;
|
|
3000
|
+
static readonly UrpPrefilterShaderName: string;
|
|
3001
|
+
static readonly UrpBlurHShaderName: string;
|
|
3002
|
+
static readonly UrpBlurVShaderName: string;
|
|
3003
|
+
static readonly UrpUpsampleShaderName: string;
|
|
3004
|
+
static readonly UrpCompositeShaderName: string;
|
|
3005
|
+
static readonly UrpPrefilterShaderKey: string;
|
|
3006
|
+
static readonly UrpBlurHShaderKey: string;
|
|
3007
|
+
static readonly UrpBlurVShaderKey: string;
|
|
3008
|
+
static readonly UrpUpsampleShaderKey: string;
|
|
3009
|
+
static readonly UrpCompositeShaderKey: string;
|
|
3010
|
+
static readonly UrpBlurHWeights: number[];
|
|
3011
|
+
static readonly UrpBlurVOffsets: number[];
|
|
3012
|
+
static readonly UrpBlurVWeights: number[];
|
|
3013
|
+
static UrpLevelRatio(level: number, downres: number): number;
|
|
3014
|
+
static UrpPyramidPassNames(mipCount: number): string[];
|
|
3015
|
+
private static num;
|
|
3016
|
+
private static channel;
|
|
3017
|
+
static LevelRatio(level: number): number;
|
|
3018
|
+
static PyramidPassNames(iterations: number): string[];
|
|
3019
|
+
static GetPyramidShaders(): {
|
|
3020
|
+
prefilter: string;
|
|
3021
|
+
downsample: string;
|
|
3022
|
+
upsample: string;
|
|
3023
|
+
composite: string;
|
|
3024
|
+
};
|
|
3025
|
+
private static registerPyramidShaders;
|
|
3026
|
+
static GetUrpPyramidShaders(): {
|
|
3027
|
+
prefilter: string;
|
|
3028
|
+
blurH: string;
|
|
3029
|
+
blurV: string;
|
|
3030
|
+
upsample: string;
|
|
3031
|
+
composite: string;
|
|
3032
|
+
};
|
|
3033
|
+
private static registerUrpPyramidShaders;
|
|
2695
3034
|
static CreateColoredBloom(scene: Scene, camera: Camera, options?: {
|
|
3035
|
+
textureType?: number;
|
|
2696
3036
|
threshold?: number;
|
|
2697
3037
|
color?: number[] | Color3 | Color4;
|
|
2698
3038
|
weight?: number;
|
|
@@ -2701,7 +3041,128 @@ export declare class ColoredBloomPlugin {
|
|
|
2701
3041
|
passes?: number;
|
|
2702
3042
|
saturation?: number;
|
|
2703
3043
|
downsampleRatio?: number;
|
|
3044
|
+
unity?: IBloomUnitySettings;
|
|
3045
|
+
pyramid?: boolean;
|
|
3046
|
+
urp?: boolean;
|
|
3047
|
+
diffusion?: number;
|
|
3048
|
+
softKnee?: number;
|
|
3049
|
+
iterations?: number;
|
|
3050
|
+
sampleScale?: number;
|
|
3051
|
+
onRebuild?: (chain: any, removed: PostProcess[], added: PostProcess[]) => void;
|
|
2704
3052
|
}): any;
|
|
3053
|
+
private static createPyramid;
|
|
3054
|
+
private static createBlurChain;
|
|
3055
|
+
private static createUrpPyramid;
|
|
3056
|
+
}
|
|
3057
|
+
export interface IFxaaUnitySettings {
|
|
3058
|
+
fastMode: boolean;
|
|
3059
|
+
}
|
|
3060
|
+
export declare class FxaaPlugin {
|
|
3061
|
+
static readonly ShaderName: string;
|
|
3062
|
+
static readonly ShaderKey: string;
|
|
3063
|
+
static readonly LumaShaderName: string;
|
|
3064
|
+
static readonly LumaShaderKey: string;
|
|
3065
|
+
static readonly QualityPreset: number;
|
|
3066
|
+
static readonly FastPreset: number;
|
|
3067
|
+
static readonly QualityPresetSteps: number[];
|
|
3068
|
+
static readonly FastPresetSteps: number[];
|
|
3069
|
+
static readonly QualitySettings: {
|
|
3070
|
+
subpix: number;
|
|
3071
|
+
edgeThreshold: number;
|
|
3072
|
+
edgeThresholdMin: number;
|
|
3073
|
+
};
|
|
3074
|
+
static readonly FastSettings: {
|
|
3075
|
+
subpix: number;
|
|
3076
|
+
edgeThreshold: number;
|
|
3077
|
+
edgeThresholdMin: number;
|
|
3078
|
+
};
|
|
3079
|
+
static readonly LumaCoefficients: number[];
|
|
3080
|
+
static readonly GammaPower: number;
|
|
3081
|
+
static PresetNumber(fast: boolean): number;
|
|
3082
|
+
static PresetSteps(fast: boolean): number[];
|
|
3083
|
+
static PackQuality(fast: boolean): {
|
|
3084
|
+
x: number;
|
|
3085
|
+
y: number;
|
|
3086
|
+
z: number;
|
|
3087
|
+
};
|
|
3088
|
+
static PackRcpFrame(width: number, height: number): {
|
|
3089
|
+
x: number;
|
|
3090
|
+
y: number;
|
|
3091
|
+
};
|
|
3092
|
+
static IsLinearTextureType(textureType: number): boolean;
|
|
3093
|
+
static LinearFromGamma(value: number): number;
|
|
3094
|
+
static GammaFromLinear(value: number): number;
|
|
3095
|
+
static Luminance(r: number, g: number, b: number): number;
|
|
3096
|
+
private static glslFloat;
|
|
3097
|
+
static GetSearchCode(steps: number[], indent?: string): string;
|
|
3098
|
+
static GetLumaShader(): string;
|
|
3099
|
+
static GetFragmentShader(): string;
|
|
3100
|
+
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
3101
|
+
textureType?: number;
|
|
3102
|
+
fastMode?: boolean;
|
|
3103
|
+
samplingMode?: number;
|
|
3104
|
+
}): PostProcess;
|
|
3105
|
+
private static num;
|
|
3106
|
+
}
|
|
3107
|
+
export interface IGrainUnitySettings {
|
|
3108
|
+
intensity: number;
|
|
3109
|
+
size: number;
|
|
3110
|
+
lumContrib: number;
|
|
3111
|
+
colored: boolean;
|
|
3112
|
+
}
|
|
3113
|
+
export declare class GrainPlugin {
|
|
3114
|
+
static readonly IntensityScale: number;
|
|
3115
|
+
static readonly IntensityScaleURP: number;
|
|
3116
|
+
static readonly UrpGrainTextureStd: number;
|
|
3117
|
+
static readonly UrpBakeRawStd: number;
|
|
3118
|
+
static readonly UrpGrainSeed: number;
|
|
3119
|
+
static readonly NoiseSize: number;
|
|
3120
|
+
static readonly UrpNoiseSize: number;
|
|
3121
|
+
static readonly SampleCount: number;
|
|
3122
|
+
static readonly NoiseParameters: number[];
|
|
3123
|
+
static readonly ColoredPhaseOffsets: number[];
|
|
3124
|
+
static readonly PhasePeriod: number;
|
|
3125
|
+
static readonly ShaderName: string;
|
|
3126
|
+
static readonly ShaderKey: string;
|
|
3127
|
+
static readonly BakerName: string;
|
|
3128
|
+
static readonly BakerKey: string;
|
|
3129
|
+
static Halton(index: number, radix: number): number;
|
|
3130
|
+
static IntensityMultiplier(): number;
|
|
3131
|
+
static PackParams1(intensity: number, lumContrib: number, typeMultiplier?: number, intensityScale?: number): {
|
|
3132
|
+
x: number;
|
|
3133
|
+
y: number;
|
|
3134
|
+
};
|
|
3135
|
+
static PackParams2(width: number, height: number, size: number, index: number, noiseSize?: number): {
|
|
3136
|
+
x: number;
|
|
3137
|
+
y: number;
|
|
3138
|
+
z: number;
|
|
3139
|
+
w: number;
|
|
3140
|
+
};
|
|
3141
|
+
static Phase(seconds?: number): number;
|
|
3142
|
+
static LuminanceResponse(r: number, g: number, b: number, lumContrib: number): number;
|
|
3143
|
+
static GetBakerShader(): string;
|
|
3144
|
+
static GetFragmentShader(): string;
|
|
3145
|
+
static Mulberry32(seed: number): () => number;
|
|
3146
|
+
static BuildUrpGrainTexels(size: number, seed?: number, targetStd?: number): Float32Array;
|
|
3147
|
+
static ToHalfFloat(value: number): number;
|
|
3148
|
+
static CreateUrpGrainTexture(scene: Scene, size?: number, seed?: number): Texture;
|
|
3149
|
+
static CreateNoiseTexture(scene: Scene, colored: boolean, film?: boolean): BaseTexture;
|
|
3150
|
+
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
3151
|
+
textureType?: number;
|
|
3152
|
+
intensity?: number;
|
|
3153
|
+
size?: number;
|
|
3154
|
+
lumContrib?: number;
|
|
3155
|
+
colored?: boolean;
|
|
3156
|
+
film?: boolean;
|
|
3157
|
+
typeMultiplier?: number;
|
|
3158
|
+
intensityScale?: number;
|
|
3159
|
+
samplingMode?: number;
|
|
3160
|
+
}): PostProcess;
|
|
3161
|
+
private static halfBuffer;
|
|
3162
|
+
private static halfBits;
|
|
3163
|
+
private static now;
|
|
3164
|
+
private static clamp01;
|
|
3165
|
+
private static num;
|
|
2705
3166
|
}
|
|
2706
3167
|
export declare class btVehicleTuning {
|
|
2707
3168
|
suspensionStiffness: number;
|
|
@@ -3022,7 +3483,23 @@ export declare class btRaycastVehicle {
|
|
|
3022
3483
|
getApproxWheelbaseMeters(): number;
|
|
3023
3484
|
dispose(): void;
|
|
3024
3485
|
}
|
|
3486
|
+
export interface ILensDistortionUnitySettings {
|
|
3487
|
+
intensity: number;
|
|
3488
|
+
intensityX: number;
|
|
3489
|
+
intensityY: number;
|
|
3490
|
+
center: number[];
|
|
3491
|
+
scale: number;
|
|
3492
|
+
volumetype?: string;
|
|
3493
|
+
}
|
|
3025
3494
|
export declare class LensDistortionPlugin {
|
|
3495
|
+
static DeriveModel(unity: ILensDistortionUnitySettings): {
|
|
3496
|
+
distortionIntensity: number;
|
|
3497
|
+
distortionIntensityX: number;
|
|
3498
|
+
distortionIntensityY: number;
|
|
3499
|
+
distortionCenterX: number;
|
|
3500
|
+
distortionCenterY: number;
|
|
3501
|
+
distortionScale: number;
|
|
3502
|
+
};
|
|
3026
3503
|
private _distortionIntensity;
|
|
3027
3504
|
private _distortionIntensityX;
|
|
3028
3505
|
private _distortionIntensityY;
|
|
@@ -3059,7 +3536,6 @@ export declare class LensDistortionPlugin {
|
|
|
3059
3536
|
};
|
|
3060
3537
|
};
|
|
3061
3538
|
getFragmentShaderCode(): string;
|
|
3062
|
-
getWGSLShaderCode(): string;
|
|
3063
3539
|
static CreatePostProcess(scene: any, camera: any, options?: {
|
|
3064
3540
|
distortionIntensity?: number;
|
|
3065
3541
|
distortionIntensityX?: number;
|
|
@@ -3067,8 +3543,91 @@ export declare class LensDistortionPlugin {
|
|
|
3067
3543
|
distortionCenterX?: number;
|
|
3068
3544
|
distortionCenterY?: number;
|
|
3069
3545
|
distortionScale?: number;
|
|
3546
|
+
textureType?: number;
|
|
3547
|
+
unity?: ILensDistortionUnitySettings;
|
|
3070
3548
|
}): any;
|
|
3071
3549
|
}
|
|
3550
|
+
export declare class LightProbeTetraWalker {
|
|
3551
|
+
readonly probeCount: number;
|
|
3552
|
+
readonly tetraCount: number;
|
|
3553
|
+
readonly positions: Float32Array;
|
|
3554
|
+
readonly probeSh: Float32Array;
|
|
3555
|
+
readonly indices: Int32Array;
|
|
3556
|
+
readonly adjacency: Int32Array;
|
|
3557
|
+
maxWalkSteps: number;
|
|
3558
|
+
lastSteps: number;
|
|
3559
|
+
lastClamped: boolean;
|
|
3560
|
+
readonly weights: Float32Array;
|
|
3561
|
+
private readonly _probeTetra;
|
|
3562
|
+
constructor(positions: Float32Array, probeSh: Float32Array, indices: Int32Array, adjacency: Int32Array);
|
|
3563
|
+
nearestProbe(px: number, py: number, pz: number): number;
|
|
3564
|
+
locate(px: number, py: number, pz: number, startTet: number): number;
|
|
3565
|
+
private _clampWeights;
|
|
3566
|
+
blend(tet: number, scale: number, out: Float32Array, outOffset: number): void;
|
|
3567
|
+
sample(px: number, py: number, pz: number, startTet: number, scale: number, out: Float32Array, outOffset: number): number;
|
|
3568
|
+
}
|
|
3569
|
+
export declare class LightProbeNetwork extends ScriptComponent {
|
|
3570
|
+
static MoveThreshold: number;
|
|
3571
|
+
static MaxWalkSteps: number;
|
|
3572
|
+
private static readonly Sections;
|
|
3573
|
+
private _url;
|
|
3574
|
+
private _probeCount;
|
|
3575
|
+
private _tetraCount;
|
|
3576
|
+
private _rendererCount;
|
|
3577
|
+
private _scale;
|
|
3578
|
+
private _walker;
|
|
3579
|
+
private _rendererSh;
|
|
3580
|
+
private _rendererOcclusion;
|
|
3581
|
+
private _rendererAnchor;
|
|
3582
|
+
private _networkActive;
|
|
3583
|
+
private _networkReason;
|
|
3584
|
+
private _networkAwake;
|
|
3585
|
+
private _networkLoaded;
|
|
3586
|
+
private _networkAttached;
|
|
3587
|
+
private _networkLoadRequested;
|
|
3588
|
+
private _dynMeshes;
|
|
3589
|
+
private _dynCount;
|
|
3590
|
+
private _dynTet;
|
|
3591
|
+
private _dynLast;
|
|
3592
|
+
private _dynAnchor;
|
|
3593
|
+
private _dynHasAnchor;
|
|
3594
|
+
private _staticCount;
|
|
3595
|
+
private _pending;
|
|
3596
|
+
private _newMeshObserver;
|
|
3597
|
+
private _bakedLights;
|
|
3598
|
+
private _lastWalkSteps;
|
|
3599
|
+
private _tmp;
|
|
3600
|
+
private _nearestWarned;
|
|
3601
|
+
private static SetRider;
|
|
3602
|
+
static Get(scene: Scene): LightProbeNetwork;
|
|
3603
|
+
constructor(transform: TransformNode, scene: Scene, properties?: any, alias?: string);
|
|
3604
|
+
private readProperties;
|
|
3605
|
+
addPreloaderTasks(assetsManager: PreloadAssetsManager): void;
|
|
3606
|
+
protected awake(): void;
|
|
3607
|
+
private selfLoad;
|
|
3608
|
+
protected late(): void;
|
|
3609
|
+
protected destroy(): void;
|
|
3610
|
+
isActive(): boolean;
|
|
3611
|
+
getDisabledReason(): string;
|
|
3612
|
+
getProbeCount(): number;
|
|
3613
|
+
getTetraCount(): number;
|
|
3614
|
+
getRendererCount(): number;
|
|
3615
|
+
getStaticCount(): number;
|
|
3616
|
+
getDynamicCount(): number;
|
|
3617
|
+
getLastWalkSteps(): number;
|
|
3618
|
+
getWalker(): LightProbeTetraWalker;
|
|
3619
|
+
attach(mesh: AbstractMesh, dynamic: boolean): boolean;
|
|
3620
|
+
detach(mesh: AbstractMesh): void;
|
|
3621
|
+
sampleMeshNow(mesh: AbstractMesh): number;
|
|
3622
|
+
private sampleDynamic;
|
|
3623
|
+
private ensureCapacity;
|
|
3624
|
+
private probeKeyOf;
|
|
3625
|
+
evaluateAt(px: number, py: number, pz: number, out: Float32Array): number;
|
|
3626
|
+
private tryAttachAll;
|
|
3627
|
+
private disable;
|
|
3628
|
+
private sceneLabel;
|
|
3629
|
+
private onDataLoaded;
|
|
3630
|
+
}
|
|
3072
3631
|
export declare class NavigationAgent extends ScriptComponent {
|
|
3073
3632
|
static TARGET_ANGLE_FACTOR: number;
|
|
3074
3633
|
static ANGULAR_SPEED_RATIO: number;
|
|
@@ -3100,6 +3659,11 @@ export declare class NavigationAgent extends ScriptComponent {
|
|
|
3100
3659
|
private m_stuckCounter;
|
|
3101
3660
|
private m_reachObserver;
|
|
3102
3661
|
private m_navMeshDestroyObserver;
|
|
3662
|
+
private m_navAreasObserver;
|
|
3663
|
+
private m_areaCosts;
|
|
3664
|
+
private m_filterSlot;
|
|
3665
|
+
private static CROWD_FILTER_SLOTS;
|
|
3666
|
+
private static CROWD_FILTER_WARNED;
|
|
3103
3667
|
speed: number;
|
|
3104
3668
|
reachRadius: number;
|
|
3105
3669
|
heightOffset: number;
|
|
@@ -3154,6 +3718,9 @@ export declare class NavigationAgent extends ScriptComponent {
|
|
|
3154
3718
|
private getLookAtStopDistance;
|
|
3155
3719
|
private updateAgentParameters;
|
|
3156
3720
|
private applyAgentUpdateFlags;
|
|
3721
|
+
private applyAgentFilter;
|
|
3722
|
+
private refreshAgentPolicy;
|
|
3723
|
+
private getFilteredClosestPoint;
|
|
3157
3724
|
private destroyNavigationAgent;
|
|
3158
3725
|
move(offset: Vector3, closetPoint?: boolean): void;
|
|
3159
3726
|
teleport(destination: Vector3, closetPoint?: boolean, initialRotation?: Quaternion): void;
|
|
@@ -3174,6 +3741,12 @@ export declare class NavigationAgent extends ScriptComponent {
|
|
|
3174
3741
|
getAgentWaypointToRef(result: Vector3): void;
|
|
3175
3742
|
cancelNavigation(): void;
|
|
3176
3743
|
releaseNavigationCrowd(): void;
|
|
3744
|
+
setAreaMask(areaMask: number): void;
|
|
3745
|
+
getAreaMask(): number;
|
|
3746
|
+
setAreaCost(area: number, cost: number): void;
|
|
3747
|
+
getAreaCost(area: number): number;
|
|
3748
|
+
resetAreaCosts(): void;
|
|
3749
|
+
getQueryFilter(): any;
|
|
3177
3750
|
getDebugDestinationMesh(): Mesh;
|
|
3178
3751
|
showDebugDestination(show: boolean): void;
|
|
3179
3752
|
}
|
|
@@ -3189,69 +3762,882 @@ export declare enum NavMoveStatus {
|
|
|
3189
3762
|
Stuck = "stuck",
|
|
3190
3763
|
Cancelled = "cancelled"
|
|
3191
3764
|
}
|
|
3765
|
+
export interface IPostProcessColorGradingState {
|
|
3766
|
+
camera: string;
|
|
3767
|
+
configuration: ImageProcessingConfiguration;
|
|
3768
|
+
expected: {
|
|
3769
|
+
exposure?: number;
|
|
3770
|
+
contrast?: number;
|
|
3771
|
+
globalSaturation?: number;
|
|
3772
|
+
colorCurvesEnabled?: boolean;
|
|
3773
|
+
toneMappingEnabled?: boolean;
|
|
3774
|
+
toneMappingType?: number;
|
|
3775
|
+
colorGradingEnabled?: boolean;
|
|
3776
|
+
ditheringEnabled?: boolean;
|
|
3777
|
+
ditheringIntensity?: number;
|
|
3778
|
+
};
|
|
3779
|
+
lutUrl: string;
|
|
3780
|
+
colorFilter: number[];
|
|
3781
|
+
hdr?: boolean;
|
|
3782
|
+
dropped?: boolean;
|
|
3783
|
+
}
|
|
3784
|
+
export interface IPostProcessImagingSnapshot {
|
|
3785
|
+
configuration: ImageProcessingConfiguration;
|
|
3786
|
+
key: string;
|
|
3787
|
+
curve: boolean;
|
|
3788
|
+
value: any;
|
|
3789
|
+
camera: string;
|
|
3790
|
+
}
|
|
3791
|
+
export interface IPostProcessStackFlags {
|
|
3792
|
+
vignetteActive: boolean;
|
|
3793
|
+
hdrGrading: boolean;
|
|
3794
|
+
hdrReason: string;
|
|
3795
|
+
}
|
|
3796
|
+
export interface IPostProcessInspectorField {
|
|
3797
|
+
key: string;
|
|
3798
|
+
label: string;
|
|
3799
|
+
kind: "number" | "switch" | "text";
|
|
3800
|
+
unit?: string;
|
|
3801
|
+
min?: number;
|
|
3802
|
+
max?: number;
|
|
3803
|
+
step?: number;
|
|
3804
|
+
readOnly?: boolean;
|
|
3805
|
+
description?: string;
|
|
3806
|
+
get(): any;
|
|
3807
|
+
set?(value: any): void;
|
|
3808
|
+
}
|
|
3809
|
+
export interface IPostProcessInspectorEffect {
|
|
3810
|
+
camera: Camera;
|
|
3811
|
+
family: string;
|
|
3812
|
+
unityEffect: string;
|
|
3813
|
+
order: number;
|
|
3814
|
+
applied: boolean;
|
|
3815
|
+
target: string;
|
|
3816
|
+
reason?: string;
|
|
3817
|
+
enabled: boolean;
|
|
3818
|
+
fields: IPostProcessInspectorField[];
|
|
3819
|
+
}
|
|
3820
|
+
export interface IPostProcessLutEntry {
|
|
3821
|
+
strip: Texture;
|
|
3822
|
+
ready: BaseTexture;
|
|
3823
|
+
waiting: ((texture: BaseTexture) => void)[];
|
|
3824
|
+
}
|
|
3825
|
+
export interface IPostProcessPluginTextureEntry {
|
|
3826
|
+
texture: Texture;
|
|
3827
|
+
ready: boolean;
|
|
3828
|
+
failed: boolean;
|
|
3829
|
+
waiting: ((texture: Texture) => void)[];
|
|
3830
|
+
}
|
|
3831
|
+
export interface IPostProcessBloomRecord {
|
|
3832
|
+
camera: Camera;
|
|
3833
|
+
chain: any;
|
|
3834
|
+
color: number[];
|
|
3835
|
+
weight: number;
|
|
3836
|
+
threshold: number;
|
|
3837
|
+
kernel: number;
|
|
3838
|
+
iterations: number;
|
|
3839
|
+
sampleScale: number;
|
|
3840
|
+
mipCount?: number;
|
|
3841
|
+
scatter?: number;
|
|
3842
|
+
}
|
|
3192
3843
|
export declare class PostProcessor extends ScriptComponent {
|
|
3193
3844
|
private static GlobalInstance;
|
|
3845
|
+
private static Registry;
|
|
3846
|
+
private static Warned;
|
|
3847
|
+
private static Scheduled;
|
|
3194
3848
|
static get Instance(): PostProcessor;
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
|
|
3206
|
-
|
|
3207
|
-
|
|
3208
|
-
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3212
|
-
|
|
3213
|
-
|
|
3214
|
-
|
|
3215
|
-
|
|
3849
|
+
static get Volumes(): PostProcessor[];
|
|
3850
|
+
static readonly PipelinePrefix: string;
|
|
3851
|
+
static LutInvertY: boolean;
|
|
3852
|
+
static LutSamplingMode: number;
|
|
3853
|
+
static LutUse3D: boolean;
|
|
3854
|
+
static ForceScreenSpaceReflections: boolean;
|
|
3855
|
+
static Dithering: boolean;
|
|
3856
|
+
static HalfFloatChain: boolean;
|
|
3857
|
+
static InspectorSection: boolean;
|
|
3858
|
+
static InspectorState: {
|
|
3859
|
+
available: boolean;
|
|
3860
|
+
registered: boolean;
|
|
3861
|
+
};
|
|
3862
|
+
static readonly HeadSlots: {
|
|
3863
|
+
motionBlur: number;
|
|
3864
|
+
lensDistortion: number;
|
|
3865
|
+
chromaticAberration: number;
|
|
3866
|
+
bloom: number;
|
|
3867
|
+
vignette: number;
|
|
3868
|
+
grain: number;
|
|
3869
|
+
grading: number;
|
|
3870
|
+
grainAfterGrading: number;
|
|
3871
|
+
};
|
|
3872
|
+
static readonly TailSlotBase: number;
|
|
3873
|
+
static readonly TailSlots: {
|
|
3874
|
+
fxaa: number;
|
|
3875
|
+
};
|
|
3876
|
+
static IsTailSlot(slot: number): boolean;
|
|
3877
|
+
static readonly BuiltInPipeline: string;
|
|
3878
|
+
static readonly SrpPipelines: string[];
|
|
3879
|
+
static VolumeTypeOf(model: any): string;
|
|
3880
|
+
static IsSrpVolume(model: any): boolean;
|
|
3881
|
+
static warnOnce(key: string, message: string): void;
|
|
3882
|
+
static hasWarned(key: string): boolean;
|
|
3883
|
+
private volumeProperties;
|
|
3884
|
+
private volumeLayer;
|
|
3885
|
+
private orchestrator;
|
|
3886
|
+
private applied;
|
|
3887
|
+
private readyCalled;
|
|
3888
|
+
private stacks;
|
|
3216
3889
|
private defaultRenderPipeline;
|
|
3217
3890
|
private screenSpaceAOPipeline;
|
|
3218
3891
|
private screenSpaceRPipeline;
|
|
3892
|
+
private ownedPipelines;
|
|
3893
|
+
private reusedPipelines;
|
|
3894
|
+
private ownedRenderPipelines;
|
|
3895
|
+
private ownedPostProcesses;
|
|
3896
|
+
private ownedTextures;
|
|
3897
|
+
private lutTextures;
|
|
3898
|
+
private pendingPlugins;
|
|
3899
|
+
private buildObservers;
|
|
3900
|
+
private reordering;
|
|
3901
|
+
private frontPostProcesses;
|
|
3902
|
+
private frontSlots;
|
|
3903
|
+
private tailPostProcesses;
|
|
3904
|
+
private tailSlots;
|
|
3905
|
+
private fxaas;
|
|
3906
|
+
private coloredBloom;
|
|
3907
|
+
private vignettes;
|
|
3908
|
+
private chromaticAberrations;
|
|
3909
|
+
private grains;
|
|
3910
|
+
private hdrGradings;
|
|
3911
|
+
private pluginTextures;
|
|
3912
|
+
private depthOfFields;
|
|
3913
|
+
private motionBlurs;
|
|
3914
|
+
private lensDistortions;
|
|
3915
|
+
private lensUnitySettings;
|
|
3916
|
+
private antialiasings;
|
|
3917
|
+
private ambientOcclusions;
|
|
3918
|
+
private ditherings;
|
|
3919
|
+
private screenSpaceReflections;
|
|
3920
|
+
private ssrGates;
|
|
3921
|
+
private gradingStates;
|
|
3922
|
+
private gradingDrift;
|
|
3923
|
+
private effectListings;
|
|
3924
|
+
private effectEnabled;
|
|
3925
|
+
private toggleOrders;
|
|
3926
|
+
private detachedPasses;
|
|
3927
|
+
private toggleSaved;
|
|
3928
|
+
private imagingSnapshots;
|
|
3929
|
+
private imagingWrites;
|
|
3930
|
+
private droppedGradingStates;
|
|
3931
|
+
private gradingReadBackScheduled;
|
|
3932
|
+
private disposed;
|
|
3219
3933
|
GetDefaultRenderPipeline(): DefaultRenderingPipeline;
|
|
3220
|
-
GetSSAORRenderPipeline():
|
|
3934
|
+
GetSSAORRenderPipeline(): SSAO2RenderingPipeline;
|
|
3221
3935
|
GetSSRRenderPipeline(): SSRRenderingPipeline;
|
|
3222
|
-
|
|
3936
|
+
GetVolumeProperties(): IPostProcessVolumeProperties;
|
|
3937
|
+
GetVolumeLayer(): number;
|
|
3938
|
+
IsOrchestrator(): boolean;
|
|
3939
|
+
GetCameraStacks(): {
|
|
3940
|
+
camera: Camera;
|
|
3941
|
+
stack: IPostProcessStack;
|
|
3942
|
+
pipeline: DefaultRenderingPipeline;
|
|
3943
|
+
}[];
|
|
3944
|
+
protected awake(): void;
|
|
3223
3945
|
protected ready(): void;
|
|
3224
|
-
|
|
3225
|
-
protected
|
|
3226
|
-
|
|
3946
|
+
private tryOrchestrate;
|
|
3947
|
+
protected destroy(): void;
|
|
3948
|
+
applyVolumes(): void;
|
|
3949
|
+
getOrCreatePipeline(camera: Camera, hdr: boolean): DefaultRenderingPipeline;
|
|
3950
|
+
protected watchPipelineBuilds(pipeline: DefaultRenderingPipeline): void;
|
|
3951
|
+
protected registerPass(camera: Camera, passes: PostProcess[], slot: number): void;
|
|
3952
|
+
static CompactChain(camera: Camera): void;
|
|
3953
|
+
protected screenSpacePasses(camera: Camera): PostProcess[];
|
|
3954
|
+
reorderPluginPasses(pipeline: DefaultRenderingPipeline): number;
|
|
3955
|
+
protected placeTailPasses(camera: Camera): number;
|
|
3956
|
+
static FindDefaultPipeline(scene: Scene, camera: Camera): DefaultRenderingPipeline;
|
|
3957
|
+
static readonly Consumes: {
|
|
3958
|
+
[family: string]: string[];
|
|
3959
|
+
};
|
|
3960
|
+
static readonly ConsumesUrp: {
|
|
3961
|
+
[family: string]: string[];
|
|
3962
|
+
};
|
|
3963
|
+
private applyStack;
|
|
3964
|
+
static ChainTextureType(scene: Scene, metadata: IPostProcessCameraMetadata, pipeline?: DefaultRenderingPipeline): number;
|
|
3965
|
+
static DeriveStackFlags(model: IPostProcessModel, metadata: IPostProcessCameraMetadata): IPostProcessStackFlags;
|
|
3966
|
+
protected applyAntialiasing(camera: Camera, pipeline: DefaultRenderingPipeline, metadata: IPostProcessCameraMetadata, textureType?: number): void;
|
|
3967
|
+
protected applySamplesToFirstPass(camera: Camera): void;
|
|
3968
|
+
static StripLacksToneMapper(lut: IPostProcessLutReference): boolean;
|
|
3969
|
+
GetAntialiasings(): {
|
|
3970
|
+
pipeline: DefaultRenderingPipeline;
|
|
3971
|
+
camera: Camera;
|
|
3972
|
+
mode: number;
|
|
3973
|
+
fxaa: boolean;
|
|
3974
|
+
samples: number;
|
|
3975
|
+
firstPass: PostProcess;
|
|
3976
|
+
prePassSamples?: number;
|
|
3977
|
+
fxaaPass?: PostProcess;
|
|
3978
|
+
lumaPass?: PostProcess;
|
|
3979
|
+
fast?: boolean;
|
|
3980
|
+
}[];
|
|
3981
|
+
protected applyColorGrading(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number, flags?: IPostProcessStackFlags): void;
|
|
3982
|
+
protected applyHdrColorGrading(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, imaging: ImageProcessingConfiguration, textureType: number): void;
|
|
3983
|
+
protected applyDithering(camera: Camera, pipeline: DefaultRenderingPipeline): void;
|
|
3984
|
+
GetDitherings(): {
|
|
3985
|
+
camera: Camera;
|
|
3986
|
+
configuration: ImageProcessingConfiguration;
|
|
3227
3987
|
enabled: boolean;
|
|
3228
|
-
|
|
3988
|
+
intensity: number;
|
|
3989
|
+
}[];
|
|
3990
|
+
protected writeImaging(configuration: ImageProcessingConfiguration, key: string, value: any, camera?: string): void;
|
|
3991
|
+
protected restoreImagingFor(camera: string, configuration: ImageProcessingConfiguration): string[];
|
|
3992
|
+
protected assertGradingState(state: IPostProcessColorGradingState): void;
|
|
3993
|
+
protected restoreImaging(): void;
|
|
3994
|
+
GetImagingSnapshots(): IPostProcessImagingSnapshot[];
|
|
3995
|
+
static GetImageProcessing(scene: Scene, pipeline: DefaultRenderingPipeline): ImageProcessingConfiguration;
|
|
3996
|
+
static ToColorArray(value: any): number[];
|
|
3997
|
+
protected requestLutTexture(lut: IPostProcessLutReference, apply: (texture: BaseTexture) => void): void;
|
|
3998
|
+
protected requestPluginTexture(url: string, purpose: string, apply: (texture: Texture) => void): void;
|
|
3999
|
+
private finalizeLutTexture;
|
|
4000
|
+
static RepackLutStrip(pixels: Uint8Array, width: number, height: number): Uint8Array;
|
|
4001
|
+
static ResolveSceneUrl(scene: Scene, url: string): string;
|
|
4002
|
+
private scheduleGradingReadBack;
|
|
4003
|
+
verifyColorGrading(reassert?: boolean): string[];
|
|
4004
|
+
GetColorGradingDrift(): {
|
|
4005
|
+
camera: string;
|
|
4006
|
+
keys: string[];
|
|
4007
|
+
}[];
|
|
4008
|
+
private pushGradingState;
|
|
4009
|
+
GetColorGradingStates(): IPostProcessColorGradingState[];
|
|
4010
|
+
protected applyBloom(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number, flags?: IPostProcessStackFlags): void;
|
|
4011
|
+
static ChainPasses(chain: any): PostProcess[];
|
|
4012
|
+
protected rechainBloom(camera: Camera, chain: any, removed: PostProcess[], added: PostProcess[]): void;
|
|
4013
|
+
private forgetPostProcesses;
|
|
4014
|
+
protected applyVignette(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4015
|
+
protected applyChromaticAberration(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4016
|
+
protected applyGrain(camera: Camera, pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4017
|
+
protected applySharpen(pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel): void;
|
|
4018
|
+
protected fieldValue(family: IPostProcessEffectModel, name: string): any;
|
|
4019
|
+
protected fieldOverridden(family: IPostProcessEffectModel, name: string): boolean;
|
|
4020
|
+
protected warnUnconsumedFields(family: IPostProcessEffectModel, extra?: string[]): void;
|
|
4021
|
+
protected warnUnsupportedFields(family: IPostProcessEffectModel, names: string[]): void;
|
|
4022
|
+
static ToVector2Array(value: any, fallback: number[]): number[];
|
|
4023
|
+
GetColoredBloomChains(): IPostProcessBloomRecord[];
|
|
4024
|
+
GetVignettes(): {
|
|
4025
|
+
camera: Camera;
|
|
4026
|
+
postProcess: PostProcess;
|
|
4027
|
+
center: number[];
|
|
4028
|
+
intensity: number;
|
|
4029
|
+
smoothness: number;
|
|
4030
|
+
roundness: number;
|
|
4031
|
+
rounded: boolean;
|
|
4032
|
+
color: number[];
|
|
4033
|
+
distortion: IVignetteDistortion;
|
|
4034
|
+
}[];
|
|
4035
|
+
GetChromaticAberrations(): {
|
|
4036
|
+
camera: Camera;
|
|
4037
|
+
postProcess: PostProcess;
|
|
4038
|
+
intensity: number;
|
|
4039
|
+
fastMode: boolean;
|
|
4040
|
+
spectralLutUrl: string;
|
|
4041
|
+
spectralLut: BaseTexture;
|
|
4042
|
+
}[];
|
|
4043
|
+
GetGrains(): {
|
|
4044
|
+
camera: Camera;
|
|
4045
|
+
postProcess: PostProcess;
|
|
4046
|
+
intensity: number;
|
|
4047
|
+
size: number;
|
|
4048
|
+
lumContrib: number;
|
|
4049
|
+
colored: boolean;
|
|
4050
|
+
typeMultiplier: number;
|
|
4051
|
+
noise: BaseTexture;
|
|
4052
|
+
}[];
|
|
4053
|
+
GetHdrGradings(): {
|
|
4054
|
+
camera: Camera;
|
|
4055
|
+
postProcess: PostProcess;
|
|
4056
|
+
lutUrl: string;
|
|
4057
|
+
postExposure: number;
|
|
4058
|
+
decodeSrgb: boolean;
|
|
4059
|
+
use3D: boolean;
|
|
4060
|
+
lutSize: number;
|
|
4061
|
+
}[];
|
|
4062
|
+
GetHeadPasses(): {
|
|
4063
|
+
postProcess: PostProcess;
|
|
4064
|
+
slot: number;
|
|
4065
|
+
}[];
|
|
4066
|
+
GetTailPasses(): {
|
|
4067
|
+
postProcess: PostProcess;
|
|
4068
|
+
slot: number;
|
|
4069
|
+
}[];
|
|
4070
|
+
GetFxaaPasses(): {
|
|
4071
|
+
camera: Camera;
|
|
4072
|
+
postProcess: PostProcess;
|
|
4073
|
+
lumaPass: PostProcess;
|
|
4074
|
+
fastMode: boolean;
|
|
4075
|
+
}[];
|
|
4076
|
+
protected applyDepthOfField(pipeline: DefaultRenderingPipeline, family: IPostProcessEffectModel, model: IPostProcessModel, metadata?: IPostProcessCameraMetadata): void;
|
|
4077
|
+
protected applyMotionBlur(camera: Camera, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4078
|
+
static FindMotionBlur(camera: Camera): MotionBlurPostProcess;
|
|
4079
|
+
protected applyLensDistortion(camera: Camera, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4080
|
+
protected deriveLensDistortionOptions(family: IPostProcessEffectModel, model: IPostProcessModel): any;
|
|
4081
|
+
protected deriveLensUnitySettings(family: IPostProcessEffectModel, model: IPostProcessModel): ILensDistortionUnitySettings;
|
|
4082
|
+
protected getLensUnitySettings(camera: Camera, model: IPostProcessModel): ILensDistortionUnitySettings;
|
|
4083
|
+
GetLensUnitySettings(): {
|
|
4084
|
+
camera: Camera;
|
|
4085
|
+
settings: ILensDistortionUnitySettings;
|
|
4086
|
+
}[];
|
|
4087
|
+
GetDepthOfFields(): {
|
|
4088
|
+
pipeline: DefaultRenderingPipeline;
|
|
4089
|
+
focusDistance: number;
|
|
4090
|
+
fStop: number;
|
|
4091
|
+
focalLength: number;
|
|
4092
|
+
blurLevel: number;
|
|
4093
|
+
}[];
|
|
4094
|
+
GetMotionBlurs(): {
|
|
4095
|
+
camera: Camera;
|
|
4096
|
+
postProcess: MotionBlurPostProcess;
|
|
4097
|
+
reused: boolean;
|
|
4098
|
+
motionStrength: number;
|
|
4099
|
+
motionBlurSamples: number;
|
|
4100
|
+
isObjectBased: boolean;
|
|
4101
|
+
}[];
|
|
4102
|
+
GetLensDistortions(): {
|
|
4103
|
+
camera: Camera;
|
|
4104
|
+
postProcess: PostProcess;
|
|
4105
|
+
options: any;
|
|
4106
|
+
}[];
|
|
4107
|
+
protected applyAmbientOcclusion(camera: Camera, family: IPostProcessEffectModel, model: IPostProcessModel, textureType: number): void;
|
|
4108
|
+
protected applyScreenSpaceReflections(camera: Camera, family: IPostProcessEffectModel, model: IPostProcessModel, metadata: IPostProcessCameraMetadata, textureType: number): void;
|
|
4109
|
+
protected releaseScreenSpaceReflections(camera: Camera): void;
|
|
4110
|
+
protected applyHdrpExposure(family: IPostProcessEffectModel): void;
|
|
4111
|
+
static FindRenderPipeline(scene: Scene, camera: Camera, ctor: any): PostProcessRenderPipeline;
|
|
4112
|
+
protected detachLegacyPipeline(camera: Camera, legacyCtor: any, replacementCtor: any, label: string): void;
|
|
4113
|
+
GetAmbientOcclusions(): {
|
|
4114
|
+
camera: Camera;
|
|
4115
|
+
pipeline: SSAO2RenderingPipeline;
|
|
4116
|
+
reused: boolean;
|
|
4117
|
+
settings: IPostProcessSsao;
|
|
4118
|
+
}[];
|
|
4119
|
+
GetScreenSpaceReflections(): {
|
|
4120
|
+
camera: Camera;
|
|
4121
|
+
pipeline: SSRRenderingPipeline;
|
|
4122
|
+
reused: boolean;
|
|
4123
|
+
settings: IPostProcessSsr;
|
|
4124
|
+
}[];
|
|
4125
|
+
GetSsrGates(): IPostProcessSsrGate[];
|
|
4126
|
+
static readonly EffectOrders: {
|
|
4127
|
+
[family: string]: number;
|
|
4128
|
+
};
|
|
4129
|
+
static readonly AntialiasingEffectName: string;
|
|
4130
|
+
onEffectListingChangedObservable: Observable<PostProcessor>;
|
|
4131
|
+
GetEffectListings(): {
|
|
4132
|
+
camera: Camera;
|
|
4133
|
+
effects: IPostProcessInspectorEffect[];
|
|
4134
|
+
}[];
|
|
4135
|
+
GetEffectListing(camera: Camera): IPostProcessInspectorEffect[];
|
|
4136
|
+
IsEffectEnabled(camera: Camera, family: string): boolean;
|
|
4137
|
+
protected setEffectEnabledFlag(camera: Camera, family: string, enabled: boolean): void;
|
|
4138
|
+
protected rebuildEffectListing(camera: Camera): void;
|
|
4139
|
+
protected notifyEffectListing(): void;
|
|
4140
|
+
private buildEffectListing;
|
|
4141
|
+
private listingRow;
|
|
4142
|
+
private numberField;
|
|
4143
|
+
private switchField;
|
|
4144
|
+
private textField;
|
|
4145
|
+
private colorFields;
|
|
4146
|
+
private enumLabel;
|
|
4147
|
+
private listingValues;
|
|
4148
|
+
private static fmt;
|
|
4149
|
+
private listGrain;
|
|
4150
|
+
private listVignette;
|
|
4151
|
+
private listChromaticAberration;
|
|
4152
|
+
private listBloom;
|
|
4153
|
+
private listColorGrading;
|
|
4154
|
+
private listDepthOfField;
|
|
4155
|
+
private listMotionBlur;
|
|
4156
|
+
private listLensDistortion;
|
|
4157
|
+
private listAmbientOcclusion;
|
|
4158
|
+
private listScreenSpaceReflections;
|
|
4159
|
+
private listSharpen;
|
|
4160
|
+
private listAntialiasing;
|
|
4161
|
+
static readonly ToggleFamilies: string[];
|
|
4162
|
+
SetEffectEnabled(camera: Camera, family: string, enabled: boolean): boolean;
|
|
4163
|
+
GetToggleOrder(camera: Camera): PostProcess[];
|
|
4164
|
+
private pipelineOf;
|
|
4165
|
+
private pluginNameOf;
|
|
4166
|
+
private spliceIntoToggleOrder;
|
|
4167
|
+
private recordToggleOrder;
|
|
4168
|
+
private toggleOwnedPasses;
|
|
4169
|
+
private togglePasses;
|
|
4170
|
+
private togglePipelineFlag;
|
|
4171
|
+
private toggleImagingGrade;
|
|
4172
|
+
private toggleRenderPipeline;
|
|
4173
|
+
protected trackPostProcess(postProcess: PostProcess, camera: Camera): void;
|
|
4174
|
+
protected trackTexture(texture: BaseTexture): void;
|
|
4175
|
+
protected trackRenderPipeline(pipeline: PostProcessRenderPipeline): void;
|
|
4176
|
+
protected releaseStacks(): void;
|
|
4177
|
+
static GlslangWatchdog: boolean;
|
|
4178
|
+
static GlslangStallDelay: number;
|
|
4179
|
+
static GlslangRetryTimeout: number;
|
|
4180
|
+
static GlslangRetryBackoff: number[];
|
|
4181
|
+
static readonly GlslangWarningKey: string;
|
|
4182
|
+
static GlslangClock: () => number;
|
|
4183
|
+
static GlslangSchedule: (callback: () => void, ms: number) => any;
|
|
4184
|
+
private glslangObserver;
|
|
4185
|
+
private glslangObserverScene;
|
|
4186
|
+
private glslangToken;
|
|
4187
|
+
private glslangStuckSince;
|
|
4188
|
+
private glslangState;
|
|
4189
|
+
static GlslangEngine(scene: Scene): any;
|
|
4190
|
+
GetGlslangWatchdogState(): {
|
|
4191
|
+
armed: boolean;
|
|
4192
|
+
attempts: number;
|
|
4193
|
+
running: boolean;
|
|
4194
|
+
failed: boolean;
|
|
4195
|
+
recovered: boolean;
|
|
4196
|
+
reason: string;
|
|
4197
|
+
rebuilt: string[];
|
|
4198
|
+
stuckPasses: string[];
|
|
4199
|
+
};
|
|
4200
|
+
GetGlslangStuckPasses(): PostProcess[];
|
|
4201
|
+
protected armGlslangWatchdog(): void;
|
|
4202
|
+
protected checkGlslangWatchdog(): void;
|
|
4203
|
+
private startGlslangRetry;
|
|
4204
|
+
static ResetGlslangScriptCaches(engine: any): string[];
|
|
4205
|
+
private recoverGlslang;
|
|
4206
|
+
private failGlslang;
|
|
4207
|
+
static RebuildGlslangPasses(engine: any, passes: PostProcess[]): string[];
|
|
4208
|
+
private annotateGlslangReasons;
|
|
4209
|
+
private removeGlslangObserver;
|
|
4210
|
+
protected disarmGlslangWatchdog(): void;
|
|
4211
|
+
}
|
|
4212
|
+
export interface IPostProcessEnumValue {
|
|
4213
|
+
value?: number;
|
|
4214
|
+
name?: string;
|
|
4215
|
+
}
|
|
4216
|
+
export interface IPostProcessTextureReference {
|
|
4217
|
+
url?: string;
|
|
4218
|
+
type?: string;
|
|
4219
|
+
width?: number;
|
|
4220
|
+
height?: number;
|
|
4221
|
+
exported?: boolean;
|
|
4222
|
+
}
|
|
4223
|
+
export interface IPostProcessLutReference extends IPostProcessTextureReference {
|
|
4224
|
+
lutsize?: number;
|
|
4225
|
+
lutlayout?: string;
|
|
4226
|
+
identity?: boolean;
|
|
4227
|
+
lutspace?: string;
|
|
4228
|
+
lutencoding?: string;
|
|
4229
|
+
operators?: string[];
|
|
4230
|
+
}
|
|
4231
|
+
export interface IPostProcessEffect {
|
|
4232
|
+
effecttype?: string;
|
|
4233
|
+
effectnamespace?: string;
|
|
4234
|
+
enabled?: boolean;
|
|
4235
|
+
active?: boolean;
|
|
4236
|
+
parameters?: {
|
|
4237
|
+
[key: string]: any;
|
|
4238
|
+
};
|
|
4239
|
+
}
|
|
4240
|
+
export interface IPostProcessVolumeBounds {
|
|
4241
|
+
shape: "box" | "sphere";
|
|
4242
|
+
center: number[];
|
|
4243
|
+
size?: number[];
|
|
4244
|
+
radius?: number;
|
|
4245
|
+
}
|
|
4246
|
+
export interface IPostProcessVolumeProperties {
|
|
4247
|
+
volumetype?: string;
|
|
4248
|
+
isglobal?: boolean;
|
|
4249
|
+
bounds?: IPostProcessVolumeBounds;
|
|
4250
|
+
pipelinedefault?: boolean;
|
|
4251
|
+
weight?: number;
|
|
4252
|
+
priority?: number;
|
|
4253
|
+
blenddistance?: number;
|
|
4254
|
+
profilename?: string;
|
|
4255
|
+
colorspace?: string;
|
|
4256
|
+
effectcount?: number;
|
|
4257
|
+
effects?: IPostProcessEffect[];
|
|
4258
|
+
}
|
|
4259
|
+
export interface IPostProcessCameraMetadata {
|
|
4260
|
+
postprocessing?: boolean;
|
|
4261
|
+
volumelayermask?: number;
|
|
4262
|
+
antialiasing?: IPostProcessEnumValue;
|
|
4263
|
+
msaasamples?: number;
|
|
4264
|
+
allowhdr?: boolean;
|
|
4265
|
+
renderingpath?: string;
|
|
4266
|
+
physicalaperture?: number;
|
|
4267
|
+
physicalfocallength?: number;
|
|
4268
|
+
}
|
|
4269
|
+
export interface IPostProcessSsrGate {
|
|
4270
|
+
camera: string;
|
|
4271
|
+
volumetype: string;
|
|
4272
|
+
renderingpath: string;
|
|
4273
|
+
forced: boolean;
|
|
4274
|
+
applied: boolean;
|
|
4275
|
+
reused: boolean;
|
|
4276
|
+
reason: string;
|
|
4277
|
+
flags: {
|
|
4278
|
+
inputTextureColorIsInGammaSpace: boolean;
|
|
4279
|
+
generateOutputInGammaSpace: boolean;
|
|
4280
|
+
enableSmoothReflections: boolean;
|
|
4281
|
+
blurDispersionStrength: number;
|
|
4282
|
+
roughnessFactor: number;
|
|
4283
|
+
};
|
|
4284
|
+
}
|
|
4285
|
+
export interface IPostProcessField {
|
|
4286
|
+
value: any;
|
|
4287
|
+
overridden: boolean;
|
|
4288
|
+
unsupported?: string;
|
|
4289
|
+
}
|
|
4290
|
+
export interface IPostProcessEffectModel {
|
|
4291
|
+
family: string;
|
|
4292
|
+
source: string;
|
|
4293
|
+
active: boolean;
|
|
4294
|
+
fields: {
|
|
4295
|
+
[name: string]: IPostProcessField;
|
|
4296
|
+
};
|
|
4297
|
+
}
|
|
4298
|
+
export interface IPostProcessUnsupportedEffect {
|
|
4299
|
+
effecttype: string;
|
|
4300
|
+
effectnamespace: string;
|
|
4301
|
+
}
|
|
4302
|
+
export interface IPostProcessModel {
|
|
4303
|
+
volumetype: string;
|
|
4304
|
+
volumetypes: string[];
|
|
4305
|
+
families: {
|
|
4306
|
+
[family: string]: IPostProcessEffectModel;
|
|
4307
|
+
};
|
|
4308
|
+
lut: IPostProcessLutReference;
|
|
4309
|
+
unsupported: IPostProcessUnsupportedEffect[];
|
|
4310
|
+
warnings: string[];
|
|
4311
|
+
}
|
|
4312
|
+
export interface IPostProcessVolumeEntry {
|
|
4313
|
+
name: string;
|
|
4314
|
+
layer: number;
|
|
4315
|
+
properties: IPostProcessVolumeProperties;
|
|
4316
|
+
cameraLocal?: number[];
|
|
4317
|
+
}
|
|
4318
|
+
export interface IPostProcessIgnoredVolume {
|
|
4319
|
+
name: string;
|
|
4320
|
+
reason: string;
|
|
4321
|
+
}
|
|
4322
|
+
export interface IPostProcessStack {
|
|
4323
|
+
model: IPostProcessModel;
|
|
4324
|
+
applied: string[];
|
|
4325
|
+
ignored: IPostProcessIgnoredVolume[];
|
|
4326
|
+
warnings: string[];
|
|
4327
|
+
}
|
|
4328
|
+
export interface IPostProcessCameraCandidate {
|
|
4329
|
+
name: string;
|
|
4330
|
+
main?: boolean;
|
|
4331
|
+
metadata?: IPostProcessCameraMetadata;
|
|
4332
|
+
camera?: any;
|
|
4333
|
+
}
|
|
4334
|
+
export interface IPostProcessCameraSelection {
|
|
4335
|
+
cameras: IPostProcessCameraCandidate[];
|
|
4336
|
+
mode: string;
|
|
4337
|
+
warning?: string;
|
|
4338
|
+
}
|
|
4339
|
+
export declare class PostProcessingContract {
|
|
4340
|
+
static readonly VOLUME_TYPES: string[];
|
|
4341
|
+
static readonly GRADING_MODES: string[];
|
|
4342
|
+
static readonly RENDERING_PATH_DEFERRED: string;
|
|
4343
|
+
static readonly RENDERING_PATH_FORWARD: string;
|
|
4344
|
+
static readonly Defaults: {
|
|
4345
|
+
[family: string]: {
|
|
4346
|
+
[field: string]: any;
|
|
4347
|
+
};
|
|
4348
|
+
};
|
|
4349
|
+
static readonly KnownFields: {
|
|
4350
|
+
[family: string]: {
|
|
4351
|
+
BuiltIn?: string[];
|
|
4352
|
+
URP?: string[];
|
|
4353
|
+
HDRP?: string[];
|
|
4354
|
+
};
|
|
4355
|
+
};
|
|
4356
|
+
static readonly ModeOnlyFields: {
|
|
4357
|
+
[family: string]: string[];
|
|
3229
4358
|
};
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
static
|
|
3251
|
-
static
|
|
3252
|
-
|
|
3253
|
-
overrideState: boolean | null;
|
|
4359
|
+
static unconsumedFields(family: IPostProcessEffectModel, consumes: string[]): string[];
|
|
4360
|
+
static readonly Vocabulary: {
|
|
4361
|
+
[effecttype: string]: {
|
|
4362
|
+
family: string | null;
|
|
4363
|
+
rename?: {
|
|
4364
|
+
[from: string]: string;
|
|
4365
|
+
};
|
|
4366
|
+
consumedElsewhere?: boolean;
|
|
4367
|
+
};
|
|
4368
|
+
};
|
|
4369
|
+
static readonly HDRP_NAMESPACE: string;
|
|
4370
|
+
static parseVolume(props: any): IPostProcessVolumeProperties;
|
|
4371
|
+
static parseVolumeBounds(raw: any): IPostProcessVolumeBounds;
|
|
4372
|
+
static parseEffect(raw: any): IPostProcessEffect;
|
|
4373
|
+
static readField(param: any): IPostProcessField;
|
|
4374
|
+
static enumIndex(value: any, fallback?: number): number;
|
|
4375
|
+
static enumName(value: any): string;
|
|
4376
|
+
static normalise(volume: IPostProcessVolumeProperties): IPostProcessModel;
|
|
4377
|
+
private static createFamily;
|
|
4378
|
+
private static parseLut;
|
|
4379
|
+
static parseTexture(raw: any): IPostProcessTextureReference;
|
|
4380
|
+
static readonly TextureFields: {
|
|
4381
|
+
[family: string]: string[];
|
|
3254
4382
|
};
|
|
4383
|
+
static gradingMode(model: IPostProcessModel): IPostProcessEnumValue;
|
|
4384
|
+
static isHdrGrading(model: IPostProcessModel): boolean;
|
|
4385
|
+
static tonemapper(model: IPostProcessModel): IPostProcessEnumValue;
|
|
4386
|
+
static renderingPath(metadata: IPostProcessCameraMetadata): string;
|
|
4387
|
+
static volumeType(volume: IPostProcessVolumeProperties): string;
|
|
4388
|
+
static localVolumeWeight(bounds: IPostProcessVolumeBounds, cameraLocal: number[], blendDistance: number): number;
|
|
4389
|
+
static blendStack(volumes: IPostProcessVolumeEntry[], layerMask?: number): IPostProcessStack;
|
|
4390
|
+
static layerInMask(layer: number, mask: number): boolean;
|
|
4391
|
+
private static scaleModel;
|
|
4392
|
+
private static blendInto;
|
|
4393
|
+
static interpolate(from: any, to: any, t: number): any;
|
|
4394
|
+
static selectCameras(cameras: IPostProcessCameraCandidate[]): IPostProcessCameraSelection;
|
|
4395
|
+
static isNumber(v: any): boolean;
|
|
4396
|
+
static clone(v: any): any;
|
|
4397
|
+
static fieldOf(model: IPostProcessModel, family: string, name: string): IPostProcessField;
|
|
4398
|
+
}
|
|
4399
|
+
export interface IPostProcessToneMapper {
|
|
4400
|
+
enabled: boolean;
|
|
4401
|
+
type: number;
|
|
4402
|
+
warning?: string;
|
|
4403
|
+
}
|
|
4404
|
+
export interface IPostProcessVignetteCenter {
|
|
4405
|
+
centerX: number;
|
|
4406
|
+
centerY: number;
|
|
4407
|
+
}
|
|
4408
|
+
export interface IPostProcessGaussianDof {
|
|
4409
|
+
focusDistanceMm: number;
|
|
4410
|
+
blurLevel: number;
|
|
4411
|
+
warning: string;
|
|
4412
|
+
}
|
|
4413
|
+
export interface IPostProcessSsao {
|
|
4414
|
+
totalStrength: number;
|
|
4415
|
+
radius: number;
|
|
4416
|
+
samples: number;
|
|
4417
|
+
expensiveBlur: boolean;
|
|
4418
|
+
ssaoRatio: number;
|
|
4419
|
+
blurRatio: number;
|
|
4420
|
+
epsilon: number;
|
|
4421
|
+
base: number;
|
|
4422
|
+
maxZ: number;
|
|
4423
|
+
minZAspect: number;
|
|
4424
|
+
bilateralSamples: number;
|
|
4425
|
+
bilateralSoften: number;
|
|
4426
|
+
bilateralTolerance: number;
|
|
4427
|
+
}
|
|
4428
|
+
export interface IPostProcessSsr {
|
|
4429
|
+
maxSteps: number;
|
|
4430
|
+
thickness: number;
|
|
4431
|
+
strength: number;
|
|
4432
|
+
ssrDownsample: number;
|
|
4433
|
+
maxDistance?: number;
|
|
4434
|
+
attenuateScreenBorders?: boolean;
|
|
4435
|
+
roughnessFactor?: number;
|
|
4436
|
+
blurDispersionStrength?: number;
|
|
4437
|
+
enableSmoothReflections?: boolean;
|
|
4438
|
+
}
|
|
4439
|
+
export interface IPostProcessAntialiasing {
|
|
4440
|
+
fxaa: boolean;
|
|
4441
|
+
fast: boolean;
|
|
4442
|
+
samples: number;
|
|
4443
|
+
mode: number;
|
|
4444
|
+
}
|
|
4445
|
+
export declare class PostProcessingConversions {
|
|
4446
|
+
static ContrastMin: number;
|
|
4447
|
+
static ContrastMax: number;
|
|
4448
|
+
static NeutralToneMapperType: number;
|
|
4449
|
+
static ExposureMaxStops: number;
|
|
4450
|
+
static exposureFromEV(ev: number): number;
|
|
4451
|
+
static contrastFromUnity(contrast: number): number;
|
|
4452
|
+
static saturationFromUnity(saturation: number): number;
|
|
4453
|
+
static toneMapperFromPPv2(tonemapper: number): IPostProcessToneMapper;
|
|
4454
|
+
static toneMapperFromSRP(mode: number): IPostProcessToneMapper;
|
|
4455
|
+
private static toneMapperFromMode;
|
|
4456
|
+
static srgbToLinearColor(color: number[]): number[];
|
|
4457
|
+
static srgbToLinear(c: number): number;
|
|
4458
|
+
static linearToSrgb(c: number): number;
|
|
4459
|
+
static linearToSrgbColor(color: number[]): number[];
|
|
4460
|
+
static isWhite(color: number[], tolerance?: number): boolean;
|
|
4461
|
+
static BloomWeightScaleURP: number;
|
|
4462
|
+
static BloomThresholdGamma: number;
|
|
4463
|
+
static BloomKernelMin: number;
|
|
4464
|
+
static BloomKernelMax: number;
|
|
4465
|
+
static BloomScale: number;
|
|
4466
|
+
static BloomMaxIterations: number;
|
|
4467
|
+
static BloomWeightScaleHDRP: number;
|
|
4468
|
+
static bloomWeightFromIntensity(intensity: number, volumetype?: string): number;
|
|
4469
|
+
static bloomThresholdFromUnity(threshold: number, volumetype?: string, softKnee?: number): number;
|
|
4470
|
+
static BloomHardKneeSRP: number;
|
|
4471
|
+
static BloomKneeWeight: number;
|
|
4472
|
+
static gammaToLinearSpace(value: number): number;
|
|
4473
|
+
static bloomPyramidFromDiffusion(diffusion: number, width: number, height: number): {
|
|
4474
|
+
iterations: number;
|
|
4475
|
+
sampleScale: number;
|
|
4476
|
+
logs: number;
|
|
4477
|
+
tw: number;
|
|
4478
|
+
th: number;
|
|
4479
|
+
};
|
|
4480
|
+
static bloomThresholdVectorFromPPv2(threshold: number, softKnee?: number): number[];
|
|
4481
|
+
static bloomKernelFromScatter(scatter: number): number;
|
|
4482
|
+
private static kernelFromUnit;
|
|
4483
|
+
static bloomUrpPrefilterParams(threshold: number, clamp?: number): {
|
|
4484
|
+
threshold: number;
|
|
4485
|
+
knee: number;
|
|
4486
|
+
clamp: number;
|
|
4487
|
+
};
|
|
4488
|
+
static bloomUrpScatter(scatter: number): number;
|
|
4489
|
+
static bloomUrpLadder(width: number, height: number, downscale?: number, maxIterations?: number): {
|
|
4490
|
+
tw: number;
|
|
4491
|
+
th: number;
|
|
4492
|
+
mipCount: number;
|
|
4493
|
+
downres: number;
|
|
4494
|
+
};
|
|
4495
|
+
static bloomUrpTint(color: number[]): number[];
|
|
4496
|
+
static dofBlurLevelFromUrpBokeh(highQualitySampling: boolean): number;
|
|
4497
|
+
static vignetteCenter(uv: number[]): IPostProcessVignetteCenter;
|
|
4498
|
+
static vignetteColorLinear(rgba: number[]): number[];
|
|
4499
|
+
static gradingModeIsHdr(gradingMode: number, volumetype: string): boolean;
|
|
4500
|
+
static gradingModeBakesToneMapper(gradingMode: number, volumetype: string): boolean;
|
|
4501
|
+
static GrainIntensityMultiplier: number;
|
|
4502
|
+
static BloomIntensityMultiplier: number;
|
|
4503
|
+
static FilmGrainTypeMultipliers: number[];
|
|
4504
|
+
static FilmGrainAmplitudeScaleURP: number;
|
|
4505
|
+
static SharpenEdgeScale: number;
|
|
4506
|
+
static filmGrainTypeMultiplier(type: number): number;
|
|
4507
|
+
static sharpenEdgeAmount(intensity: number): number;
|
|
4508
|
+
static dofFocusDistanceMm(metres: number): number;
|
|
4509
|
+
static dofFocusDistanceFromHdrpRanges(nearFocusEnd: number, farFocusStart: number): number;
|
|
4510
|
+
static dofBlurLevelFromKernelSize(kernelSize: number): number;
|
|
4511
|
+
static dofFromGaussian(start: number, end: number, maxRadius: number): IPostProcessGaussianDof;
|
|
4512
|
+
static MotionStrengthK: number;
|
|
4513
|
+
static MotionBlurQualitySamples: number[];
|
|
4514
|
+
static motionStrengthFromShutterAngle(shutterAngle: number): number;
|
|
4515
|
+
static motionStrengthFromIntensity(intensity: number): number;
|
|
4516
|
+
static motionSamplesFromQuality(quality: number): number;
|
|
4517
|
+
static LensDistortionK: number;
|
|
4518
|
+
static LensDistortionDegreesPerUnit: number;
|
|
4519
|
+
static LensDistortionMaxDegrees: number;
|
|
4520
|
+
static lensDistortionTheta(normalised: number): number;
|
|
4521
|
+
static lensDistortionIntensity(normalised: number): number;
|
|
4522
|
+
static lensDistortionModelScale(normalised: number): number;
|
|
4523
|
+
static lensDistortionAxisIntensity(intensity: number, multiplier: number): number;
|
|
4524
|
+
static lensDistortionCenterUv(center: number): number;
|
|
4525
|
+
static lensDistortionScale(scale: number): number;
|
|
4526
|
+
static lensDistortionNormalised(value: number, volumetype?: string): number;
|
|
4527
|
+
static SsaoQualitySamples: number[];
|
|
4528
|
+
static SsaoExpensiveBlurFromQuality: number;
|
|
4529
|
+
static SsaoStrengthScale: number;
|
|
4530
|
+
static SsaoRadiusScale: number;
|
|
4531
|
+
static SsaoRatio: number;
|
|
4532
|
+
static SsaoBlurRatio: number;
|
|
4533
|
+
static SsaoEpsilon: number;
|
|
4534
|
+
static SsaoBase: number;
|
|
4535
|
+
static SsaoMaxZ: number;
|
|
4536
|
+
static SsaoMinZAspect: number;
|
|
4537
|
+
static SsaoExpensiveBlur: boolean;
|
|
4538
|
+
static SsaoBilateralSamples: number;
|
|
4539
|
+
static SsaoBilateralSoften: number;
|
|
4540
|
+
static SsaoBilateralTolerance: number;
|
|
4541
|
+
private static SsaoDeclared;
|
|
4542
|
+
static frozen(name: string): number;
|
|
4543
|
+
static ssaoFromUnity(intensity: number, radius: number, quality?: number, stepCount?: number): IPostProcessSsao;
|
|
4544
|
+
static DitheringIntensity: number;
|
|
4545
|
+
static SsrPresets: IPostProcessSsr[];
|
|
4546
|
+
static SsrBlurDispersionStrength: number;
|
|
4547
|
+
static SsrRoughnessFactor: number;
|
|
4548
|
+
static ssrRoughnessBlur(minSmoothness?: number): {
|
|
4549
|
+
roughnessFactor: number;
|
|
4550
|
+
blurDispersionStrength: number;
|
|
4551
|
+
enableSmoothReflections: boolean;
|
|
4552
|
+
};
|
|
4553
|
+
static ssrPresetTable(preset: number): IPostProcessSsr;
|
|
4554
|
+
static ssrCustomFromUnity(maximumIterationCount: number, thickness: number, resolution: number, maximumMarchDistance: number, distanceFade: number, vignette: number): IPostProcessSsr;
|
|
4555
|
+
static ssrFromHdrp(rayMaxIterations: number, minSmoothness: number, screenFadeDistance: number): IPostProcessSsr;
|
|
4556
|
+
static antialiasingFromMetadata(mode: number, msaaSamples: number): IPostProcessAntialiasing;
|
|
4557
|
+
static num(value: any, fallback: number): number;
|
|
4558
|
+
static clamp(value: number, min: number, max: number): number;
|
|
4559
|
+
}
|
|
4560
|
+
export interface IInspectorDisposable {
|
|
4561
|
+
dispose(): void;
|
|
4562
|
+
}
|
|
4563
|
+
export interface IInspectorSectionRow {
|
|
4564
|
+
section: string;
|
|
4565
|
+
order?: number;
|
|
4566
|
+
component: (props: {
|
|
4567
|
+
context: any;
|
|
4568
|
+
}) => any;
|
|
4569
|
+
}
|
|
4570
|
+
export interface IInspectorPropertiesService {
|
|
4571
|
+
addSection(section: {
|
|
4572
|
+
identity: string;
|
|
4573
|
+
order?: number;
|
|
4574
|
+
collapseByDefault?: boolean;
|
|
4575
|
+
}): IInspectorDisposable;
|
|
4576
|
+
addSectionContent(content: {
|
|
4577
|
+
key: string;
|
|
4578
|
+
predicate: (entity: unknown) => boolean;
|
|
4579
|
+
content: readonly IInspectorSectionRow[];
|
|
4580
|
+
}): IInspectorDisposable;
|
|
4581
|
+
}
|
|
4582
|
+
export interface IInspectorServiceDefinition {
|
|
4583
|
+
friendlyName: string;
|
|
4584
|
+
consumes?: any[];
|
|
4585
|
+
produces?: any[];
|
|
4586
|
+
factory: (...args: any[]) => any;
|
|
4587
|
+
}
|
|
4588
|
+
export interface IPostProcessInspectorRow {
|
|
4589
|
+
family: string;
|
|
4590
|
+
field: string;
|
|
4591
|
+
order: number;
|
|
4592
|
+
}
|
|
4593
|
+
export interface IPostProcessInspectorRegistration extends IPostProcessInspectorRow {
|
|
4594
|
+
kind: string;
|
|
4595
|
+
key: string;
|
|
4596
|
+
}
|
|
4597
|
+
export declare class PostProcessingInspector {
|
|
4598
|
+
static readonly SectionIdentity: string;
|
|
4599
|
+
static readonly SectionOrder: number;
|
|
4600
|
+
static readonly RequiredExports: string[];
|
|
4601
|
+
static readonly StockSections: {
|
|
4602
|
+
[family: string]: string;
|
|
4603
|
+
};
|
|
4604
|
+
static readonly PassFamilies: {
|
|
4605
|
+
[plugin: string]: string;
|
|
4606
|
+
};
|
|
4607
|
+
static readonly FamilyFields: {
|
|
4608
|
+
[family: string]: string[];
|
|
4609
|
+
};
|
|
4610
|
+
static readonly HeaderFields: string[];
|
|
4611
|
+
static readonly EmptyRowKey: string;
|
|
4612
|
+
static get RowCatalogue(): IPostProcessInspectorRow[];
|
|
4613
|
+
private static catalogue;
|
|
4614
|
+
static readonly RowKinds: string[];
|
|
4615
|
+
static get RowRegistrations(): IPostProcessInspectorRegistration[];
|
|
4616
|
+
static IsRowPresent(entity: any, reg: IPostProcessInspectorRegistration): boolean;
|
|
4617
|
+
static IsEmptyRowPresent(entity: any): boolean;
|
|
4618
|
+
static EmptyRowMessage(entity: any): string;
|
|
4619
|
+
static ResolveNoteTarget(entity: any, family: string): string;
|
|
4620
|
+
static GetInspectorGlobal(): any;
|
|
4621
|
+
static IsAvailable(inspector?: any): boolean;
|
|
4622
|
+
static GetServiceDefinitions(inspector?: any): IInspectorServiceDefinition[];
|
|
4623
|
+
static IsInspectable(entity: any): boolean;
|
|
4624
|
+
static IsOwnedPipeline(entity: any): boolean;
|
|
4625
|
+
static IsToolkitPass(entity: any): boolean;
|
|
4626
|
+
static ResolveContext(entity: any): {
|
|
4627
|
+
camera: any;
|
|
4628
|
+
family: string;
|
|
4629
|
+
effects: IPostProcessInspectorEffect[];
|
|
4630
|
+
unmapped?: boolean;
|
|
4631
|
+
};
|
|
4632
|
+
static ResolveEffect(entity: any, family: string): IPostProcessInspectorEffect;
|
|
4633
|
+
static ResolveField(entity: any, family: string, field: string): IPostProcessInspectorField;
|
|
4634
|
+
static CreateServiceDefinition(inspector: any): IInspectorServiceDefinition;
|
|
4635
|
+
static Register(inspector: any, properties: IInspectorPropertiesService): {
|
|
4636
|
+
dispose: () => void;
|
|
4637
|
+
};
|
|
4638
|
+
static RenderRow(inspector: any, context: any, reg: IPostProcessInspectorRegistration, observable: any, notify: () => void): any;
|
|
4639
|
+
private static state;
|
|
4640
|
+
private static setRegistered;
|
|
3255
4641
|
}
|
|
3256
4642
|
export declare class RaycastVehicle {
|
|
3257
4643
|
private static TempVector;
|
|
@@ -3474,16 +4860,6 @@ export interface IPhysicsShapeCastQuery {
|
|
|
3474
4860
|
shouldHitTriggers: boolean;
|
|
3475
4861
|
ignoreBody?: PhysicsBody;
|
|
3476
4862
|
}
|
|
3477
|
-
export declare class RoundedVignettePlugin {
|
|
3478
|
-
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
3479
|
-
color?: number[] | Color3 | Color4;
|
|
3480
|
-
center?: number[];
|
|
3481
|
-
intensity?: number;
|
|
3482
|
-
smoothness?: number;
|
|
3483
|
-
rounded?: boolean;
|
|
3484
|
-
blendMode?: string | number;
|
|
3485
|
-
}): PostProcess;
|
|
3486
|
-
}
|
|
3487
4863
|
export declare class ShurikenParticles extends ScriptComponent {
|
|
3488
4864
|
private static DefaultParticleTexture;
|
|
3489
4865
|
private static readonly DEFAULT_PARTICLE_PROPERTIES;
|
|
@@ -3972,6 +5348,14 @@ export declare class SkinTextureArray {
|
|
|
3972
5348
|
invertY?: boolean;
|
|
3973
5349
|
mipmaps?: boolean;
|
|
3974
5350
|
}): Promise<RawTexture2DArray>;
|
|
5351
|
+
static IsCached(scene: Scene, urls: string[], options?: {
|
|
5352
|
+
samplingMode?: number;
|
|
5353
|
+
aniso?: number;
|
|
5354
|
+
invertY?: boolean;
|
|
5355
|
+
mipmaps?: boolean;
|
|
5356
|
+
}): boolean;
|
|
5357
|
+
private static _clampLayers;
|
|
5358
|
+
private static _cacheKey;
|
|
3975
5359
|
private static _uploadMipChain;
|
|
3976
5360
|
private static _downsampleLayers;
|
|
3977
5361
|
private static _maxArrayLayers;
|
|
@@ -4165,7 +5549,7 @@ export declare class TerrainBuilder extends ScriptComponent {
|
|
|
4165
5549
|
private static GammaToLinear;
|
|
4166
5550
|
private static LinearToGamma;
|
|
4167
5551
|
}
|
|
4168
|
-
export declare class TextureAtlasSkin extends ScriptComponent {
|
|
5552
|
+
export declare class TextureAtlasSkin extends ScriptComponent implements IAssetPreloader {
|
|
4169
5553
|
private abtractMesh;
|
|
4170
5554
|
private textureData;
|
|
4171
5555
|
private defaultIndex;
|
|
@@ -4178,11 +5562,18 @@ export declare class TextureAtlasSkin extends ScriptComponent {
|
|
|
4178
5562
|
private _applied;
|
|
4179
5563
|
private _manifest;
|
|
4180
5564
|
private _currentIndex;
|
|
5565
|
+
private _pendingIndex;
|
|
4181
5566
|
private _targets;
|
|
4182
5567
|
private _clonedMultiMaterial;
|
|
5568
|
+
onSkinsReadyObservable: Observable<TextureAtlasSkin>;
|
|
5569
|
+
private _outstandingBuilds;
|
|
5570
|
+
private _skinsReady;
|
|
4183
5571
|
constructor(transform: TransformNode, scene: Scene, properties?: any, alias?: string);
|
|
4184
5572
|
protected awake(): void;
|
|
4185
5573
|
protected start(): void;
|
|
5574
|
+
private readSliceProperties;
|
|
5575
|
+
addPreloaderTasks(assetsManager: PreloadAssetsManager): void;
|
|
5576
|
+
protected destroy(): void;
|
|
4186
5577
|
getAbstractSkinnedMesh(): AbstractMesh;
|
|
4187
5578
|
applySkins(): void;
|
|
4188
5579
|
setSkinIndex(index: number): number;
|
|
@@ -4190,15 +5581,51 @@ export declare class TextureAtlasSkin extends ScriptComponent {
|
|
|
4190
5581
|
skinCount(): number;
|
|
4191
5582
|
private maxChannelSliceCount;
|
|
4192
5583
|
getSkinIndex(): number;
|
|
5584
|
+
static OnAllSkinsReadyObservable: Observable<Scene>;
|
|
5585
|
+
private static readonly SKIN_READY_TIMEOUT_MS;
|
|
5586
|
+
private static readonly SKIN_READY_SETTLE_MS;
|
|
5587
|
+
private static readonly SKIN_SHADER_WAIT_MS;
|
|
5588
|
+
private static readonly SKIN_PRELOAD_TIMEOUT_MS;
|
|
5589
|
+
private static readonly SKIN_READY_POLL_MS;
|
|
5590
|
+
private static _pendingBuilds;
|
|
5591
|
+
private static _buildActivity;
|
|
5592
|
+
private static _buildsSinceNotify;
|
|
5593
|
+
private static _batchWatch;
|
|
5594
|
+
private static _batchScene;
|
|
5595
|
+
static GetPendingSkinBuilds(): number;
|
|
5596
|
+
static AreAllSkinsReady(): boolean;
|
|
5597
|
+
static WhenAllSkinsReady(scene: Scene, timeoutMs?: number, settleMs?: number): Promise<boolean>;
|
|
5598
|
+
private static NoteBuildStarted;
|
|
5599
|
+
private static NoteBuildFinished;
|
|
5600
|
+
private static TrackSkinBuild;
|
|
5601
|
+
private beginSkinBuild;
|
|
5602
|
+
private endSkinBuild;
|
|
5603
|
+
isSkinsReady(): boolean;
|
|
5604
|
+
private markSkinsReady;
|
|
5605
|
+
private static startBatchWatch;
|
|
5606
|
+
private static stopBatchWatch;
|
|
5607
|
+
private static whenSceneReady;
|
|
5608
|
+
private static nowMs;
|
|
5609
|
+
private resolveVatSlot;
|
|
4193
5610
|
private configureMaterial;
|
|
5611
|
+
private skinChannels;
|
|
5612
|
+
private channelUrlsFor;
|
|
5613
|
+
private static readonly CHANNEL_SPECS;
|
|
5614
|
+
private static ChannelOptions;
|
|
5615
|
+
static PreloadContainerSkinsAsync(scene: Scene, container: AssetContainer, rootUrl?: string, timeoutMs?: number): Promise<boolean>;
|
|
5616
|
+
private static ScanContainerSkinChannels;
|
|
5617
|
+
private static SlicePropertyUrls;
|
|
5618
|
+
private assignChannelArray;
|
|
4194
5619
|
private albedoChannelUrls;
|
|
4195
5620
|
private normalChannelUrls;
|
|
4196
5621
|
private metalRoughChannelUrls;
|
|
4197
5622
|
private emissiveChannelUrls;
|
|
4198
5623
|
private sliceUrls;
|
|
4199
5624
|
private resolveLayerUrl;
|
|
5625
|
+
private setVatUniformMode;
|
|
4200
5626
|
private applyIndexToTargets;
|
|
4201
5627
|
private applyLayerToMaterial;
|
|
5628
|
+
private refreshMaterialDefines;
|
|
4202
5629
|
private isInstancedSetup;
|
|
4203
5630
|
private ensureSkinLayerBuffer;
|
|
4204
5631
|
private getMeshSlots;
|
|
@@ -4280,6 +5707,65 @@ export declare class UserInterface extends ScriptComponent {
|
|
|
4280
5707
|
static HideCanvasElement(element: Control, fadeDuration?: number, fadeSpeedRatio?: number): Promise<void>;
|
|
4281
5708
|
static AttachClickHandler(element: Control, func: (eventData?: Vector2WithInfo, eventState?: EventState) => any): Observer<Vector2WithInfo> | null;
|
|
4282
5709
|
}
|
|
5710
|
+
export interface IVignetteDistortion {
|
|
5711
|
+
intensity: number;
|
|
5712
|
+
intensityX: number;
|
|
5713
|
+
intensityY: number;
|
|
5714
|
+
center: number[];
|
|
5715
|
+
scale: number;
|
|
5716
|
+
}
|
|
5717
|
+
export interface IVignetteUnitySettings {
|
|
5718
|
+
intensity: number;
|
|
5719
|
+
smoothness: number;
|
|
5720
|
+
roundness: number;
|
|
5721
|
+
rounded: boolean;
|
|
5722
|
+
center: number[];
|
|
5723
|
+
color: number[];
|
|
5724
|
+
}
|
|
5725
|
+
export declare class VignettePlugin {
|
|
5726
|
+
static readonly IntensityScale: number;
|
|
5727
|
+
static readonly SmoothnessScale: number;
|
|
5728
|
+
static readonly RoundnessScale: number;
|
|
5729
|
+
static readonly DefaultRoundness: number;
|
|
5730
|
+
static readonly ShaderName: string;
|
|
5731
|
+
static readonly ShaderKey: string;
|
|
5732
|
+
static PackSettings(intensity: number, smoothness: number, roundness: number, rounded: boolean): {
|
|
5733
|
+
x: number;
|
|
5734
|
+
y: number;
|
|
5735
|
+
z: number;
|
|
5736
|
+
w: number;
|
|
5737
|
+
};
|
|
5738
|
+
static Factor(uvX: number, uvY: number, centerX: number, centerY: number, settings: {
|
|
5739
|
+
x: number;
|
|
5740
|
+
y: number;
|
|
5741
|
+
z: number;
|
|
5742
|
+
w: number;
|
|
5743
|
+
}, width: number, height: number, distortion?: IVignetteDistortion): number;
|
|
5744
|
+
private static clamp01;
|
|
5745
|
+
static GetFragmentShader(): string;
|
|
5746
|
+
static CreatePostProcess(scene: Scene, camera: Camera, options?: {
|
|
5747
|
+
textureType?: number;
|
|
5748
|
+
intensity?: number;
|
|
5749
|
+
smoothness?: number;
|
|
5750
|
+
roundness?: number;
|
|
5751
|
+
rounded?: boolean;
|
|
5752
|
+
center?: {
|
|
5753
|
+
x: number;
|
|
5754
|
+
y: number;
|
|
5755
|
+
} | number[];
|
|
5756
|
+
color?: number[] | Color3 | Color4;
|
|
5757
|
+
colorSrgb?: number[] | Color3 | Color4;
|
|
5758
|
+
samplingMode?: number;
|
|
5759
|
+
distortion?: IVignetteDistortion;
|
|
5760
|
+
distortionSettings?: ILensDistortionUnitySettings;
|
|
5761
|
+
}): PostProcess;
|
|
5762
|
+
static toDistortion(distortion: any): IVignetteDistortion;
|
|
5763
|
+
static DistortUv(uvX: number, uvY: number, distortion: IVignetteDistortion): number[];
|
|
5764
|
+
private static toCenter;
|
|
5765
|
+
private static linearOf;
|
|
5766
|
+
private static toColor;
|
|
5767
|
+
private static num;
|
|
5768
|
+
}
|
|
4283
5769
|
export declare class WebVideoPlayer extends ScriptComponent implements IAssetPreloader {
|
|
4284
5770
|
private videoLoop;
|
|
4285
5771
|
private videoMuted;
|