import { type FrameContext } from "./EngineLoop.js";
import { type EngineConfig, type ResolvedEngineConfig } from "./EngineConfig.js";
import { EventBus } from "./EventBus.js";
import { Diagnostics } from "./Diagnostics.js";
import { Logger } from "./Logger.js";
import { ResourceScope } from "./ResourceScope.js";
import { Scheduler } from "./Scheduler.js";
import { TaskQueue } from "./TaskQueue.js";
export type EngineState = "created" | "initializing" | "initialized" | "running" | "stopped" | "disposed" | "failed";
export interface EngineEvents {
    stateChanged: {
        readonly previous: EngineState;
        readonly current: EngineState;
    };
    frame: FrameContext;
    error: unknown;
}
export interface EnginePlugin {
    readonly id: string;
    init?(engine: Engine): void | Promise<void>;
    dispose?(): void | Promise<void>;
}
export declare class Engine {
    readonly config: ResolvedEngineConfig;
    readonly events: EventBus<EngineEvents>;
    readonly diagnostics: Diagnostics;
    readonly logger: Logger;
    readonly scheduler: Scheduler;
    readonly tasks: TaskQueue;
    readonly resources: ResourceScope;
    private readonly plugins;
    private readonly pluginDisposables;
    private readonly loop;
    private stateValue;
    constructor(config?: EngineConfig);
    get state(): EngineState;
    use(plugin: EnginePlugin): this;
    init(): Promise<void>;
    start(): void;
    stop(): void;
    step(delta: number): Promise<FrameContext>;
    dispose(): Promise<void>;
    private runFrame;
    private setState;
}
//# sourceMappingURL=Engine.d.ts.map