@vvfx/sdk 0.1.19-alpha.12 → 0.1.19-alpha.13

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/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as _galacean_effects from '@galacean/effects';
2
- import { math, spec, Player } from '@galacean/effects';
2
+ import { math, spec, Player, EventEmitter, Composition, VFXItem, Constructor, Component } from '@galacean/effects';
3
3
  export { generateGUID, spec } from '@galacean/effects';
4
4
  import { Point } from '@pixi/constants';
5
5
 
@@ -290,6 +290,108 @@ declare class Box2 {
290
290
  rotate(angle: number, center?: Vector2): this;
291
291
  }
292
292
 
293
+ declare class Quaternion extends math.Quaternion {
294
+ }
295
+
296
+ declare class Vector3 extends math.Vector3 {
297
+ clone(): Vector3;
298
+ /**
299
+ * 由空间变换矩阵保存三维分量
300
+ * @param {Matrix4} m 四维矩阵
301
+ * @param {number} index 下标
302
+ * @returns {Vec3} 指定三维分量
303
+ */
304
+ setFromMatrixColumn(m: Matrix4, index: number): this;
305
+ applyEuler(euler: Euler, _out?: Vector3): this;
306
+ /**
307
+ * 三维点根据四元数绕点的旋转
308
+ * @param {Quaternion} q 四元数
309
+ * @param {Vec3} [center=new Vec3()] 旋转中心
310
+ * @returns {Vec3} 旋转结果
311
+ */
312
+ applyQuaternion(q: Quaternion, center?: Vector3): this;
313
+ /**
314
+ * 由空间变换矩阵保存三维偏移值
315
+ * @param {Matrix4} m 四维矩阵
316
+ * @returns {Vec3} 偏移值
317
+ */
318
+ setFromMatrixPosition(m: Matrix4): this;
319
+ applyMatrix(matrix: Matrix4, center?: Vector3): this;
320
+ }
321
+
322
+ declare class Matrix4 extends math.Matrix4 {
323
+ /**
324
+ * 通过数组创建矩阵
325
+ * @param array - 数组
326
+ * @param [offset=0] - 起始偏移值
327
+ * @returns 矩阵
328
+ */
329
+ static fromArray(array: math.Matrix4DataType, offset?: number): Matrix4;
330
+ clone(): Matrix4;
331
+ compose(translation: Vector3, rotation: Quaternion, scale: Vector3, anchor?: math.Vector3): this;
332
+ /**
333
+ * 导出四维矩阵[三维空间变换矩阵]旋转部分
334
+ * @param {Matrix4} m 四维矩阵
335
+ * @returns {Matrix4} 导出结果
336
+ */
337
+ extractRotation(m: Matrix4): this;
338
+ /**
339
+ * 由欧拉角设置四维矩阵
340
+ * @param {Euler} euler 欧拉角
341
+ * @returns {Matrix4} 四维矩阵
342
+ */
343
+ makeRotationFromEuler(euler: Euler): this;
344
+ setPosition(position: Vector3): this;
345
+ }
346
+
347
+ declare class Euler extends math.Euler {
348
+ constructor(x?: number, y?: number, z?: number, order?: math.EulerOrder);
349
+ getInvertMatrixByEuler(): Matrix4;
350
+ /**
351
+ * 欧拉角保存于三维向量(应用于计算)
352
+ * @param {Vector3} [optionalResult] 目标保存对象
353
+ * @returns {Vector3} 保存结果
354
+ */
355
+ toDegreeVector3(optionalResult?: Vector3): Vector3;
356
+ /**
357
+ * 由角度三维向量构建欧拉角
358
+ * @param {Vector3} v 角度三维向量
359
+ * @param {EulerOrder} [order] 欧拉角顺序,默认为ZYX
360
+ * @returns {Euler} 欧拉角
361
+ */
362
+ setFromDegreeVector3(degree: Vector3, order?: math.EulerOrder): this;
363
+ }
364
+
365
+ declare class Plane {
366
+ distance: number;
367
+ normal: Vector3;
368
+ constructor(distance?: number, normal?: Vector3);
369
+ static set(distance: number, normal: Vector3): Plane;
370
+ set(distance: number, normal: Vector3): this;
371
+ static copy(target: Plane): Plane;
372
+ copy(target: Plane): this;
373
+ static setFromNormalAndCoplanarPoint(point: Vector3, normal: Vector3): Plane;
374
+ setFromNormalAndCoplanarPoint(point: Vector3, normal: Vector3): this;
375
+ clone(): Plane;
376
+ distanceToPoint(point: Vector3): number;
377
+ }
378
+
379
+ declare class Ray extends math.Ray {
380
+ origin: Vector3;
381
+ direction: Vector3;
382
+ constructor(origin?: Vector3, direction?: Vector3);
383
+ clone(): Ray;
384
+ rayCastPlane(plane: Plane, _target: Vector3): number;
385
+ at(t: number): Vector3;
386
+ /**
387
+ * 射线到平面的距离
388
+ * 当两个向量都是单位向量的时候,从a投影到b的距离等于从b投影到a的距离
389
+ * @param plane 平面
390
+ * @returns 射线到平面的距离
391
+ */
392
+ distanceToPlane(plane: Plane): number;
393
+ }
394
+
293
395
  type SizeAdaptDirection = 'x' | 'y';
294
396
 
