import { Vector3 } from 'three';
import { DiffResult, VisualDiffMode } from './modules/Differ';
import { BatchObject } from './modules/batching/BatchObject';
import { FilteringState } from './modules/filtering/FilteringManager';
import { PropertyInfo } from './modules/filtering/PropertyManager';
import { Query, QueryArgsResultMap, QueryResult } from './modules/queries/Query';
import { DataTree } from './modules/tree/DataTree';
import { WorldTree } from './modules/tree/WorldTree';
import { Utils } from './modules/Utils';
import { World } from './modules/World';
import { MeasurementOptions } from './modules/measurements/Measurements';
export interface ViewerParams {
    showStats: boolean;
    environmentSrc: Asset | string;
    verbose: boolean;
    keepGeometryData: boolean;
}
export declare enum AssetType {
    TEXTURE_8BPP = "png",
    TEXTURE_HDR = "hdr",
    TEXTURE_EXR = "exr",
    FONT_JSON = "font-json"
}
export interface Asset {
    src: string;
    type: AssetType;
}
/**
 * The default HDRI the viewer uses is actually a true HDR image (.exr),
 * specified by the explicit TEXTURE_EXR
 *
 * We do this because bundling an actual .exr or .hdr image format would require
 * anybody consuming the viewer to make adjustments to their build config, to enable
 * its import.
 *
 * Three.js doesn't mind the extension of the asset you load, so an .exr hidden behind
 * a .png will work just fine.
 */
export declare const DefaultViewerParams: ViewerParams;
export declare enum ViewerEvent {
    ObjectClicked = "object-clicked",
    ObjectDoubleClicked = "object-doubleclicked",
    DownloadComplete = "download-complete",
    LoadComplete = "load-complete",
    LoadProgress = "load-progress",
    UnloadComplete = "unload-complete",
    LoadCancelled = "load-cancelled",
    UnloadAllComplete = "unload-all-complete",
    Busy = "busy",
    SectionBoxChanged = "section-box-changed",
    SectionBoxUpdated = "section-box-updated",
    FilteringStateSet = "filtering-state-set",
    LightConfigUpdated = "light-config-updated"
}
export type SelectionEvent = {
    multiple: boolean;
    event?: PointerEvent;
    hits: Array<{
        guid?: string;
        object: Record<string, unknown> & {
            id: string;
        };
        point: Vector3;
    }>;
};
export interface LightConfiguration {
    enabled?: boolean;
    castShadow?: boolean;
    intensity?: number;
    color?: number;
    indirectLightIntensity?: number;
    shadowcatcher?: boolean;
}
export interface SunLightConfiguration extends LightConfiguration {
    elevation?: number;
    azimuth?: number;
    radius?: number;
}
export declare const DefaultLightConfiguration: SunLightConfiguration;
export type CanonicalView = 'front' | 'back' | 'up' | 'top' | 'down' | 'bottom' | 'right' | 'left' | '3d' | '3D';
export type SpeckleView = {
    name: string;
    id: string;
    view: Record<string, unknown>;
};
export type InlineView = {
    position: Vector3;
    target: Vector3;
};
export type PolarView = {
    azimuth: number;
    polar: number;
    radius?: number;
    origin?: Vector3;
};
export interface IViewer {
    init(): Promise<void>;
    resize(): void;
    on(eventType: ViewerEvent, handler: (arg: any) => void): any;
    requestRender(): void;
    setSectionBox(box?: {
        min: {
            x: number;
            y: number;
            z: number;
        };
        max: {
            x: number;
            y: number;
            z: number;
        };
    }, offset?: number): any;
    setSectionBoxFromObjects(objectIds: string[], offset?: number): any;
    getCurrentSectionBox(): {
        min: {
            x: number;
            y: number;
            z: number;
        };
        max: {
            x: number;
            y: number;
            z: number;
        };
    } | null;
    toggleSectionBox(): void;
    sectionBoxOff(): void;
    sectionBoxOn(): void;
    zoom(objectIds?: string[], fit?: number, transition?: boolean): void;
    toggleCameraProjection(): void;
    setLightConfiguration(config: LightConfiguration): void;
    getViews(): SpeckleView[];
    setView(view: CanonicalView | SpeckleView | InlineView | PolarView, transition?: boolean): any;
    loadObject(url: string, token?: string, enableCaching?: boolean, zoomToObject?: boolean): Promise<void>;
    loadObjectAsync(url: string, token?: string, enableCaching?: boolean, priority?: number, zoomToObject?: boolean): Promise<void>;
    cancelLoad(url: string, unload?: boolean): Promise<void>;
    unloadObject(url: string): Promise<void>;
    unloadAll(): Promise<void>;
    /** Diffing */
    diff(urlA: string, urlB: string, mode: VisualDiffMode): Promise<DiffResult>;
    undiff(): void;
    setDiffTime(diffResult: DiffResult, time: number): void;
    setVisualDiffMode(diffResult: DiffResult, mode: VisualDiffMode): any;
    screenshot(): Promise<string>;
    /** Old Filtering members. Deprecated */
    applyFilter(filter: unknown): Promise<void>;
    /** New Filtering members */
    getObjectProperties(resourceURL?: string, bypassCache?: boolean): PropertyInfo[];
    showObjects(objectIds: string[], stateKey?: string, includeDescendants?: any): Promise<FilteringState>;
    hideObjects(objectIds: string[], stateKey?: string, includeDescendants?: any, ghost?: boolean): Promise<FilteringState>;
    isolateObjects(objectIds: string[], stateKey?: string, includeDescendants?: any, ghost?: boolean): Promise<FilteringState>;
    unIsolateObjects(objectIds: string[], stateKey?: string, includeDescendants?: any): Promise<FilteringState>;
    selectObjects(objectIds: string[]): Promise<FilteringState>;
    resetSelection(): Promise<FilteringState>;
    highlightObjects(objectIds: string[], ghost?: boolean): Promise<FilteringState>;
    resetHighlight(): Promise<FilteringState>;
    setColorFilter(prop: PropertyInfo, ghost?: boolean): Promise<FilteringState>;
    setUserObjectColors(groups: [{
        objectIds: string[];
        color: string;
    }]): Promise<FilteringState>;
    removeColorFilter(): Promise<FilteringState>;
    resetFilters(): Promise<FilteringState>;
    /** Data ops */
    getDataTree(): DataTree;
    getWorldTree(): WorldTree;
    query<T extends Query>(query: T): QueryArgsResultMap[T['operation']];
    queryAsync(query: Query): Promise<QueryResult>;
    get Utils(): Utils;
    get World(): World;
    getObjects(id: string): BatchObject[];
    explode(time: number): any;
    enableMeasurements(value: boolean): any;
    setMeasurementOptions(options: MeasurementOptions): any;
    removeMeasurement(): any;
    dispose(): void;
}
