import { EventDispatcher, Loader, type Object3D } from 'three/webgpu'; import { type AnimationModeType, type Tween, type Viewer } from 'u-space'; export declare class AnimationsLoader extends Loader { constructor(); loadAsync(): Promise; } export interface IKeyframe { id: string; uuid: string; x: number; y: number; z: number; scaleX: number; scaleY: number; scaleZ: number; rotationX: number; rotationY: number; rotationZ: number; easing: AnimationModeType; mode: string; delay: number; duration: number; repeat: number; yoyo: boolean; } /** * 动画 */ export interface IAnimations { id: string; sid: string; modelId: string; name: string; keyframes: IKeyframe[]; } export declare class AnimationsParser extends EventDispatcher { viewer: Viewer; target: Object3D; tweenSet: Set; _initialTransformSymbol: symbol; constructor(viewer: Viewer, target: Object3D); initTransform(defaultTransform?: TTweenSource): TTweenSource; getInitialTransform(): TTweenSource | undefined; play(frames: IKeyframe[]): Promise; stop(): void; reset(): void; dispose(): void; } export type TTweenSource = Pick; export type TTweenType = Tween; export type TAnimationsPlayerEventMap = { update: { source: TTweenSource; tween: TTweenType; }; start: { tween: TTweenType; }; };