295
397
  declare const MEDIA_TYPE: {
@@ -2154,6 +2256,12 @@ type EffectsCreateInfo = {
2154
2256
  */
2155
2257
  extension?: Record<string, any>;
2156
2258
  };
2259
+ type AsyncSpriteCreateInfo = SpriteCreateInfo & {
2260
+ textureId: string;
2261
+ };
2262
+ type AsyncVideoCreateInfo = VideoCreateInfo & {
2263
+ textureId: string;
2264
+ };
2157
2265
  /**
2158
2266
  * @description Frame 画板元素创建信息
2159
2267
  */
@@ -2297,6 +2405,857 @@ declare class UndoRedo {
2297
2405
  clear(): void;
2298
2406
  }
2299
2407
 
2408
+ declare function arrAdd<T>(arr: T[], item: T): void;
2409
+ declare function isObj(item: any): item is object;
2410
+ declare function deepEquals<T>(a: T, b: T): boolean;
2411
+ declare function deepClone<T>(target: T): T;
2412
+ declare function getColorByNormalizeColor(color: [number, number, number, number]): [number, number, number, number];
2413
+ declare function getNormalizeColorByColor(color: [number, number, number, number]): [number, number, number, number];
2414
+ declare function getTransformRatioByViewAndCamera(viewSize: Vector2, cameraPosition: Vector3, cameraFov: number, cameraNear: number, cameraFar: number, isReverse: boolean): {
2415
+ xRatio: number;
2416
+ yRatio: number;
2417
+ };
2418
+ declare function assertExist<T>(item: T | undefined | null, msg?: string): asserts item is T;
2419
+ declare function asserts(condition: any, msg?: string): asserts condition;
2420
+ /**
2421
+ * @example
2422
+ * Input: logger('log', ['VVFX', 'SDK'], 'xx is required');
2423
+ * Output: [VVFX SDK] xx is required
2424
+ */
2425
+ type Level = 'error' | 'info' | 'debug' | 'warn' | 'log';
2426
+ declare function logger(level: Level, prefixs: string[], ...args: any[]): void;
2427
+ declare function loadScriptAsync(src: string, attrs?: Record<string, string>): Promise<unknown>;
2428
+ declare function downloadBlob(buffer: BlobPart | BlobPart[], filename: string, mimeType?: string): void;
2429
+ declare function getUniqueName(name: string, names: string[]): string;
2430
+ /**
2431
+ * 深度比较两个值是否相等
2432
+ */
2433
+ declare function isEqual(a: unknown, b: unknown): boolean;
2434
+
2435
+ /**
2436
+ * @description 交互状态视图信息
2437
+ */
2438
+ type ViewInteractionParam = {
2439
+ /**
2440
+ * @description 视口宽度 - 红框区域像素大小
2441
+ */
2442
+ width: number;
2443
+ /**
2444
+ * @description 视口高度 - 红框区域像素大小
2445
+ */
2446
+ height: number;
2447
+ /**
2448
+ * @description 视口缩放比例
2449
+ */
2450
+ scale: number;
2451
+ /**
2452
+ * @description 视口位移信息
2453
+ */
2454
+ translation: Vector2;
2455
+ /**
2456
+ * @description 标尺宽度
2457
+ */
2458
+ rulerWidth: number;
2459
+ };
2460
+ /**
2461
+ * @description 交互状态相机信息
2462
+ */
2463
+ type CameraInteractionParam = {
2464
+ /**
2465
+ * @description 位置
2466
+ */
2467
+ position: Vector3;
2468
+ /**
2469
+ * @description 旋转角度
2470
+ */
2471
+ rotation: Vector3;
2472
+ /**
2473
+ * @description 视野初始中心
2474
+ */
2475
+ focusPosition: Vector3;
2476
+ /**
2477
+ * @description 视野初始角度
2478
+ */
2479
+ focusRotation: Vector3;
2480
+ /**
2481
+ * @description 投影矩阵
2482
+ */
2483
+ viewProjectionMatrix: Matrix4;
2484
+ /**
2485
+ * @description 逆投影矩阵
2486
+ */
2487
+ inverseViewProjectionMatrix: Matrix4;
2488
+ };
2489
+ declare const SafeConstraint: {
2490
+ topAdsorption: string;
2491
+ leftAdsorption: string;
2492
+ rightAdsorption: string;
2493
+ bottomAdsorption: string;
2494
+ centerAdsorption: string;
2495
+ bottomCenterAdsorption: string;
2496
+ };
2497
+ type ItemJSONInfo = {
2498
+ item: spec.VFXItemData;
2499
+ components: spec.ComponentData[];
2500
+ tracks: any[];
2501
+ playableAssets: any[];
2502
+ };
2503
+ type AlignType = 'left' | 'right' | 'horizontal-center' | 'top' | 'bottom' | 'vertical-center';
2504
+ type DistributeType = 'vertical-spacing' | 'horizontal-spacing';
2505
+ /**
2506
+ * @description 背景类型预设配置
2507
+ */
2508
+ type BackgroundPreset = {
2509
+ /**
2510
+ * @description 背景颜色
2511
+ */
2512
+ color?: string;
2513
+ /**
2514
+ * @description 背景图片/渐变
2515
+ */
2516
+ image?: string;
2517
+ /**
2518
+ * @description 背景重复方式
2519
+ */
2520
+ repeat?: string;
2521
+ /**
2522
+ * @description 背景位置
2523
+ */
2524
+ position?: string;
2525
+ /**
2526
+ * @description 背景大小
2527
+ */
2528
+ size?: string;
2529
+ };
2530
+ /**
2531
+ * @description 背景网格配置
2532
+ */
2533
+ type BackgroundGridConfig = {
2534
+ /**
2535
+ * @description 基础网格大小(像素)
2536
+ */
2537
+ baseSize: number;
2538
+ /**
2539
+ * @description 缩放循环阈值(默认 2,即 2x 时重置)
2540
+ */
2541
+ zoomCycle: number;
2542
+ /**
2543
+ * @description 最小网格大小限制
2544
+ */
2545
+ minSize: number;
2546
+ };
2547
+
2548
+ /**
2549
+ * @description 背景管理器
2550
+ * 负责管理画布背景的配置、渲染和跟随变换
2551
+ */
2552
+ declare class BackgroundManager {
2553
+ /**
2554
+ * @description 默认网格配置
2555
+ */
2556
+ static readonly DEFAULT_GRID_CONFIG: BackgroundGridConfig;
2557
+ /**
2558
+ * @description 背景预设配置
2559
+ */
2560
+ static readonly PRESETS: Record<string, BackgroundPreset>;
2561
+ private container;
2562
+ private config;
2563
+ /**
2564
+ * @description 当前背景位置(用于跟随移动)
2565
+ */
2566
+ private offsetX;
2567
+ private offsetY;
2568
+ constructor(config?: Partial<BackgroundGridConfig>);
2569
+ /**
2570
+ * @description 绑定容器元素
2571
+ * @param element 画布容器元素
2572
+ */
2573
+ attach(element: HTMLElement): void;
2574
+ /**
2575
+ * @description 解绑容器元素
2576
+ */
2577
+ detach(): void;
2578
+ /**
2579
+ * @description 应用背景预设
2580
+ * @param presetName 预设名称
2581
+ * @param color 可选的背景色覆盖
2582
+ */
2583
+ applyPreset(presetName: string, color?: string): boolean;
2584
+ /**
2585
+ * @description 设置纯色背景
2586
+ * @param color 颜色值
2587
+ */
2588
+ setColorBackground(color: string): void;
2589
+ /**
2590
+ * @description 设置图片背景
2591
+ * @param url 图片 URL
2592
+ */
2593
+ setImageBackground(url: string): void;
2594
+ /**
2595
+ * @description 更新背景变换(跟随画布移动和缩放)
2596
+ * @param shift 画布移动的偏移量
2597
+ * @param zoom 当前缩放比例
2598
+ */
2599
+ updateTransform(shift: {
2600
+ x: number;
2601
+ y: number;
2602
+ }, zoom: number): void;
2603
+ /**
2604
+ * @description 重置背景位置和大小
2605
+ */
2606
+ reset(): void;
2607
+ /**
2608
+ * @description 清除背景样式
2609
+ */
2610
+ private clearBackground;
2611
+ /**
2612
+ * @description 计算循环缩放比例
2613
+ * zoom 在 [1, 2) 时,bgZoom = zoom
2614
+ * zoom 在 [2, 4) 时,bgZoom = zoom / 2
2615
+ * zoom 在 [0.5, 1) 时,bgZoom = zoom / 0.5
2616
+ */
2617
+ private calculateZoomCycle;
2618
+ }
2619
+
2620
+ /**
2621
+ * @description 创建 Frame 元素的内部合成场景
2622
+ * @param frameId Frame 元素ID(用于标识)
2623
+ * @param size 场景尺寸 [width, height]
2624
+ * @param name 场景名称
2625
+ * @returns Frame 内部的合成场景
2626
+ */
2627
+ declare function createFrameCompositionScene(frameId: string, size: spec.vec2, name: string): spec.JSONScene;
2628
+ /**
2629
+ * @description 创建基础场景信息
2630
+ * @param viewSize 画布大小
2631
+ * @returns 场景信息
2632
+ */
2633
+ declare function getBasicScene(viewSize?: number[], name?: string): spec.JSONScene;
2634
+ declare function createSpriteItemJSON(spriteId: string, position: Vector3, rotation: Vector3, size: Vector2, scale: Vector3, name: string, texture?: string): ItemJSONInfo;
2635
+ /**
2636
+ * @description 创建视频生成器 Item JSON
2637
+ * @description 以 SpriteItem 形式渲染,但设置透明颜色
2638
+ * @description 在 content 中存储 isVideoGenerator 标记
2639
+ */
2640
+ declare function createVideoGeneratorItemJSON(id: string, position: Vector3, rotation: Vector3, size: Vector2, scale: Vector3, name: string): ItemJSONInfo;
2641
+ declare function createNullItemJSON(nullId: string, name: string, position: Vector3, scale?: Vector2, rotation?: Vector3, worldSize?: Vector2): ItemJSONInfo;
2642
+ declare function createTextItemJSON(textId: string, name: string, position: Vector3, rotation: Vector3, size: Vector2, fontInfo: spec.TextContentOptions): ItemJSONInfo;
2643
+ declare function createVideoItemJSON(videoId: string, position: Vector3, rotation: Vector3, size: Vector2, scale: Vector3, name: string, isMuted?: boolean, transparent?: boolean, volume?: number, playbackRate?: number, texture?: string, video?: string): ItemJSONInfo;
2644
+ /**
2645
+ * @description 创建预合成元素
2646
+ * @param effectsId 预合成元素ID
2647
+ * @param position 位置信息
2648
+ * @param rotation 旋转信息
2649
+ * @param scale 缩放信息
2650
+ * @param name 名称
2651
+ */
2652
+ declare function createCompositionItemJSON(effectsId: string, position: Vector3, rotation: Vector3, scale: Vector3, name: string): {
2653
+ item: spec.VFXItemData;
2654
+ components: never[];
2655
+ tracks: {
2656
+ id: string;
2657
+ dataType: spec.DataType;
2658
+ children: never[];
2659
+ clips: {
2660
+ start: number;
2661
+ duration: number;
2662
+ endBehavior: spec.EndBehavior;
2663
+ asset: {
2664
+ id: string;
2665
+ };
2666
+ }[];
2667
+ }[];
2668
+ playableAssets: {
2669
+ id: string;
2670
+ dataType: spec.DataType;
2671
+ }[];
2672
+ };
2673
+ /**
2674
+ * @description 添加元素信息到JSON
2675
+ * @param scene 场景信息
2676
+ * @param itemInfo 元素信息
2677
+ */
2678
+ declare function addItemInfoToScene(scene: spec.JSONScene, itemInfo: ItemJSONInfo): void;
2679
+ /**
2680
+ * @description 设置元素父节点信息
2681
+ * @param scene 场景信息
2682
+ * @param itemId 元素Id
2683
+ * @param parentId 父节点Id
2684
+ */
2685
+ declare function setItemJSONParentId(scene: spec.JSONScene, itemId: string, parentId: string): void;
2686
+ /**
2687
+ * @description 清理元素父节点信息
2688
+ * @param scene 场景信息
2689
+ * @param itemId 元素Id
2690
+ */
2691
+ declare function clearItemParentInfo(scene: spec.JSONScene, itemId: string): void;
2692
+ /**
2693
+ * @description 删除元素信息
2694
+ * @param scene 场景信息
2695
+ * @param itemId 元素Id
2696
+ */
2697
+ declare function deleteItemInfoFromScene(scene: spec.JSONScene, itemId: string): spec.JSONScene | undefined;
2698
+ /**
2699
+ * @description 从场景中移除并获取元素的完整 ItemJSONInfo
2700
+ * @param scene 场景信息
2701
+ * @param itemId 元素ID
2702
+ * @returns ItemJSONInfo 或 undefined(如果元素不存在)
2703
+ */
2704
+ declare function removeItemInfoFromScene(scene: spec.JSONScene, itemId: string): ItemJSONInfo | undefined;
2705
+ declare function getTextureUrlById(scene: spec.JSONScene, itemId: string): string | undefined;
2706
+ declare function addCompositionItemByComposition(main: spec.JSONScene, inputChild: spec.JSONScene, compositionItemId: string, parentId?: string): spec.JSONScene;
2707
+ /**
2708
+ * @description 删除预合成数据
2709
+ * @param scene 场景数据
2710
+ * @param itemId 预合成ID
2711
+ * @returns 场景数据
2712
+ */
2713
+ declare function deleteCompositionItemFromScene(scene: spec.JSONScene, itemIds: string[]): spec.JSONScene;
2714
+ /**
2715
+ * @description 删除合成信息
2716
+ * @param scene 场景数据
2717
+ * @param compositionId 合成ID
2718
+ */
2719
+ declare function deleteCompositionFromScene(scene: spec.JSONScene, compositionId: string): void;
2720
+ /**
2721
+ * @description 重置元素ID - 加载时会新建guid,需要保持一致
2722
+ * @param scene 场景数据
2723
+ * @param idMap id名称列表
2724
+ */
2725
+ declare function resetSubCompositionItemId(scene: spec.JSONScene, idMap: Map<string, string>): void;
2726
+ /**
2727
+ * @description 设置场景中元素名称
2728
+ * @param scene 场景数据
2729
+ * @param itemId 元素ID
2730
+ * @param name 名称
2731
+ */
2732
+ declare function setJSONItemName(scene: spec.JSONScene, itemId: string, name: string): void;
2733
+ /**
2734
+ * @description 元素变换选项
2735
+ */
2736
+ type MoveItemTransformOptions = {
2737
+ position?: {
2738
+ x: number;
2739
+ y: number;
2740
+ z: number;
2741
+ };
2742
+ size?: {
2743
+ x: number;
2744
+ y: number;
2745
+ };
2746
+ scale?: {
2747
+ x: number;
2748
+ y: number;
2749
+ z: number;
2750
+ };
2751
+ rotation?: {
2752
+ x: number;
2753
+ y: number;
2754
+ z: number;
2755
+ };
2756
+ };
2757
+ /**
2758
+ * @description 将元素从一个合成移动到另一个合成
2759
+ * @param scene 场景数据
2760
+ * @param itemId 元素ID
2761
+ * @param targetCompositionId 目标合成ID,为null时表示移动到主合成
2762
+ * @param options 可选的位置、大小、缩放、旋转信息
2763
+ * @returns 是否移动成功
2764
+ */
2765
+ declare function moveItemBetweenCompositions(scene: spec.JSONScene, itemId: string, targetCompositionId: string | null, options?: MoveItemTransformOptions): boolean;
2766
+ declare function getCompositionIdByRefCompositionItemId(scene: spec.JSONScene, compositionItemId: string): any;
2767
+ /**
2768
+ * @description 获取预合成元素所指向的合成数据
2769
+ * @param scene 场景数据
2770
+ * @param compositionItemId 预合成元素ID
2771
+ * @returns 对应的合成数据 (CompositionData),如果未找到则返回 undefined
2772
+ */
2773
+ declare function getCompositionDataByRefCompositionItemId(scene: spec.JSONScene, compositionItemId: string): spec.CompositionData | undefined;
2774
+ /**
2775
+ * @description 提取子合成元素及其所有关联资源为独立的 JSONScene
2776
+ * @param scene 主场景数据
2777
+ * @param compositionItemId 预合成元素ID(子合成元素ID)
2778
+ * @returns 独立的子合成场景 JSONScene,如果未找到则返回 undefined
2779
+ */
2780
+ declare function extractSubCompositionToScene(scene: spec.JSONScene, compositionItemId: string): spec.JSONScene | undefined;
2781
+ declare function fixStandardJSON(scene: spec.JSONScene): void;
2782
+
2783
+ declare class PageDataUtils {
2784
+ private sdk;
2785
+ player: Player;
2786
+ container: HTMLElement;
2787
+ emitter: EventEmitter<SDKEvents>;
2788
+ interactionUtils: InteractionUtils;
2789
+ constructor(player: Player, container: HTMLElement, emitter: EventEmitter<SDKEvents>, sdk: SDK);
2790
+ init(): void;
2791
+ getPageData(): PageData | undefined;
2792
+ getCurrentComposition(): Composition | undefined;
2793
+ isItemSelected(id: string): boolean;
2794
+ getItemEditEnable(id: string): boolean;
2795
+ getItemShow(id: string): boolean;
2796
+ addSelectedItems(ids: string[]): void;
2797
+ removeSelectedItems(ids: string[]): void;
2798
+ clearSelectedItems(emitChange?: boolean): void;
2799
+ getSelectedItems(): SDKItem[];
2800
+ addPreSelectedItem(id: string): void;
2801
+ clearPreSelectedItem(): void;
2802
+ getPreSelectedItem(): SDKItem | undefined;
2803
+ addLoadingItems(ids: string[]): void;
2804
+ removeLoadingItems(ids: string[]): void;
2805
+ clearLoadingItems(): void;
2806
+ getLoadingItems(): SDKItem[];
2807
+ getSDKItem(id: string): SDKItem | undefined;
2808
+ getPlayerSizeByParent(parentSize: [number, number], sceneSize: [number, number]): readonly [number, number];
2809
+ loadScene(id: number): Promise<void>;
2810
+ refreshPageTime(number: number): void;
2811
+ pageZoom(shift: number, center?: Vector2, ignoreClamp?: boolean): void;
2812
+ setPageZoom(targetZoom: number, center?: Vector2, ignoreClamp?: boolean): void;
2813
+ refreshInteractionParam(): void;
2814
+ pageMove(shift: Vector2): void;
2815
+ setPageMove(targetTranslation: Vector2): void;
2816
+ /**
2817
+ * @description 设置当前相机视图矩阵
2818
+ * @param matrix 视图矩阵
2819
+ */
2820
+ setCurrenCameraViewportMatrix(matrix: Matrix4): void;
2821
+ rotateItem(id: string, shift: Vector3, ignoreEvent?: boolean): void;
2822
+ moveItem(id: string, shift: Vector3, ignoreEvent?: boolean): void;
2823
+ scaleItem(id: string, shift: Vector3, ignoreEvent?: boolean): void;
2824
+ scaleTextItemWidth(id: string, scalar: number): void;
2825
+ scaleTextItem(id: string, scalar: number): void;
2826
+ getItemTransformById(id: string): {
2827
+ matrix: Matrix4;
2828
+ parentMatrix: Matrix4;
2829
+ };
2830
+ addSDKItemsByItems(result: SDKItem[], playerItems: VFXItem[], id?: string): void;
2831
+ getFilterItemIds(): (string | undefined)[];
2832
+ createSDKItemByPlayerItem(playerItem: VFXItem, parentId?: string): SDKItem;
2833
+ /**
2834
+ * @description 根据 spec.ItemType 创建 SDKItem(内部辅助方法)
2835
+ * @param itemType spec.ItemType
2836
+ * @param baseOptions 基础选项
2837
+ * @param property 属性
2838
+ * @returns SDKItem 实例
2839
+ */
2840
+ private createSDKItemBySpecType;
2841
+ getViewBoxById(id: string): Box2;
2842
+ getItemViewAnchor(id: string): Vector2 | undefined;
2843
+ getChildrenPlayerItems(item?: VFXItem): VFXItem[];
2844
+ getChildrenSceneItemIds(id: string, scene: spec.JSONScene): string[];
2845
+ getViewBoxByPlayerItem(item: VFXItem, childrenItem: VFXItem[]): Box2;
2846
+ getViewportLeftTopPosition(): Vector2;
2847
+ getViewportByViewPoint(point: Vector2): Vector2;
2848
+ /**
2849
+ * @description 设置元素属性(支持单个元素的单/多属性设置)
2850
+ * @param param 设置参数,支持两种场景:
2851
+ * 1. 单个元素单个属性: { itemId, type, propertyName, propertyValue }
2852
+ * 2. 单个元素多个属性: { itemId, type, property }
2853
+ */
2854
+ setItemProperty<T extends SDKItemType>(param: SetItemPropertyParam<T>): Promise<void>;
2855
+ /**
2856
+ * @description 场景 1: 设置单个元素的单个属性
2857
+ */
2858
+ private setSingleItemSingleProperty;
2859
+ /**
2860
+ * @description 场景 2: 设置单个元素的多个属性
2861
+ */
2862
+ private setSingleItemMultipleProperties;
2863
+ /**
2864
+ * @description 更新 PlayerItem 的属性
2865
+ * @param itemId 元素ID
2866
+ * @param propertyName 属性名
2867
+ * @param propertyValue 属性值
2868
+ */
2869
+ private updatePlayerItemProperty;
2870
+ /**
2871
+ * @description 更新 PlayerItem 的基础属性
2872
+ */
2873
+ private updatePlayerItemBaseProperty;
2874
+ /**
2875
+ * @description 更新 PlayerItem 的 Property 属性
2876
+ */
2877
+ private updatePlayerItemPropertyAttribute;
2878
+ /**
2879
+ * @description 更新 JSON Scene 中 Item 的属性
2880
+ * @param itemId 元素ID
2881
+ * @param propertyName 属性名
2882
+ * @param propertyValue 属性值
2883
+ */
2884
+ private updateJSONItemProperty;
2885
+ /**
2886
+ * @description 更新 Scene 中 Item 的基础属性
2887
+ */
2888
+ private updateSceneItemBaseProperty;
2889
+ /**
2890
+ * @description 更新 Scene 中 Item 的 Property 属性
2891
+ */
2892
+ updateSceneItemPropertyAttribute(scene: spec.JSONScene, itemId: string, propertyName: string, propertyValue: any): void;
2893
+ setSpriteSize(id: string, size: [number, number]): void;
2894
+ transformSceneItem(id: string, property: 'position' | 'rotation' | 'scale', shift: [number, number, number]): void;
2895
+ refreshSDKItem(id: string): void;
2896
+ /**
2897
+ * @description 更新已有 SDKItem 的属性(而不是替换整个对象)
2898
+ * @param sdkItem 需要更新的 SDKItem
2899
+ * @param playerItem 对应的 Player VFXItem
2900
+ */
2901
+ updateSDKItemFromPlayerItem(sdkItem: SDKItem, playerItem: VFXItem): void;
2902
+ getPlayerItemById(id?: string): VFXItem | undefined;
2903
+ getPixelSizeByWorldSize(worldSize: spec.vec3, item: VFXItem): spec.vec2;
2904
+ getWorldSizeByPixelSize(pixelSize: spec.vec2): spec.vec2;
2905
+ /**
2906
+ * @private
2907
+ * @description 获取当前激活的场景
2908
+ */
2909
+ private getActiveTargetScene;
2910
+ /**
2911
+ * @private
2912
+ * @description 刷新场景和页面数据
2913
+ */
2914
+ private refreshSceneAndPageData;
2915
+ addSpriteItem(spriteInfo: AsyncSpriteCreateInfo, asyncMode: true, targetScene?: spec.JSONScene): Promise<string>;
2916
+ addSpriteItem(spriteInfo: SpriteCreateInfo, asyncMode: false, targetScene?: spec.JSONScene): Promise<string>;
2917
+ addGroupItem(groupInfo: GroupCreateInfo, targetScene?: spec.JSONScene): string | undefined;
2918
+ addTextItem(textInfo: TextCreateInfo, targetScene?: spec.JSONScene): Promise<string | undefined>;
2919
+ addVideoItem(videoInfo: AsyncVideoCreateInfo, asyncMode: true, targetScene?: spec.JSONScene): Promise<string>;
2920
+ addVideoItem(videoInfo: VideoCreateInfo, asyncMode: false, targetScene?: spec.JSONScene): Promise<string>;
2921
+ /**
2922
+ * @description 添加生成器元素
2923
+ * @param createInfo 生成器创建信息
2924
+ * @param targetScene 目标场景
2925
+ * @returns 元素ID
2926
+ */
2927
+ addGeneratorItem(createInfo: GeneratorCreateInfo, targetScene?: spec.JSONScene): string;
2928
+ /**
2929
+ * @description 设置生成器资源,将生成器转换为对应的元素(SpriteItem 或 VideoItem)
2930
+ * @param id 生成器元素ID
2931
+ * @param resourceUrl 资源地址
2932
+ * @returns 新的元素ID
2933
+ */
2934
+ setGeneratorResource(id: string, resourceUrl: string): Promise<string>;
2935
+ /**
2936
+ * @description 将视频生成器转换为视频元素
2937
+ * @param id 视频生成器元素ID
2938
+ * @param videoUrl 视频资源地址
2939
+ * @returns 新的视频元素ID
2940
+ * @deprecated 使用 setGeneratorResource 替代
2941
+ */
2942
+ convertVideoGeneratorToVideo(id: string, videoUrl: string): Promise<string>;
2943
+ /**
2944
+ * @description 删除元素
2945
+ * @param id 元素id
2946
+ */
2947
+ deleteItem(id: string): void;
2948
+ setItemParent(id: string, parentId: string, targetScene?: spec.JSONScene): void;
2949
+ deleteItemParent(id: string, parentId: string, targetScene?: spec.JSONScene): void;
2950
+ /**
2951
+ * @description 将元素移动到 Frame 中
2952
+ * @param itemIds 要移动的元素ID列表
2953
+ * @param frameId 目标 Frame ID
2954
+ */
2955
+ moveItemsToFrame(itemIds: string[], frameId: string): void;
2956
+ /**
2957
+ * @description 移动单个元素到 Frame(仅 JSON 层,Player 层在 reLoad 后重建)
2958
+ * @private
2959
+ */
2960
+ private moveSingleJSONItemToFrame;
2961
+ /**
2962
+ * @description 移动单个元素到 Frame(保持 parentId)
2963
+ * @param itemId 元素ID
2964
+ * @param frameItem 目标 Frame
2965
+ * @param options 变换选项
2966
+ * @param mainScene 主场景
2967
+ * @param parentId 要保持的父节点ID
2968
+ * @private
2969
+ */
2970
+ private moveSingleJSONItemToFrameWithParent;
2971
+ /**
2972
+ * @description 收集元素及其所有子元素(递归处理嵌套组)
2973
+ * @param itemIds 初始元素ID列表
2974
+ * @returns 包含所有子元素的ID列表
2975
+ * @private
2976
+ */
2977
+ private collectItemsWithChildren;
2978
+ private moveSinglePlayerItemToFrame;
2979
+ /**
2980
+ * @description 将元素从 Frame 中移出到主场景
2981
+ * @param itemIds 要移动的元素ID列表
2982
+ * @param frameId 源 Frame ID(可选,如果不传则从第一个元素的 parentId 推断)
2983
+ */
2984
+ moveItemsOutOfFrame(itemIds: string[], frameId?: string): void;
2985
+ /**
2986
+ * @description 移动单个元素从 Frame 到主场景(仅 JSON 层)
2987
+ * @private
2988
+ */
2989
+ private moveSingleJSONItemOutOfFrame;
2990
+ private moveSinglePlayerItemOutOfFrame;
2991
+ setItemName(id: string, name: string, targetScene?: spec.JSONScene): void;
2992
+ get undoRedo(): UndoRedo;
2993
+ saveUndoRedoOldData(): void;
2994
+ pushUndoRedoData(): void;
2995
+ getItemCreateInfo(id: string, withParent?: boolean): GroupCreateInfo | SpriteCreateInfo | TextCreateInfo | VideoCreateInfo | GeneratorCreateInfo | EffectsCreateInfo | FrameCreateInfo | undefined;
2996
+ getChildrenIds(id: string): string[];
2997
+ createScreenShotSceneByIds(idInfo: string | string[]): any;
2998
+ createSceneByCreateInfos(createInfos: ItemCreateInfo[], sceneSize?: spec.vec2, name?: string, scenePosition?: spec.vec2): spec.JSONScene;
2999
+ /**
3000
+ * @description 更新元素在图片中的顺序(仅在同级元素之间)
3001
+ * @param id 元素ID
3002
+ * @param action 排序操作类型
3003
+ */
3004
+ updateItemOrder(id: string, action: ItemOrderAction): void;
3005
+ private isPluginItem;
3006
+ private refreshItemRenderOrder;
3007
+ /**
3008
+ * @description 根据 composition.items 的顺序重新排列 pageData.items
3009
+ * @param composition 当前场景
3010
+ */
3011
+ private syncPageDataItemsOrder;
3012
+ getViewProperty(id?: number): ViewProperty | undefined;
3013
+ viewportFit(shiftParam?: ViewportFitShiftParam, box?: Box2): void;
3014
+ getItemBoxById(idInfo: string): Box2;
3015
+ getItemBoxById(idInfo: string[]): Box2[];
3016
+ setItemFontFamily(id: string, fontFamilyName: string, url: string): Promise<void>;
3017
+ changeItemPropertyByCreateInfo(itemCreateInfo: ItemCreateInfo | ItemCreateInfo[]): void;
3018
+ getViewBoxByBox(box: Box2): Box2;
3019
+ playVideoItem(id?: string): void;
3020
+ pauseVideoItem(id?: string): void;
3021
+ playEffectsItem(id?: string): void;
3022
+ pauseEffectsItem(id?: string): void;
3023
+ setEffectsResource(id: string, effects: string): void;
3024
+ /**
3025
+ * @description 根据元素创建信息获取包围盒
3026
+ * @param createInfo 元素创建信息
3027
+ * @returns 包围盒
3028
+ */
3029
+ getBoundingBoxByCreateInfo(createInfo: ItemCreateInfo): Box2;
3030
+ /**
3031
+ * @description 根据元素创建信息组获取包围盒
3032
+ * @param createInfos 元素创建信息组
3033
+ * @returns 包围盒
3034
+ */
3035
+ getBoundingBoxByCreateInfos(createInfos: ItemCreateInfo[]): Box2;
3036
+ getVideoItemPlayTime(id: string): number;
3037
+ setVideoItemPlayTime(id: string, time: number): void;
3038
+ getEffectsItemPlayTime(id: string): number | undefined;
3039
+ setEffectsItemPlayTime(id: string, time: number): void;
3040
+ getPixelPositionByViewPosition(viewPosition: Vector2): Vector2;
3041
+ getItemParentScale(id: string): Vector3;
3042
+ getJSONItem(id: string): spec.VFXItemData | undefined;
3043
+ getJSONComponent(id: string): spec.ComponentData | undefined;
3044
+ getTextOriginSize(id: string): {
3045
+ size: spec.vec2;
3046
+ isPublishScene: boolean;
3047
+ };
3048
+ asyncAddItemByCreateInfos(createInfos: ItemCreateInfo[]): Promise<string[]>;
3049
+ addItemByCreateInfos(createInfos: ItemCreateInfo[]): Promise<string[]>;
3050
+ addEffectsItem(createInfo: EffectsCreateInfo, targetScene?: spec.JSONScene): Promise<string | undefined>;
3051
+ /**
3052
+ * @description 添加画板元素
3053
+ * @param createInfo 画板创建信息
3054
+ * @param targetScene 目标场景
3055
+ * @returns 元素ID
3056
+ */
3057
+ addFrameItem(createInfo: FrameCreateInfo, targetScene?: spec.JSONScene): Promise<string>;
3058
+ makeItemAlign(type: AlignType, ids?: string[]): void;
3059
+ makeItemDistribute(type: DistributeType, ids?: string[]): void;
3060
+ setItemLockState(id: string, state: boolean): void;
3061
+ getItemLockState(id: string): boolean;
3062
+ /**
3063
+ * @description 计算元素在新父节点下保持世界绝对 transform 不变时所需的局部 transform
3064
+ * @param itemId 要移动的元素 ID
3065
+ * @param targetParentVFXItem 目标父 VFXItem(移入 Frame 时为 compositionItem,移出 Frame 时为 composition.rootItem)
3066
+ */
3067
+ getItemTransformUnderParent(itemId: string, targetParentVFXItem: VFXItem): MoveItemTransformOptions | undefined;
3068
+ /**
3069
+ * @description 修改画板元素大小
3070
+ * @param id 元素id
3071
+ * @param size 目标大小 [width, height]
3072
+ * @param translation 位置偏移补偿(可选,用于保持拖拽角点固定)
3073
+ */
3074
+ resizeFrameItem(id: string, size: spec.vec2, translation?: Vector3): void;
3075
+ /**
3076
+ * @description 对 FrameItem 执行自动布局(Shelf 算法)
3077
+ * @param frameId Frame 元素 ID
3078
+ */
3079
+ applyFrameAutoLayout(frameId: string): void;
3080
+ /**
3081
+ * @description 将 layout-utils 的 AutoLayoutResult 结果记录到 layoutInfos
3082
+ * @param frameId Frame 元素 ID
3083
+ * @param layoutResult autoLayout 函数返回的结果
3084
+ */
3085
+ private recordLayoutInfosFromAutoLayoutResult;
3086
+ refreshFrameChildren(id: string): void;
3087
+ }
3088
+
3089
+ declare class InteractionUtils {
3090
+ /**
3091
+ * @description 交互平面
3092
+ */
3093
+ plane: Plane;
3094
+ /**
3095
+ * @description 交互射线
3096
+ */
3097
+ ray: Ray;
3098
+ /**
3099
+ * @description 交互状态视图信息
3100
+ */
3101
+ viewportParam: ViewInteractionParam;
3102
+ /**
3103
+ * @description 交互状态相机信息
3104
+ */
3105
+ cameraParam: CameraInteractionParam;
3106
+ pageDataUtils: PageDataUtils;
3107
+ constructor(utils: PageDataUtils);
3108
+ refreshViewParam(): void;
3109
+ refreshCameraParam(): void;
3110
+ refrehCameraParamByCameraInfo(camera: any): void;
3111
+ initInteractionPlane(position?: Vector3, rotation?: Euler): void;
3112
+ /**
3113
+ * @description 根据视图空间大小获取空间大小
3114
+ * @param viewSize 视图空间大小
3115
+ * @param isWorld 是否依赖于世界坐标系 - 世界坐标系下,以当前相机锁定平面为基准进行运算;本地坐标系下,以元素坐标系进行运算[用于决定交互平面]
3116
+ * @param targetItem 目标元素
3117
+ */
3118
+ getWorldSizeByViewSize(viewSize: Vector2, isWorld?: boolean, itemId?: string): Vector3;
3119
+ getViewSizeByPixelSize(pixelSize: Vector2): Vector2;
3120
+ /**
3121
+ * @description 对空间坐标进行投影
3122
+ * @param point 空间坐标
3123
+ * @param isGestureHandlerView 是否投影到辅助视图下 - 辅助试图与实际视图大小可能会有区别
3124
+ */
3125
+ projectPoint(point: Vector3): Vector2;
3126
+ /**
3127
+ * @description 通过屏幕坐标获取世界坐标
3128
+ * @param point 屏幕坐标
3129
+ * @returns 世界坐标
3130
+ */
3131
+ getWorldPositionByViewPoint(point: Vector2): Vector3 | undefined;
3132
+ getNDCPositionByScreenPosition(point: Vector2): Vector2;
3133
+ getNDCSizeByPixelSize(pixelSize: Vector2): Vector2;
3134
+ getViewPositionWWithOutTransform(point: Vector2): Vector2;
3135
+ getViewPositionByPixelPoint(point: Vector2): Vector2;
3136
+ getPixelPositionByViewPoint(point: Vector2): Vector2;
3137
+ getPixelSizeByWorldSize(worldSize: Vector3): Vector2;
3138
+ getPixelSizeByNDCSize(ndcSize: Vector2): Vector2;
3139
+ getPixelSizeByViewSize(viewSize: Vector2): Vector2;
3140
+ }
3141
+
3142
+ /**
3143
+ * @description 布局元素信息
3144
+ */
3145
+ type LayoutItem = {
3146
+ /**
3147
+ * @description 元素ID
3148
+ */
3149
+ id: string;
3150
+ /**
3151
+ * @description 元素包围盒(用于获取宽高)
3152
+ */
3153
+ box: Box2;
3154
+ /**
3155
+ * @description 所在行号(可选)
3156
+ */
3157
+ row?: number;
3158
+ /**
3159
+ * @description 所在列号(可选)
3160
+ */
3161
+ column?: number;
3162
+ };
3163
+ /**
3164
+ * @description 布局结果项
3165
+ */
3166
+ type LayoutResultItem = {
3167
+ /**
3168
+ * @description 元素ID
3169
+ */
3170
+ id: string;
3171
+ /**
3172
+ * @description 目标位置(相对画布左上角的像素坐标)
3173
+ */
3174
+ position: [number, number];
3175
+ /**
3176
+ * @description 实际分配的行号
3177
+ */
3178
+ row: number;
3179
+ /**
3180
+ * @description 实际分配的列号
3181
+ */
3182
+ column: number;
3183
+ };
3184
+ /**
3185
+ * @description 自动排布配置
3186
+ */
3187
+ type AutoLayoutOptions = {
3188
+ /**
3189
+ * @description 边距(默认20)
3190
+ */
3191
+ padding?: number;
3192
+ /**
3193
+ * @description 元素间隔(默认5)
3194
+ */
3195
+ gap?: number;
3196
+ /**
3197
+ * @description 自动布局高级配置(可选)
3198
+ */
3199
+ config?: AutoLayoutConfig;
3200
+ };
3201
+ /**
3202
+ * @description 自动排布结果
3203
+ */
3204
+ type AutoLayoutResult = {
3205
+ /**
3206
+ * @description 各元素的位置信息
3207
+ */
3208
+ items: LayoutResultItem[];
3209
+ /**
3210
+ * @description 排布后的整体尺寸 [width, height]
3211
+ */
3212
+ size: [number, number];
3213
+ };
3214
+ /**
3215
+ * @description 自动排布函数
3216
+ * 根据元素信息中的行列数参数进行排布:
3217
+ * - 如果元素有 row/column,则按指定行列排布
3218
+ * - 如果元素没有 row/column,则使用 Shelf 算法自动生成行列数,再排布
3219
+ *
3220
+ * @param canvasBox 画布范围(Box2),min为左上角,max为右下角
3221
+ * @param items 元素信息列表(包含 ID、Box2、可选的 row/column)
3222
+ * @param options 可选配置(padding, gap)
3223
+ * @returns 各元素的位置信息和整体尺寸
3224
+ */
3225
+ declare function autoLayout(items: LayoutItem[], options?: AutoLayoutOptions): AutoLayoutResult;
3226
+ /**
3227
+ * @description 计算元素到目标位置的位移
3228
+ * @param currentPosition 当前位置 [x, y]
3229
+ * @param targetPosition 目标位置 [x, y]
3230
+ * @returns 位移向量 [dx, dy]
3231
+ */
3232
+ declare function calculateDisplacement(currentPosition: [number, number], targetPosition: [number, number]): [number, number];
3233
+ /**
3234
+ * @description 为 autoLayout 结果计算位移信息
3235
+ * @param items 元素列表(包含当前位置)
3236
+ * @param layoutResult autoLayout 的返回结果
3237
+ * @returns 每个元素的位移信息
3238
+ */
3239
+ declare function calculateLayoutDisplacements(items: {
3240
+ id: string;
3241
+ currentPosition: [number, number];
3242
+ }[], layoutResult: AutoLayoutResult): {
3243
+ id: string;
3244
+ displacement: [number, number];
3245
+ targetPosition: [number, number];
3246
+ }[];
3247
+
3248
+ declare class DefaultVFXItems {
3249
+ static createEmpty(composition: Composition, parent?: null, name?: string): VFXItem;
3250
+ static createSprite(composition: Composition, parent?: null, name?: string): VFXItem;
3251
+ static createText(composition: Composition, parent?: null, name?: string): VFXItem;
3252
+ static createVideo(composition: Composition, parent?: null, name?: string): VFXItem;
3253
+ static createEffects(composition: Composition, effects: string | spec.JSONScene, parent?: null, urlname?: string): Promise<VFXItem>;
3254
+ }
3255
+ declare class VFXItemFactory {
3256
+ static createVFXItem(composition: Composition, parent?: null, name?: string, ...types: Constructor<Component>[]): VFXItem;
3257
+ }
3258
+
2300
3259
  type SDKMode = 'editor' | 'template';
2301
3260
  /**
2302
3261
  * @description SDK功能配置
@@ -2834,6 +3793,18 @@ type TextGizmoConfig = {
2834
3793
  * @description 触发边缩放交互的距离
2835
3794
  */
2836
3795
  widthScaleInteractionDistance: number;
3796
+ /**
3797
+ * @description 画板线框颜色
3798
+ */
3799
+ wireframeColor: number;
3800
+ /**
3801
+ * @description 画板线框透明度
3802
+ */
3803
+ wireframeAlpha: number;
3804
+ /**
3805
+ * @description 画板线框线宽
3806
+ */
3807
+ wireframeWidth: number;
2837
3808
  };
