@galacean/engine-core 2.0.0-alpha.38 → 2.0.0-alpha.40
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 +10818 -11218
- package/dist/main.js.map +1 -1
- package/dist/module.js +10819 -11217
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/2d/sprite/SpriteMask.d.ts +4 -0
- package/types/2d/sprite/SpriteRenderer.d.ts +4 -0
- package/types/Canvas.d.ts +23 -7
- package/types/Renderer.d.ts +6 -1
- package/types/Signal.d.ts +7 -1
- package/types/Transform.d.ts +6 -1
- package/types/UpdateFlag.d.ts +1 -1
- package/types/animation/AnimationClip.d.ts +1 -1
- package/types/animation/Animator.d.ts +6 -1
- package/types/asset/ResourceManager.d.ts +16 -0
- package/types/base/DataObject.d.ts +6 -0
- package/types/base/index.d.ts +1 -0
- package/types/clone/CloneDecorators.d.ts +17 -0
- package/types/clone/ComponentCloner.d.ts +1 -15
- package/types/clone/ICloneHook.d.ts +12 -0
- package/types/index.d.ts +3 -3
- package/types/mesh/MeshRenderer.d.ts +4 -0
- package/types/mesh/Skin.d.ts +2 -2
- package/types/mesh/SkinnedMeshRenderer.d.ts +4 -0
- package/types/particle/ParticleGenerator.d.ts +7 -1
- package/types/particle/ParticleRenderer.d.ts +4 -0
- package/types/particle/modules/Burst.d.ts +2 -1
- package/types/particle/modules/MainModule.d.ts +7 -2
- package/types/particle/modules/ParticleCompositeCurve.d.ts +2 -1
- package/types/particle/modules/ParticleCompositeGradient.d.ts +6 -1
- package/types/particle/modules/ParticleCurve.d.ts +3 -2
- package/types/particle/modules/ParticleGeneratorModule.d.ts +2 -1
- package/types/particle/modules/ParticleGradient.d.ts +4 -3
- package/types/particle/modules/SubEmitter.d.ts +2 -1
- package/types/particle/modules/shape/BaseShape.d.ts +3 -2
- package/types/particle/modules/shape/MeshShape.d.ts +6 -1
- package/types/physics/Collider.d.ts +6 -2
- package/types/physics/DynamicCollider.d.ts +4 -0
- package/types/physics/joint/JointLimits.d.ts +2 -4
- package/types/physics/joint/JointMotor.d.ts +2 -4
- package/types/physics/shape/ColliderShape.d.ts +7 -2
- package/types/physics/shape/MeshColliderShape.d.ts +4 -3
- package/types/postProcess/PostProcessEffect.d.ts +2 -1
- package/types/postProcess/PostProcessEffectParameter.d.ts +2 -1
- package/types/shader/ShaderData.d.ts +8 -1
- package/types/shader/state/BlendState.d.ts +2 -1
- package/types/shader/state/DepthState.d.ts +2 -1
- package/types/shader/state/RasterState.d.ts +2 -1
- package/types/shader/state/RenderState.d.ts +2 -1
- package/types/shader/state/RenderTargetBlendState.d.ts +2 -1
- package/types/shader/state/StencilState.d.ts +2 -1
- package/types/clone/CloneManager.d.ts +0 -31
- package/types/clone/enums/CloneMode.d.ts +0 -13
- /package/types/clone/{CloneUtils.d.ts → CloneUtil.d.ts} +0 -0
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
2
2
|
/**
|
|
3
3
|
* The JointMotor is used to motorize a joint.
|
|
4
4
|
*/
|
|
5
|
-
export declare class JointMotor {
|
|
6
|
-
/** @internal */
|
|
7
|
-
_updateFlagManager: UpdateFlagManager;
|
|
5
|
+
export declare class JointMotor extends DataObject {
|
|
8
6
|
private _targetVelocity;
|
|
9
7
|
private _forceLimit;
|
|
10
8
|
private _gearRatio;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { PhysicsMaterial } from "../PhysicsMaterial";
|
|
2
3
|
import { Vector3 } from "@galacean/engine-math";
|
|
3
4
|
import { Collider } from "../Collider";
|
|
4
|
-
import {
|
|
5
|
+
import type { ICloneHook } from "../../clone/ICloneHook";
|
|
5
6
|
/**
|
|
6
7
|
* Abstract class for collider shapes.
|
|
7
8
|
*/
|
|
8
|
-
export declare abstract class ColliderShape implements
|
|
9
|
+
export declare abstract class ColliderShape extends DataObject implements ICloneHook<ColliderShape> {
|
|
9
10
|
private static _idGenerator;
|
|
10
11
|
protected _id: number;
|
|
11
12
|
protected _material: PhysicsMaterial;
|
|
@@ -55,6 +56,10 @@ export declare abstract class ColliderShape implements ICustomClone {
|
|
|
55
56
|
* @returns The distance between the point and the shape
|
|
56
57
|
*/
|
|
57
58
|
getClosestPoint(point: Vector3, outClosestPoint: Vector3): number;
|
|
59
|
+
/**
|
|
60
|
+
* @inheritdoc
|
|
61
|
+
*/
|
|
62
|
+
_onClone(target: ColliderShape): void;
|
|
58
63
|
protected _syncNative(): void;
|
|
59
64
|
private _setPosition;
|
|
60
65
|
private _setRotation;
|
|
@@ -11,7 +11,6 @@ export declare class MeshColliderShape extends ColliderShape {
|
|
|
11
11
|
private _positions;
|
|
12
12
|
private _indices;
|
|
13
13
|
private _cookingFlags;
|
|
14
|
-
private _isShapeAttached;
|
|
15
14
|
/**
|
|
16
15
|
* Cooking flags for this mesh collider shape.
|
|
17
16
|
*/
|
|
@@ -35,11 +34,13 @@ export declare class MeshColliderShape extends ColliderShape {
|
|
|
35
34
|
* {@inheritDoc ColliderShape.getClosestPoint}
|
|
36
35
|
*/
|
|
37
36
|
getClosestPoint(point: Vector3, outClosestPoint: Vector3): number;
|
|
37
|
+
/**
|
|
38
|
+
* @inheritdoc
|
|
39
|
+
*/
|
|
40
|
+
_onClone(target: MeshColliderShape): void;
|
|
38
41
|
private _clearMeshData;
|
|
39
42
|
private _destroyNativeShape;
|
|
40
43
|
private _extractMeshData;
|
|
41
44
|
private _updateNativeShapeData;
|
|
42
|
-
private _detachFromCollider;
|
|
43
|
-
private _attachToCollider;
|
|
44
45
|
private _createNativeShape;
|
|
45
46
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { DataObject } from "../base/DataObject";
|
|
1
2
|
/**
|
|
2
3
|
* The base class for post process effect.
|
|
3
4
|
*/
|
|
4
|
-
export declare class PostProcessEffect {
|
|
5
|
+
export declare class PostProcessEffect extends DataObject {
|
|
5
6
|
private _enabled;
|
|
6
7
|
private _parameters;
|
|
7
8
|
private _parameterInitialized;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DataObject } from "../base/DataObject";
|
|
1
2
|
import { Color, Vector2, Vector3, Vector4 } from "@galacean/engine-math";
|
|
2
3
|
import { Texture } from "../texture";
|
|
3
4
|
/**
|
|
@@ -5,7 +6,7 @@ import { Texture } from "../texture";
|
|
|
5
6
|
* @remarks
|
|
6
7
|
* The parameter will be mixed to a final value and be used in post process manager.
|
|
7
8
|
*/
|
|
8
|
-
export declare abstract class PostProcessEffectParameter<T> {
|
|
9
|
+
export declare abstract class PostProcessEffectParameter<T> extends DataObject {
|
|
9
10
|
/**
|
|
10
11
|
* Whether the parameter is enabled.
|
|
11
12
|
*/
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
+
import { DataObject } from "../base/DataObject";
|
|
1
2
|
import { IClone } from "@galacean/engine-design";
|
|
2
3
|
import { Color, Matrix, Vector2, Vector3, Vector4 } from "@galacean/engine-math";
|
|
3
4
|
import { IReferable } from "../asset/IReferable";
|
|
5
|
+
import type { ICloneHook } from "../clone/ICloneHook";
|
|
4
6
|
import { Texture } from "../texture/Texture";
|
|
5
7
|
import { ShaderMacro } from "./ShaderMacro";
|
|
6
8
|
import { ShaderProperty } from "./ShaderProperty";
|
|
7
9
|
/**
|
|
8
10
|
* Shader data collection,Correspondence includes shader properties data and macros data.
|
|
9
11
|
*/
|
|
10
|
-
export declare class ShaderData implements IReferable, IClone {
|
|
12
|
+
export declare class ShaderData extends DataObject implements IReferable, IClone, ICloneHook<ShaderData> {
|
|
11
13
|
private _batchSharedFields;
|
|
12
14
|
private _macroMap;
|
|
13
15
|
private _refCount;
|
|
@@ -347,6 +349,11 @@ export declare class ShaderData implements IReferable, IClone {
|
|
|
347
349
|
getProperties(out: ShaderProperty[]): void;
|
|
348
350
|
clone(): ShaderData;
|
|
349
351
|
cloneTo(target: ShaderData): void;
|
|
352
|
+
/**
|
|
353
|
+
* @inheritdoc
|
|
354
|
+
*/
|
|
355
|
+
_onClone(target: ShaderData): void;
|
|
356
|
+
private _addTexturesReferCount;
|
|
350
357
|
private _updateRendererBatchSharedFields;
|
|
351
358
|
}
|
|
352
359
|
export type ShaderPropertyValueType = number | Vector2 | Vector3 | Vector4 | Color | Matrix | Texture | Texture[] | Int32Array | Float32Array;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { Color } from "@galacean/engine-math";
|
|
2
3
|
import { RenderTargetBlendState } from "./RenderTargetBlendState";
|
|
3
4
|
/**
|
|
4
5
|
* Blend state.
|
|
5
6
|
*/
|
|
6
|
-
export declare class BlendState {
|
|
7
|
+
export declare class BlendState extends DataObject {
|
|
7
8
|
private static _getGLBlendFactor;
|
|
8
9
|
private static _getGLBlendOperation;
|
|
9
10
|
/** The blend state of the render target. */
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { CompareFunction } from "../enums/CompareFunction";
|
|
2
3
|
/**
|
|
3
4
|
* Depth state.
|
|
4
5
|
*/
|
|
5
|
-
export declare class DepthState {
|
|
6
|
+
export declare class DepthState extends DataObject {
|
|
6
7
|
private static _getGLCompareFunction;
|
|
7
8
|
/** Whether to enable the depth test. */
|
|
8
9
|
enabled: boolean;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { CullMode } from "../enums/CullMode";
|
|
2
3
|
/**
|
|
3
4
|
* Raster state.
|
|
4
5
|
*/
|
|
5
|
-
export declare class RasterState {
|
|
6
|
+
export declare class RasterState extends DataObject {
|
|
6
7
|
/** Specifies whether or not front- and/or back-facing polygons can be culled. */
|
|
7
8
|
cullMode: CullMode;
|
|
8
9
|
/** The multiplier by which an implementation-specific value is multiplied with to create a constant depth offset. */
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { RenderQueueType } from "../enums/RenderQueueType";
|
|
2
3
|
import { BlendState } from "./BlendState";
|
|
3
4
|
import { DepthState } from "./DepthState";
|
|
@@ -6,7 +7,7 @@ import { StencilState } from "./StencilState";
|
|
|
6
7
|
/**
|
|
7
8
|
* Render state.
|
|
8
9
|
*/
|
|
9
|
-
export declare class RenderState {
|
|
10
|
+
export declare class RenderState extends DataObject {
|
|
10
11
|
/** Blend state. */
|
|
11
12
|
readonly blendState: BlendState;
|
|
12
13
|
/** Depth state. */
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { BlendOperation } from "../enums/BlendOperation";
|
|
2
3
|
import { BlendFactor } from "../enums/BlendFactor";
|
|
3
4
|
import { ColorWriteMask } from "../enums/ColorWriteMask";
|
|
4
5
|
/**
|
|
5
6
|
* The blend state of the render target.
|
|
6
7
|
*/
|
|
7
|
-
export declare class RenderTargetBlendState {
|
|
8
|
+
export declare class RenderTargetBlendState extends DataObject {
|
|
8
9
|
/** Whether to enable blend. */
|
|
9
10
|
enabled: boolean;
|
|
10
11
|
/** color (RGB) blend operation. */
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { DataObject } from "../../base/DataObject";
|
|
1
2
|
import { CompareFunction } from "../enums/CompareFunction";
|
|
2
3
|
import { StencilOperation } from "../enums/StencilOperation";
|
|
3
4
|
/**
|
|
4
5
|
* Stencil state.
|
|
5
6
|
*/
|
|
6
|
-
export declare class StencilState {
|
|
7
|
+
export declare class StencilState extends DataObject {
|
|
7
8
|
private static _getGLCompareFunction;
|
|
8
9
|
private static _getGLStencilOperation;
|
|
9
10
|
/** Whether to enable stencil test. */
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Property decorator, ignore the property when cloning.
|
|
3
|
-
*/
|
|
4
|
-
export declare function ignoreClone(target: Object, propertyKey: string): void;
|
|
5
|
-
/**
|
|
6
|
-
* Property decorator, assign value to the property when cloning.
|
|
7
|
-
*
|
|
8
|
-
* @remarks
|
|
9
|
-
* If it's a primitive type, the value will be copied.
|
|
10
|
-
* If it's a class type, the reference will be copied.
|
|
11
|
-
*/
|
|
12
|
-
export declare function assignmentClone(target: Object, propertyKey: string): void;
|
|
13
|
-
/**
|
|
14
|
-
* Property decorator, shallow clone the property when cloning.
|
|
15
|
-
* After cloning, it will keep its own reference independent, and use the method of assignment to clone all its internal properties.
|
|
16
|
-
* if the internal property is a primitive type, the value will be copied, if the internal property is a reference type, its reference address will be copied.。
|
|
17
|
-
*
|
|
18
|
-
* @remarks
|
|
19
|
-
* Applicable to Object, Array, TypedArray and Class types.
|
|
20
|
-
*/
|
|
21
|
-
export declare function shallowClone(target: Object, propertyKey: string): void;
|
|
22
|
-
/**
|
|
23
|
-
* Property decorator, deep clone the property when cloning.
|
|
24
|
-
* After cloning, it will maintain its own reference independence, and all its internal deep properties will remain completely independent.
|
|
25
|
-
*
|
|
26
|
-
* @remarks
|
|
27
|
-
* Applicable to Object, Array, TypedArray and Class types.
|
|
28
|
-
* If Class is encountered during the deep cloning process, the custom cloning function of the object will be called first.
|
|
29
|
-
* Custom cloning requires the object to implement the IClone interface.
|
|
30
|
-
*/
|
|
31
|
-
export declare function deepClone(target: Object, propertyKey: string): void;
|
|
File without changes
|