import { Object3D, WebGLRendererParameters } from "three";
import { WebglModel } from "./model";
import { WebglScene, RenderInterceptor, ModelTheme } from "./scene";
import { RenderOptions, WebglRenderer } from "./renderer";
import { CameraOptions, WebglCamera } from "./camera";
import Loader from "./loader";
import EventEmitter from "../common/event-emitter";
import { Component, Options } from "../interface/component";
import { ComponentType } from "../common/constant";
import { DecryptOptions } from "./decrypt";
import { PluginCreator } from "../interface/meta";
export declare enum SceneCacheType {
    enter = "enter",
    leave = "leave"
}
export interface WebglConfig {
    decoderPath: string;
    decoderType: "js" | "wasm";
    renderer: RenderOptions;
    modelPath: string;
    cache: {
        enable: boolean;
        expires: number;
    };
    scene: {
        cache: ((url: string) => boolean) | boolean;
        expires: number;
        cacheType: SceneCacheType;
    };
    encrypt: DecryptOptions;
    performance: {
        autoMerge: boolean;
        silent: boolean;
        mergeTypes: ComponentType[];
        mergedTypes: ComponentType[];
    };
    themes: {
        camera: CameraOptions;
        render: WebGLRendererParameters;
        orbitControls: Record<string, any>;
        hover: {
            color: string;
            opacity: number;
        };
        selected: {
            color: string;
            opacity: number;
        };
        model: ModelTheme;
    };
    plugins: PluginCreator<unknown, WebglCreator>[];
    interceptor: RenderInterceptor;
}
export type WebglCreator = {
    readonly container: HTMLElement | undefined;
    renderer: WebglRenderer;
    scene: WebglScene;
    camera: WebglCamera;
    loader: Loader;
    clear: () => Promise<void>;
    render(url: string, mapping?: boolean): Promise<Component<WebglModel>>;
    compile(url: string, mapping?: boolean, force?: boolean): Promise<Object3D>;
    amount(url: string | HTMLElement): void;
    dispose(): void;
    loadOption: (url: string) => Promise<Options>;
    createComponent(options: string | Partial<Options>, url?: string): Promise<Component<WebglModel>>;
    readonly component: Component<WebglModel> | undefined;
    readonly model: WebglModel | undefined;
    readonly global: Component<WebglModel> | undefined;
} & EventEmitter;
export declare function createWebglDefaultConfig(): WebglConfig;
export declare function webglCreator(config: WebglConfig): WebglCreator;
