@galacean/engine-core 1.1.0-alpha.1 → 1.1.0-alpha.3
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/dist/main.js +334 -206
- package/dist/main.js.map +1 -1
- package/dist/miniprogram.js +334 -206
- package/dist/module.js +334 -206
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/ComponentsManager.d.ts +0 -2
- package/types/DisorderedArray.d.ts +6 -1
- package/types/RenderPipeline/MeshRenderElement.d.ts +1 -3
- package/types/RenderPipeline/RenderElementX.d.ts +12 -0
- package/types/RenderPipeline/SpriteElement.d.ts +1 -3
- package/types/RenderPipeline/SpriteMaskElement.d.ts +1 -3
- package/types/RenderPipeline/TextRenderElement.d.ts +1 -3
- package/types/SafeLoopArray.d.ts +37 -0
- package/types/Script.d.ts +0 -1
- package/types/Ticker.d.ts +30 -0
- package/types/Transform.d.ts +1 -0
- package/types/animation/internal/AnimationCurveOwnerLayerData.d.ts +1 -0
- package/types/asset/Loader.d.ts +1 -1
- package/types/asset/ResourceManager.d.ts +8 -0
- package/types/graphic/Primitive.d.ts +1 -0
- package/types/graphic/PrimitiveVertexBinding.d.ts +1 -0
- package/types/graphic/SubPrimitive.d.ts +9 -0
- package/types/index.d.ts +1 -1
- package/types/particle/ParticleBufferUtils.d.ts +1 -0
- package/types/particle/ParticleData.d.ts +1 -0
- package/types/particle/ParticleGenerator.d.ts +72 -0
- package/types/particle/ParticleMaterial.d.ts +28 -0
- package/types/particle/ParticleMesh.d.ts +289 -0
- package/types/particle/ParticleShaderDeclaration.d.ts +1 -0
- package/types/particle/ParticleShaderMacro.d.ts +1 -0
- package/types/particle/ParticleShaderProperty.d.ts +1 -0
- package/types/particle/ParticleSystem.d.ts +41 -0
- package/types/particle/ParticleVertexElements.d.ts +1 -0
- package/types/particle/ParticleVertexUtils.d.ts +1 -0
- package/types/particle/enum/ParticleAnimationRowMode.d.ts +9 -0
- package/types/particle/enum/ParticleAnimationType.d.ts +9 -0
- package/types/particle/enum/ParticleCurveMode.d.ts +13 -0
- package/types/particle/enum/ParticleGradientMode.d.ts +13 -0
- package/types/particle/enum/ParticleRenderMode.d.ts +17 -0
- package/types/particle/enum/ParticleScaleMode.d.ts +11 -0
- package/types/particle/enum/ParticleShapeMultiModeValue.d.ts +9 -0
- package/types/particle/enum/ParticleShapeType.d.ts +15 -0
- package/types/particle/enum/ParticleSimulationSpace.d.ts +9 -0
- package/types/particle/enum/index.d.ts +9 -0
- package/types/particle/enums/ParticleCurveMode.d.ts +9 -0
- package/types/particle/enums/ParticleGradientMode.d.ts +9 -0
- package/types/particle/enums/ParticleRandomSubSeeds.d.ts +1 -0
- package/types/particle/enums/ParticleRenderMode.d.ts +17 -0
- package/types/particle/enums/ParticleScaleMode.d.ts +11 -0
- package/types/particle/enums/ParticleSimulationSpace.d.ts +9 -0
- package/types/particle/enums/ParticleStopMode.d.ts +6 -0
- package/types/particle/enums/attributes/BillboardParticleVertexAttribute.d.ts +1 -0
- package/types/particle/enums/attributes/MeshParticleVertexAttribute.d.ts +5 -0
- package/types/particle/enums/attributes/ParticleInstanceVertexAttribute.d.ts +1 -0
- package/types/particle/module/Burst.d.ts +38 -0
- package/types/particle/module/ColorGradient.d.ts +75 -0
- package/types/particle/module/ColorOverLifetimeModule.d.ts +20 -0
- package/types/particle/module/EmissionModule.d.ts +63 -0
- package/types/particle/module/FrameOverTime.d.ts +73 -0
- package/types/particle/module/ParticleCurve.d.ts +37 -0
- package/types/particle/module/RotationOverLifetimeModule.d.ts +21 -0
- package/types/particle/module/RotationVelocityGradient.d.ts +184 -0
- package/types/particle/module/SizeGradient.d.ts +151 -0
- package/types/particle/module/SizeOverLifetimeModule.d.ts +21 -0
- package/types/particle/module/StartFrame.d.ts +46 -0
- package/types/particle/module/TextureSheetAnimationModule.d.ts +37 -0
- package/types/particle/module/VelocityGradient.d.ts +110 -0
- package/types/particle/module/VelocityOverLifetimeModule.d.ts +22 -0
- package/types/particle/module/index.d.ts +15 -0
- package/types/particle/module/shape/BaseShape.d.ts +26 -0
- package/types/particle/module/shape/BoxShape.d.ts +20 -0
- package/types/particle/module/shape/CircleShape.d.ts +27 -0
- package/types/particle/module/shape/ConeShape.d.ts +35 -0
- package/types/particle/module/shape/HemisphereShape.d.ts +23 -0
- package/types/particle/module/shape/ShapeUtils.d.ts +1 -0
- package/types/particle/module/shape/SphereShape.d.ts +23 -0
- package/types/particle/module/shape/index.d.ts +5 -0
- package/types/particle/modules/Burst.d.ts +14 -0
- package/types/particle/modules/ColorOverLifetimeModule.d.ts +20 -0
- package/types/particle/modules/EmissionModule.d.ts +45 -0
- package/types/particle/modules/MainModule.d.ts +68 -0
- package/types/particle/modules/ParticleCompositeCurve.d.ts +56 -0
- package/types/particle/modules/ParticleCompositeGradient.d.ts +55 -0
- package/types/particle/modules/ParticleCurve.d.ts +56 -0
- package/types/particle/modules/ParticleGeneratorModule.d.ts +12 -0
- package/types/particle/modules/ParticleGradient.d.ts +94 -0
- package/types/particle/modules/RotationOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/ShapeModule.d.ts +9 -0
- package/types/particle/modules/SizeOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/TextureSheetAnimationModule.d.ts +42 -0
- package/types/particle/modules/VelocityOverLifetimeModule.d.ts +34 -0
- package/types/particle/modules/shape/BaseShape.d.ts +12 -0
- package/types/particle/modules/shape/BoxShape.d.ts +11 -0
- package/types/particle/modules/shape/CircleShape.d.ts +17 -0
- package/types/particle/modules/shape/ConeShape.d.ts +28 -0
- package/types/particle/modules/shape/HemisphereShape.d.ts +9 -0
- package/types/particle/modules/shape/ShapeUtils.d.ts +1 -0
- package/types/particle/modules/shape/SphereShape.d.ts +9 -0
- package/types/particle/modules/shape/enums/ParticleShapeArcMode.d.ts +9 -0
- package/types/particle/modules/shape/enums/ParticleShapeMultiModeValue.d.ts +9 -0
- package/types/particle/modules/shape/enums/ParticleShapeType.d.ts +15 -0
- package/types/particle/modules/shape/index.d.ts +6 -0
- package/types/particle/moudules/Burst.d.ts +25 -0
- package/types/particle/moudules/Emission.d.ts +47 -0
- package/types/particle/moudules/EmissionModule.d.ts +49 -0
- package/types/particle/moudules/MainModule.d.ts +59 -0
- package/types/particle/moudules/ParticleCurve.d.ts +27 -0
- package/types/particle/moudules/ParticleGradient.d.ts +28 -0
- package/types/particle/moudules/ShapeModule.d.ts +7 -0
- package/types/particle/moudules/shape/BaseShape.d.ts +28 -0
- package/types/particle/moudules/shape/BoxShape.d.ts +20 -0
- package/types/particle/moudules/shape/CircleShape.d.ts +27 -0
- package/types/particle/moudules/shape/ConeShape.d.ts +35 -0
- package/types/particle/moudules/shape/HemisphereShape.d.ts +23 -0
- package/types/particle/moudules/shape/ShapeUtils.d.ts +1 -0
- package/types/particle/moudules/shape/SphereShape.d.ts +23 -0
- package/types/particle/moudules/shape/enums/ParticleShapeMultiModeValue.d.ts +9 -0
- package/types/particle/moudules/shape/enums/ParticleShapeType.d.ts +15 -0
- package/types/particle/moudules/shape/index.d.ts +5 -0
- package/types/physics/PhysicsScene.d.ts +6 -2
- package/types/shaderlib/particle/index.d.ts +14 -0
- package/types/shadow/PipelinePass.d.ts +16 -0
- package/types/utils/BoolUpdateFlag.d.ts +12 -0
- package/types/utils/DisorderedArray.d.ts +18 -0
- package/types/utils/UpdateFlag.d.ts +20 -0
- package/types/utils/UpdateFlagManager.d.ts +1 -0
- package/types/utils/Utils.d.ts +31 -0
- package/types/xr/XRManager.d.ts +31 -0
- package/types/xr/component/XRPoseDriver.d.ts +10 -0
- package/types/xr/data/XRCamera.d.ts +6 -0
- package/types/xr/data/XRDevice.d.ts +9 -0
- package/types/xr/data/XRHandle.d.ts +10 -0
- package/types/xr/enum/EnumXRButton.d.ts +5 -0
- package/types/xr/enum/EnumXRDevicePhase.d.ts +4 -0
- package/types/xr/enum/EnumXRFeature.d.ts +9 -0
- package/types/xr/enum/EnumXRInputSource.d.ts +8 -0
- package/types/xr/enum/EnumXRMode.d.ts +7 -0
- package/types/xr/enum/EnumXRSubsystem.d.ts +4 -0
- package/types/xr/enum/EnumXRTrackingMode.d.ts +7 -0
- package/types/xr/feature/XRCameraManager.d.ts +21 -0
- package/types/xr/feature/XRFeature.d.ts +29 -0
- package/types/xr/feature/XRImageTrackManager.d.ts +10 -0
- package/types/xr/feature/XRInputManager.d.ts +16 -0
- package/types/xr/index.d.ts +18 -0
- package/types/xr/provider/XRProvider.d.ts +19 -0
- package/types/xr/subsystem/XRInputSubsystem.d.ts +5 -0
- package/types/xr/subsystem/XRSubsystem.d.ts +30 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { IClone } from "@galacean/engine-design";
|
|
2
|
+
import { ParticleCurveMode } from "../enums/ParticleCurveMode";
|
|
3
|
+
/**
|
|
4
|
+
* Particle curve.
|
|
5
|
+
*/
|
|
6
|
+
export declare class ParticleCurve implements IClone {
|
|
7
|
+
/** The curve mode. */
|
|
8
|
+
mode: ParticleCurveMode;
|
|
9
|
+
constant: number;
|
|
10
|
+
constantMin: number;
|
|
11
|
+
constantMax: number;
|
|
12
|
+
/**
|
|
13
|
+
* Query the curve value at the specified time.
|
|
14
|
+
* @param time - Normalized time at which to evaluate the curve, Valid when `mode` is set to `Curve` or `TwoCurves`
|
|
15
|
+
* @param lerpFactor - Lerp factor between two constants or curves, Valid when `mode` is set to `TwoConstants` or `TwoCurves`
|
|
16
|
+
* @returns - The result curve value
|
|
17
|
+
*/
|
|
18
|
+
evaluate(time: number, lerpFactor: number): number;
|
|
19
|
+
/**
|
|
20
|
+
* @inheritDoc
|
|
21
|
+
*/
|
|
22
|
+
cloneTo(destEmission: ParticleCurve): void;
|
|
23
|
+
/**
|
|
24
|
+
* @inheritDoc
|
|
25
|
+
*/
|
|
26
|
+
clone(): ParticleCurve;
|
|
27
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { IClone } from "@galacean/engine-design";
|
|
2
|
+
import { Color } from "@galacean/engine-math";
|
|
3
|
+
import { ParticleGradientMode } from "../enums/ParticleGradientMode";
|
|
4
|
+
/**
|
|
5
|
+
* Particle curve.
|
|
6
|
+
*/
|
|
7
|
+
export declare class ParticleGradient implements IClone {
|
|
8
|
+
/** The curve mode. */
|
|
9
|
+
mode: ParticleGradientMode;
|
|
10
|
+
color: Color;
|
|
11
|
+
colorMin: Color;
|
|
12
|
+
colorMax: Color;
|
|
13
|
+
/**
|
|
14
|
+
* Query the color at the specified time.
|
|
15
|
+
* @param time - Normalized time at which to evaluate the gradient, Valid when `mode` is set to `Gradient` or `TwoGradients`
|
|
16
|
+
* @param lerpFactor - Lerp factor between two colors or gradients, Valid when `mode` is set to `TwoColors` or `TwoGradients`
|
|
17
|
+
* @param out - The result color
|
|
18
|
+
*/
|
|
19
|
+
evaluate(time: number, lerpFactor: number, out: Color): void;
|
|
20
|
+
/**
|
|
21
|
+
* @inheritDoc
|
|
22
|
+
*/
|
|
23
|
+
cloneTo(destEmission: ParticleGradient): void;
|
|
24
|
+
/**
|
|
25
|
+
* @inheritDoc
|
|
26
|
+
*/
|
|
27
|
+
clone(): ParticleGradient;
|
|
28
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { IClone } from "@galacean/engine-design";
|
|
2
|
+
import { BoundingBox, Rand } from "@galacean/engine-math";
|
|
3
|
+
import { ParticleShapeType } from "./enums/ParticleShapeType";
|
|
4
|
+
/**
|
|
5
|
+
* Configures the initial positions and directions of particles.
|
|
6
|
+
*/
|
|
7
|
+
export declare class BaseShape implements IClone {
|
|
8
|
+
/** The type of shape to emit particles from. */
|
|
9
|
+
shapeType: ParticleShapeType;
|
|
10
|
+
/** Specifies whether the ShapeModule is enabled or disabled. */
|
|
11
|
+
enable: boolean;
|
|
12
|
+
/** Randomizes the starting direction of particles. */
|
|
13
|
+
randomDirectionAmount: number;
|
|
14
|
+
protected _rand: Rand;
|
|
15
|
+
constructor(randSeed?: number);
|
|
16
|
+
/**
|
|
17
|
+
* @override
|
|
18
|
+
* @inheritDoc
|
|
19
|
+
*/
|
|
20
|
+
cloneTo(destShape: BaseShape): void;
|
|
21
|
+
/**
|
|
22
|
+
* @override
|
|
23
|
+
* @inheritDoc
|
|
24
|
+
*/
|
|
25
|
+
clone(): BaseShape;
|
|
26
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
27
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
28
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { BoundingBox, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
/**
|
|
4
|
+
* Box emitter shape
|
|
5
|
+
*/
|
|
6
|
+
export declare class BoxShape extends BaseShape {
|
|
7
|
+
/** Thickness of the box to emit particles from. */
|
|
8
|
+
boxThickness: Vector3;
|
|
9
|
+
constructor();
|
|
10
|
+
/**
|
|
11
|
+
* @inheritDoc
|
|
12
|
+
*/
|
|
13
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
14
|
+
/**
|
|
15
|
+
* @inheritDoc
|
|
16
|
+
*/
|
|
17
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
18
|
+
cloneTo(destShape: BoxShape): void;
|
|
19
|
+
clone(): BoxShape;
|
|
20
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { BoundingBox, Vector2, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
import { ParticleShapeMultiModeValue } from "./enums/ParticleShapeMultiModeValue";
|
|
4
|
+
/**
|
|
5
|
+
* Circle Particle Emitter
|
|
6
|
+
*/
|
|
7
|
+
export declare class CircleShape extends BaseShape {
|
|
8
|
+
protected static _tempPositionPoint: Vector2;
|
|
9
|
+
/** Radius of the shape to emit particles from. */
|
|
10
|
+
radius: number;
|
|
11
|
+
/** Angle of the circle arc to emit particles from. */
|
|
12
|
+
arc: number;
|
|
13
|
+
/** The mode to generate particles around the arc. */
|
|
14
|
+
arcMode: ParticleShapeMultiModeValue;
|
|
15
|
+
constructor();
|
|
16
|
+
/**
|
|
17
|
+
* @inheritDoc
|
|
18
|
+
*/
|
|
19
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
20
|
+
/**
|
|
21
|
+
* @inheritDoc
|
|
22
|
+
*/
|
|
23
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
24
|
+
_generatePositionAndDirection(position: Vector3, direction: Vector3): void;
|
|
25
|
+
cloneTo(destShape: CircleShape): void;
|
|
26
|
+
clone(): CircleShape;
|
|
27
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { BoundingBox, Vector2, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
export declare enum ConeEmitType {
|
|
4
|
+
Base = 0,
|
|
5
|
+
BaseShell = 1,
|
|
6
|
+
Volume = 2,
|
|
7
|
+
VolumeShell = 3
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Cone particle emitter
|
|
11
|
+
*/
|
|
12
|
+
export declare class ConeShape extends BaseShape {
|
|
13
|
+
protected static _tempPositionPoint: Vector2;
|
|
14
|
+
protected static _tempDirectionPoint: Vector2;
|
|
15
|
+
/** Angle of the cone to emit particles from. */
|
|
16
|
+
angle: number;
|
|
17
|
+
/** Radius of the shape to emit particles from. */
|
|
18
|
+
radius: number;
|
|
19
|
+
/** Length of the cone to emit particles from. */
|
|
20
|
+
length: number;
|
|
21
|
+
/** Cone emitter subtype */
|
|
22
|
+
emitType: ConeEmitType;
|
|
23
|
+
constructor();
|
|
24
|
+
/**
|
|
25
|
+
* @inheritDoc
|
|
26
|
+
*/
|
|
27
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
28
|
+
/**
|
|
29
|
+
* @inheritDoc
|
|
30
|
+
*/
|
|
31
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
32
|
+
_generatePositionAndDirection(position: Vector3, direction: Vector3): void;
|
|
33
|
+
cloneTo(destShape: ConeShape): void;
|
|
34
|
+
clone(): ConeShape;
|
|
35
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { BoundingBox, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
/**
|
|
4
|
+
* Hemisphere emitter
|
|
5
|
+
*/
|
|
6
|
+
export declare class HemisphereShape extends BaseShape {
|
|
7
|
+
/** Radius of the shape to emit particles from. */
|
|
8
|
+
radius: number;
|
|
9
|
+
/** Whether emit from shell */
|
|
10
|
+
emitFromShell: boolean;
|
|
11
|
+
constructor();
|
|
12
|
+
/**
|
|
13
|
+
* @inheritDoc
|
|
14
|
+
*/
|
|
15
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
16
|
+
/**
|
|
17
|
+
* @inheritDoc
|
|
18
|
+
*/
|
|
19
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
20
|
+
_generatePositionAndDirection(position: Vector3, direction: Vector3): void;
|
|
21
|
+
cloneTo(destShape: HemisphereShape): void;
|
|
22
|
+
clone(): HemisphereShape;
|
|
23
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { BoundingBox, Rand, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { BaseShape } from "./BaseShape";
|
|
3
|
+
/**
|
|
4
|
+
* Sphere emitter
|
|
5
|
+
*/
|
|
6
|
+
export declare class SphereShape extends BaseShape {
|
|
7
|
+
/** Radius of the shape to emit particles from. */
|
|
8
|
+
radius: number;
|
|
9
|
+
/** Whether emit from shell */
|
|
10
|
+
emitFromShell: boolean;
|
|
11
|
+
constructor();
|
|
12
|
+
/**
|
|
13
|
+
* @inheritDoc
|
|
14
|
+
*/
|
|
15
|
+
protected _getShapeBoundBox(boundBox: BoundingBox): void;
|
|
16
|
+
/**
|
|
17
|
+
* @inheritDoc
|
|
18
|
+
*/
|
|
19
|
+
protected _getSpeedBoundBox(boundBox: BoundingBox): void;
|
|
20
|
+
_generatePositionAndDirection(position: Vector3, direction: Vector3, rand?: Rand, randomSeeds?: Uint32Array): void;
|
|
21
|
+
cloneTo(destShape: SphereShape): void;
|
|
22
|
+
clone(): SphereShape;
|
|
23
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The emission shape.
|
|
3
|
+
*/
|
|
4
|
+
export declare enum ParticleShapeType {
|
|
5
|
+
/** Emit from the volume of a box. */
|
|
6
|
+
Box = 0,
|
|
7
|
+
/** Emit from a circle. */
|
|
8
|
+
Circle = 1,
|
|
9
|
+
/** Emit from the base of a cone. */
|
|
10
|
+
Cone = 2,
|
|
11
|
+
/** Emit from a half-sphere. */
|
|
12
|
+
Hemisphere = 3,
|
|
13
|
+
/** Emit from a sphere. */
|
|
14
|
+
Sphere = 4
|
|
15
|
+
}
|
|
@@ -9,6 +9,7 @@ export declare class PhysicsScene {
|
|
|
9
9
|
private static _collision;
|
|
10
10
|
private _scene;
|
|
11
11
|
private _restTime;
|
|
12
|
+
private _fixedTimeStep;
|
|
12
13
|
private _colliders;
|
|
13
14
|
private _gravity;
|
|
14
15
|
private _nativePhysicsScene;
|
|
@@ -18,13 +19,16 @@ export declare class PhysicsScene {
|
|
|
18
19
|
private _onTriggerEnter;
|
|
19
20
|
private _onTriggerExit;
|
|
20
21
|
private _onTriggerStay;
|
|
21
|
-
/** The fixed time step in seconds at which physics are performed. */
|
|
22
|
-
fixedTimeStep: number;
|
|
23
22
|
/**
|
|
24
23
|
* The gravity of physics scene.
|
|
25
24
|
*/
|
|
26
25
|
get gravity(): Vector3;
|
|
27
26
|
set gravity(value: Vector3);
|
|
27
|
+
/**
|
|
28
|
+
* The fixed time step in seconds at which physics are performed.
|
|
29
|
+
*/
|
|
30
|
+
get fixedTimeStep(): number;
|
|
31
|
+
set fixedTimeStep(value: number);
|
|
28
32
|
constructor(scene: Scene);
|
|
29
33
|
/**
|
|
30
34
|
* Casts a ray through the Scene and returns the first hit.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
particle_common: string;
|
|
3
|
+
velocity_over_lifetime_module: string;
|
|
4
|
+
rotation_over_lifetime_module: string;
|
|
5
|
+
size_over_lifetime_module: string;
|
|
6
|
+
color_over_lifetime_module: string;
|
|
7
|
+
texture_sheet_animation_module: string;
|
|
8
|
+
sphere_billboard: string;
|
|
9
|
+
stretched_billboard: string;
|
|
10
|
+
vertical_billboard: string;
|
|
11
|
+
horizontal_billboard: string;
|
|
12
|
+
particle_mesh: string;
|
|
13
|
+
};
|
|
14
|
+
export default _default;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Engine } from "../Engine";
|
|
2
|
+
import { CullingResults } from "../RenderPipeline/CullingResults";
|
|
3
|
+
import { RenderContext } from "../RenderPipeline/RenderContext";
|
|
4
|
+
/**
|
|
5
|
+
* PipelinePass is a base class for all pipeline passes.
|
|
6
|
+
*/
|
|
7
|
+
export declare abstract class PipelinePass {
|
|
8
|
+
protected _engine: Engine;
|
|
9
|
+
constructor(engine: Engine);
|
|
10
|
+
/**
|
|
11
|
+
* Called before rendering a camera, override this method to configure the camera If you need to configure the camera clear flag or render target.
|
|
12
|
+
* @param context - Rendering context
|
|
13
|
+
* @param cullingResults - Culling results
|
|
14
|
+
*/
|
|
15
|
+
abstract onRender(context: RenderContext, cullingResults: CullingResults): void;
|
|
16
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* High-performance unordered array, delete uses exchange method to improve performance, internal capacity only increases.
|
|
3
|
+
*/
|
|
4
|
+
export declare class DisorderedArray<T> {
|
|
5
|
+
_elements: T[];
|
|
6
|
+
length: number;
|
|
7
|
+
constructor(count?: number);
|
|
8
|
+
add(element: T): void;
|
|
9
|
+
delete(element: T): void;
|
|
10
|
+
get(index: number): T;
|
|
11
|
+
/**
|
|
12
|
+
*
|
|
13
|
+
* @param index
|
|
14
|
+
* @returns The replaced item is used to reset its index.
|
|
15
|
+
*/
|
|
16
|
+
deleteByIndex(index: number): T;
|
|
17
|
+
garbageCollection(): void;
|
|
18
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Used to update tags.
|
|
3
|
+
*/
|
|
4
|
+
export declare abstract class UpdateFlag {
|
|
5
|
+
/**
|
|
6
|
+
* Dispatch.
|
|
7
|
+
* @param bit - Bit
|
|
8
|
+
* @param param - Parameter
|
|
9
|
+
*/
|
|
10
|
+
abstract dispatch(bit?: number, param?: Object): void;
|
|
11
|
+
/**
|
|
12
|
+
* Clear.
|
|
13
|
+
*/
|
|
14
|
+
clearFromManagers(): void;
|
|
15
|
+
/**
|
|
16
|
+
* Destroy.
|
|
17
|
+
*/
|
|
18
|
+
destroy(): void;
|
|
19
|
+
private _removeFromManagers;
|
|
20
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export declare class Utils {
|
|
2
|
+
/**
|
|
3
|
+
* Fast remove an element from array.
|
|
4
|
+
* @param array - Array
|
|
5
|
+
* @param item - Element
|
|
6
|
+
*/
|
|
7
|
+
static removeFromArray(array: any[], item: any): boolean;
|
|
8
|
+
/**
|
|
9
|
+
* Decodes a given Uint8Array into a string.
|
|
10
|
+
*/
|
|
11
|
+
static decodeText(array: Uint8Array): string;
|
|
12
|
+
/**
|
|
13
|
+
* Judge whether the url is absolute url.
|
|
14
|
+
* @param url - The url to be judged.
|
|
15
|
+
* @returns Whether the url is absolute url.
|
|
16
|
+
*/
|
|
17
|
+
static isAbsoluteUrl(url: string): boolean;
|
|
18
|
+
/**
|
|
19
|
+
* Get the values of an object.
|
|
20
|
+
*/
|
|
21
|
+
static objectValues(obj: any): any[];
|
|
22
|
+
/**
|
|
23
|
+
* Convert a relative URL to an absolute URL based on a given base URL.
|
|
24
|
+
* @param baseUrl - The base url.
|
|
25
|
+
* @param relativeUrl - The relative url.
|
|
26
|
+
* @returns The resolved url.
|
|
27
|
+
*/
|
|
28
|
+
static resolveAbsoluteUrl(baseUrl: string, relativeUrl: string): string;
|
|
29
|
+
private static _stringToPath;
|
|
30
|
+
private static _formatRelativePath;
|
|
31
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Engine } from "../Engine";
|
|
2
|
+
import { EnumXRMode } from "./enum/EnumXRMode";
|
|
3
|
+
import { EnumXRFeature } from "./enum/EnumXRFeature";
|
|
4
|
+
import { EnumXRTrackingMode } from "./enum/EnumXRTrackingMode";
|
|
5
|
+
import { XRFeature } from "./feature/XRFeature";
|
|
6
|
+
import { EnumXRSubsystem } from "./enum/EnumXRSubsystem";
|
|
7
|
+
import { XRProvider } from "./provider/XRProvider";
|
|
8
|
+
import { XRSubsystem } from "./subsystem/XRSubsystem";
|
|
9
|
+
type FeatureConstructor = new (engine: Engine) => XRFeature;
|
|
10
|
+
export declare class XRManager {
|
|
11
|
+
private _engine;
|
|
12
|
+
private _provider;
|
|
13
|
+
private _features;
|
|
14
|
+
private _subsystems;
|
|
15
|
+
private _isPaused;
|
|
16
|
+
isSupportedMode(mode: EnumXRMode): Promise<void>;
|
|
17
|
+
isSupportedTrackingMode(mode: EnumXRTrackingMode): Promise<void>;
|
|
18
|
+
isSupportedFeature(feature: EnumXRFeature): Promise<void>;
|
|
19
|
+
getFeature<T extends XRFeature>(feature: EnumXRFeature): T;
|
|
20
|
+
enableFeature(feature: EnumXRFeature): void;
|
|
21
|
+
disableFeature(feature: EnumXRFeature): void;
|
|
22
|
+
getSubsystem<T extends XRSubsystem>(subsystem: EnumXRSubsystem): T;
|
|
23
|
+
initialize(mode: EnumXRMode, trackingMode: EnumXRTrackingMode, requestFeatures?: EnumXRFeature[]): Promise<void>;
|
|
24
|
+
start(): Promise<void>;
|
|
25
|
+
pause(): void;
|
|
26
|
+
resume(): void;
|
|
27
|
+
destroy(): void;
|
|
28
|
+
constructor(engine: Engine, type: new (engine: Engine) => XRProvider);
|
|
29
|
+
}
|
|
30
|
+
export declare function registerFeature(feature: EnumXRFeature, dependentSubsystem?: EnumXRSubsystem[]): (featureConstructor: FeatureConstructor) => void;
|
|
31
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Script } from "../../Script";
|
|
2
|
+
import { EnumXRInputSource } from "../enum/EnumXRInputSource";
|
|
3
|
+
import { EnumXRTrackingMode } from "../enum/EnumXRTrackingMode";
|
|
4
|
+
export declare class XRPoseDriver extends Script {
|
|
5
|
+
source: EnumXRInputSource;
|
|
6
|
+
updateType: EnumXRTrackingMode;
|
|
7
|
+
private _xrManager;
|
|
8
|
+
onLateUpdate(): void;
|
|
9
|
+
onAwake(): void;
|
|
10
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Matrix, Quaternion, Vector3 } from "@galacean/engine-math";
|
|
2
|
+
import { EnumXRDevicePhase } from "../enum/EnumXRDevicePhase";
|
|
3
|
+
export declare class XRDevice {
|
|
4
|
+
matrix: Matrix;
|
|
5
|
+
position: Vector3;
|
|
6
|
+
linearVelocity: Vector3;
|
|
7
|
+
quaternion: Quaternion;
|
|
8
|
+
phase: EnumXRDevicePhase;
|
|
9
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { XRDevice } from "./XRDevice";
|
|
2
|
+
import { EnumXRButton } from "../enum/EnumXRButton";
|
|
3
|
+
import { DisorderedArray } from "../../DisorderedArray";
|
|
4
|
+
export declare class XRHandle extends XRDevice {
|
|
5
|
+
pressedButtons: EnumXRButton;
|
|
6
|
+
upMap: number[];
|
|
7
|
+
downMap: number[];
|
|
8
|
+
upList: DisorderedArray<EnumXRButton>;
|
|
9
|
+
downList: DisorderedArray<EnumXRButton>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Camera } from "../../Camera";
|
|
2
|
+
import { EnumXRInputSource } from "../enum/EnumXRInputSource";
|
|
3
|
+
import { XRFeature } from "./XRFeature";
|
|
4
|
+
export declare class XRCameraManager extends XRFeature {
|
|
5
|
+
private _cameras;
|
|
6
|
+
private _automaticNear;
|
|
7
|
+
private _customNear;
|
|
8
|
+
private _automaticFar;
|
|
9
|
+
private _customFar;
|
|
10
|
+
get near(): number;
|
|
11
|
+
set near(value: number);
|
|
12
|
+
get far(): number;
|
|
13
|
+
set far(value: number);
|
|
14
|
+
attachCamera(source: EnumXRInputSource, camera: Camera): void;
|
|
15
|
+
detachCamera(source: EnumXRInputSource): void;
|
|
16
|
+
getCamera(source: EnumXRInputSource): Camera;
|
|
17
|
+
onUpdate(): void;
|
|
18
|
+
onEnable(): void;
|
|
19
|
+
onDisable(): void;
|
|
20
|
+
onDestroy(): void;
|
|
21
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Engine } from "../../Engine";
|
|
2
|
+
export declare abstract class XRFeature {
|
|
3
|
+
protected _engine: Engine;
|
|
4
|
+
/**
|
|
5
|
+
* Enable an instance of a feature.
|
|
6
|
+
* This method needs to be override.
|
|
7
|
+
* @returns
|
|
8
|
+
*/
|
|
9
|
+
onEnable(): void;
|
|
10
|
+
/**
|
|
11
|
+
* Disable an instance of a feature.
|
|
12
|
+
* This method needs to be override.
|
|
13
|
+
* @returns
|
|
14
|
+
*/
|
|
15
|
+
onDisable(): void;
|
|
16
|
+
/**
|
|
17
|
+
* Update an instance of a feature.
|
|
18
|
+
* This method needs to be override.
|
|
19
|
+
* @returns
|
|
20
|
+
*/
|
|
21
|
+
onUpdate(): void;
|
|
22
|
+
/**
|
|
23
|
+
* Destroy an instance of a feature.
|
|
24
|
+
* This method needs to be override.
|
|
25
|
+
* @returns
|
|
26
|
+
*/
|
|
27
|
+
onDestroy(): void;
|
|
28
|
+
constructor(engine: Engine);
|
|
29
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Entity } from "../../Entity";
|
|
2
|
+
import { XRFeature } from "./XRFeature";
|
|
3
|
+
export declare class XRImageTrackManager extends XRFeature {
|
|
4
|
+
addImage(): void;
|
|
5
|
+
removeImage(): void;
|
|
6
|
+
getTrackedObject(): Entity;
|
|
7
|
+
onEnable(): void;
|
|
8
|
+
onDisable(): void;
|
|
9
|
+
onDestroy(): void;
|
|
10
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Engine } from "../../Engine";
|
|
2
|
+
import { XRDevice } from "../data/XRDevice";
|
|
3
|
+
import { EnumXRButton } from "../enum/EnumXRButton";
|
|
4
|
+
import { EnumXRInputSource } from "../enum/EnumXRInputSource";
|
|
5
|
+
import { XRFeature } from "./XRFeature";
|
|
6
|
+
export declare class XRInputManager extends XRFeature {
|
|
7
|
+
private _subSystem;
|
|
8
|
+
getDevice<T extends XRDevice>(source: EnumXRInputSource): T;
|
|
9
|
+
isButtonDown(handedness: EnumXRInputSource, button: EnumXRButton): boolean;
|
|
10
|
+
isButtonUp(handedness: EnumXRInputSource, button: EnumXRButton): boolean;
|
|
11
|
+
isButtonHeldDown(handedness: EnumXRInputSource, button: EnumXRButton): boolean;
|
|
12
|
+
onEnable(): void;
|
|
13
|
+
onDisable(): void;
|
|
14
|
+
onDestroy(): void;
|
|
15
|
+
constructor(engine: Engine);
|
|
16
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export { XRManager, registerFeature } from "./XRManager";
|
|
2
|
+
export { EnumXRMode } from "./enum/EnumXRMode";
|
|
3
|
+
export { EnumXRButton } from "./enum/EnumXRButton";
|
|
4
|
+
export { EnumXRFeature } from "./enum/EnumXRFeature";
|
|
5
|
+
export { EnumXRSubsystem } from "./enum/EnumXRSubsystem";
|
|
6
|
+
export { EnumXRDevicePhase } from "./enum/EnumXRDevicePhase";
|
|
7
|
+
export { EnumXRInputSource } from "./enum/EnumXRInputSource";
|
|
8
|
+
export { EnumXRTrackingMode } from "./enum/EnumXRTrackingMode";
|
|
9
|
+
export { XRInputManager } from "./feature/XRInputManager";
|
|
10
|
+
export { XRCameraManager } from "./feature/XRCameraManager";
|
|
11
|
+
export { XRImageTrackManager } from "./feature/XRImageTrackManager";
|
|
12
|
+
export { XRSubsystem } from "./subsystem/XRSubsystem";
|
|
13
|
+
export { XRInputSubsystem } from "./subsystem/XRInputSubsystem";
|
|
14
|
+
export { XRProvider } from "./provider/XRProvider";
|
|
15
|
+
export { XRPoseDriver } from "./component/XRPoseDriver";
|
|
16
|
+
export { XRDevice } from "./data/XRDevice";
|
|
17
|
+
export { XRCamera } from "./data/XRCamera";
|
|
18
|
+
export { XRHandle } from "./data/XRHandle";
|