import { Color, ConeGeometry, Object3D, SphereGeometry, type Camera, type Scene } from "three";
import { type CameraUtilsApi } from "../../Camera/useCameraUtils";
import type { ViewerStoreApi } from "../../store/ViewerStore";
import type { ViewerControlsRef, ViewerModelRef } from "../../types";
import { DimensionLine, type DimensionUnit } from "./DimentionLine";
type DimensionsContext = {
    camera: Camera;
    cameraUtils: CameraUtilsApi;
    controlRef: ViewerControlsRef;
    domElement: HTMLCanvasElement;
    getExtraSnapObjects?: () => Object3D[];
    modelRef: ViewerModelRef;
    scene: Scene;
    viewerStore: ViewerStoreApi;
    viewportHeight: number;
};
export type ViewerDimensionsApi = {
    cancelDrawing: () => void;
    changeAxes: () => void;
    delete: () => void;
    deleteAll: () => void;
    getActive: () => boolean;
    getDimensions: () => DimensionLine[];
    getSnapDistance: () => number;
    getUnit: () => DimensionUnit;
    setActive: (active: boolean) => void;
    setColor: (color: string | Color) => void;
    setEndpointScaleFactor: (factor: number) => void;
    setSnapDistance: (distance: number) => void;
    setUnit: (unit: DimensionUnit) => void;
    setWidth: (width: number) => void;
    toggle: () => void;
};
export declare class DimensionsUtils {
    private active;
    private axis;
    private readonly boundingMaterial;
    private context;
    private currentDimension;
    private dimensions;
    private readonly endpointGeometry;
    private readonly endpointMaterial;
    private endpointScale;
    private readonly lineMaterial;
    private measureInProcess;
    private moveState;
    private readonly previewMarker;
    private readonly root;
    private snapDistance;
    private startPoint;
    private unit;
    constructor(context: DimensionsContext);
    setContext(context: DimensionsContext): void;
    getActive(): boolean;
    getDimensions(): DimensionLine[];
    getSnapDistance(): number;
    getUnit(): DimensionUnit;
    setActive(active: boolean): void;
    toggle(): void;
    setColor(color: string | Color): void;
    setEndpointScaleFactor(factor: number): void;
    setSnapDistance(distance: number): void;
    setUnit(unit: DimensionUnit): void;
    setWidth(width: number): void;
    cancelDrawing(): void;
    delete(): void;
    deleteAll(): void;
    changeAxes(): void;
    updateFrame(): void;
    syncWithModel(): void;
    dispose(): void;
    private addEventListeners;
    private removeEventListeners;
    private drawStart;
    private drawPreview;
    private drawEnd;
    private createDimension;
    private getSnapObjects;
    private getModelHit;
    private getBoundingBoxes;
    private getClosestVertex;
    private getPreviewEndPoint;
    private getNextAxis;
    private getIsMoving;
    private rescalePreviewMarker;
    private setSelectionInteractionDisabled;
    private onClick;
    private onPointerMove;
    private onPointerDown;
    private onPointerUp;
    private onControlsChange;
    private onKeyDown;
    static createEndpointGeometry(height?: number, radius?: number): ConeGeometry;
    static createPreviewGeometry(): SphereGeometry;
}
export declare function useDimensionsUtils(modelRef: ViewerModelRef, controlRef: ViewerControlsRef, cameraUtils: CameraUtilsApi, getExtraSnapObjects?: () => Object3D[]): ViewerDimensionsApi & {
    syncWithModel: () => void;
};
export {};
