@galacean/effects-core 2.1.0-alpha.1 → 2.1.0-alpha.2

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.
@@ -97,6 +97,8 @@ export declare class BezierCurve extends ValueGetter<number> {
97
97
  timeInterval: number;
98
98
  valueInterval: number;
99
99
  curve: BezierEasing;
100
+ timeStart: number;
101
+ timeEnd: number;
100
102
  }>;
101
103
  keys: number[][];
102
104
  onCreate(props: spec.BezierKeyframeValue[]): void;
@@ -139,6 +139,12 @@ export declare class ParticleMesh implements ParticleMeshData {
139
139
  readonly textureOffsets: number[];
140
140
  readonly maxCount: number;
141
141
  readonly anchor: Vector2;
142
+ private cachedVelocity;
143
+ private cachedRotationVector3;
144
+ private cachedRotationMatrix;
145
+ private cachedLinearMove;
146
+ private tempMatrix3;
147
+ private tempVector3;
142
148
  VERT_MAX_KEY_FRAME_COUNT: number;
143
149
  constructor(engine: Engine, props: ParticleMeshProps);
144
150
  getPointColor(index: number): number[];
@@ -147,11 +153,12 @@ export declare class ParticleMesh implements ParticleMeshData {
147
153
  onUpdate(dt: number): void;
148
154
  minusTime(time: number): void;
149
155
  calculateTranslation(velocity: Vector3, t0: number, t1: number, duration: number): Vector3;
150
- transformFromRotation(rot: Vector3, life: number, dur: number, aSeed: number): Matrix3;
151
- mat3FromRotation(rotation: Vector3): Matrix3;
152
- calLinearMov(time: number, duration: number, aSeed: number): Vector3;
156
+ transformFromRotation(rot: Vector3, life: number, dur: number, aSeed: number, result: Matrix3): Matrix3;
157
+ mat3FromRotation(rotation: Vector3, result: Matrix3): Matrix3;
158
+ calLinearMov(time: number, duration: number, aSeed: number, result: Vector3): Vector3;
153
159
  removePoint(index: number): void;
154
160
  setPoint(index: number, point: Point): void;
161
+ private expandArray;
155
162
  }
156
163
  export declare function getParticleMeshShader(item: spec.ParticleItem, gpuCapability: GPUCapability, env?: string): {
157
164
  shader: SharedShaderWithSource;
@@ -1,5 +1,5 @@
1
1
  import { TextureSourceType } from './types';
2
- import type { TextureFactorySourceFrom, TextureSourceOptions, TextureDataType } from './types';
2
+ import type { TextureFactorySourceFrom, TextureSourceOptions, TextureDataType, TextureOptionsBase } from './types';
3
3
  import type { Engine } from '../engine';
4
4
  import { EffectsObject } from '../effects-object';
5
5
  /**
@@ -36,7 +36,7 @@ export declare abstract class Texture extends EffectsObject {
36
36
  * @param url - 要创建的 Texture URL
37
37
  * @since 2.0.0
38
38
  */
39
- static fromImage(url: string, engine: Engine): Promise<Texture>;
39
+ static fromImage(url: string, engine: Engine, options?: TextureOptionsBase): Promise<Texture>;
40
40
  /**
41
41
  * 通过数据创建 Texture 对象。
42
42
  * @param data - 要创建的 Texture 数据
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@galacean/effects-core",
3
- "version": "2.1.0-alpha.1",
3
+ "version": "2.1.0-alpha.2",
4
4
  "description": "Galacean Effects runtime core for the web",
5
5
  "module": "./dist/index.mjs",
6
6
  "main": "./dist/index.js",