2838
3809
  /**
2839
3810
  * @description 蒙版参数
@@ -3082,9 +4053,6 @@ type ItemCreateType = 'none' | 'text' | 'video-generator' | 'sprite-generator' |
3082
4053
  type GizmoType = 'null' | 'selector' | 'transform' | 'control' | 'adsorption' | 'preference' | 'picture-cut' | 'text' | 'mask' | 'loading' | 'picture-expand' | 'sprite-text-edit' | 'video-play' | 'item-create';
3083
4054
  type GestureHandlerInteractType = 'select' | 'hand';
3084
4055
 
3085
- type AlignType = 'left' | 'right' | 'horizontal-center' | 'top' | 'bottom' | 'vertical-center';
3086
- type DistributeType = 'vertical-spacing' | 'horizontal-spacing';
3087
-
3088
4056
  declare module '@pixi/graphics' {
3089
4057
  interface Graphics {
3090
4058
  fillBox(box: Box2): void;
@@ -3190,10 +4158,12 @@ declare class SDK {
3190
4158
  private disposables;
3191
4159
  private _isSwitchScene;
3192
4160
  private _undoRedo;
4161
+ private _backgroundManager;
3193
4162
  player: Player;
3194
4163
  _container: HTMLElement;
3195
4164
  private _playerContainer;
3196
4165
  constructor(container: HTMLElement, mode?: SDKMode);
4166
+ get backgroundManager(): BackgroundManager;
3197
4167
  get container(): HTMLElement;
3198
4168
  get pageData(): PageData | undefined;
3199
4169
  private get initExporterEnabled();
@@ -3654,4 +4624,4 @@ declare class SDK {
3654
4624
  applyFrameAutoLayout(frameId: string): void;
3655
4625
  }
3656
4626
 
3657
- export { type ActiveData, BaseItem, type BaseItemProperty, type BaseItemPropertyKey, type BaseItemPropertyValueMap, Box2, type CreateOperation, type DeleteOperation, type EffectsCreateInfo, EffectsItem, type EffectsItemOptions, type FrameCreateInfo, FrameItem, type FrameItemOptions, type FrameItemProperty, FrameLayoutMode, type GeneratorCreateInfo, GeneratorItem, type GeneratorItemOptions, type GeneratorItemProperty, type GizmoType, type GroupCreateInfo, GroupItem, type GroupItemOptions, type ItemCreateInfo, ItemOrderAction, type ItemPropertyMap, type Operation, type PageData, type PageProperty, SDK, type SDKEvents, type SDKInputParam, type SDKItem, type SDKItemOptions, SDKItemType, type SDKOptions, type SetItemPropertyParam, type SetSingleItemMultiplePropertiesParam, type SetSingleItemSinglePropertyParam, type SpriteCreateInfo, SpriteItem, type SpriteItemOptions, type SpriteItemProperty, type TextCreateInfo, TextItem, type TextItemOptions, type TextItemProperty, type UpdateOperation, Vector2, type VideoCreateInfo, VideoItem, type VideoItemOptions, type VideoItemProperty, type ViewParam, type ViewProperty, createSDKItem, isBaseItem, isEffectsItem, isFrameItem, isGeneratorItem, isGroupItem, isSpriteItem, isTextItem, isVideoItem };
4627
+ export { type ActiveData, type AlignType, type AutoLayoutOptions, type AutoLayoutResult, type BackgroundGridConfig, BackgroundManager, type BackgroundPreset, BaseItem, type BaseItemProperty, type BaseItemPropertyKey, type BaseItemPropertyValueMap, Box2, type CameraInteractionParam, type CreateOperation, DefaultVFXItems, type DeleteOperation, type DistributeType, type EffectsCreateInfo, EffectsItem, type EffectsItemOptions, type FrameCreateInfo, FrameItem, type FrameItemOptions, type FrameItemProperty, FrameLayoutMode, type GeneratorCreateInfo, GeneratorItem, type GeneratorItemOptions, type GeneratorItemProperty, type GizmoType, type GroupCreateInfo, GroupItem, type GroupItemOptions, InteractionUtils, type ItemCreateInfo, type ItemJSONInfo, ItemOrderAction, type ItemPropertyMap, type LayoutItem, type LayoutResultItem, type MoveItemTransformOptions, type Operation, type PageData, PageDataUtils, type PageProperty, SDK, type SDKEvents, type SDKInputParam, type SDKItem, type SDKItemOptions, SDKItemType, type SDKOptions, SafeConstraint, type SetItemPropertyParam, type SetSingleItemMultiplePropertiesParam, type SetSingleItemSinglePropertyParam, type SpriteCreateInfo, SpriteItem, type SpriteItemOptions, type SpriteItemProperty, type TextCreateInfo, TextItem, type TextItemOptions, type TextItemProperty, type UpdateOperation, VFXItemFactory, Vector2, type VideoCreateInfo, VideoItem, type VideoItemOptions, type VideoItemProperty, type ViewInteractionParam, type ViewParam, type ViewProperty, addCompositionItemByComposition, addItemInfoToScene, arrAdd, assertExist, asserts, autoLayout, calculateDisplacement, calculateLayoutDisplacements, clearItemParentInfo, createCompositionItemJSON, createFrameCompositionScene, createNullItemJSON, createSDKItem, createSpriteItemJSON, createTextItemJSON, createVideoGeneratorItemJSON, createVideoItemJSON, deepClone, deepEquals, deleteCompositionFromScene, deleteCompositionItemFromScene, deleteItemInfoFromScene, downloadBlob, extractSubCompositionToScene, fixStandardJSON, getBasicScene, getColorByNormalizeColor, getCompositionDataByRefCompositionItemId, getCompositionIdByRefCompositionItemId, getNormalizeColorByColor, getTextureUrlById, getTransformRatioByViewAndCamera, getUniqueName, isBaseItem, isEffectsItem, isEqual, isFrameItem, isGeneratorItem, isGroupItem, isObj, isSpriteItem, isTextItem, isVideoItem, loadScriptAsync, logger, moveItemBetweenCompositions, removeItemInfoFromScene, resetSubCompositionItemId, setItemJSONParentId, setJSONItemName };