import type { Camera, Vector2, WebGLRenderer } from "three";
import { Color, type Scene, WebGLRenderTarget } from "three";
import { Pass } from "three/examples/jsm/postprocessing/Pass";
/**
 * Selection Outline Pass
 *
 * GPU-based outline effect for selected elements.
 * Renders the scene with a filter shader that outputs white only for
 * fragments matching the selection color — zero CPU vertex work.
 *
 * Cost: 1-2 extra draw calls (mask render with overrideMaterial) + 1 fullscreen Sobel pass
 *
 * Process:
 * 1. Render entire scene with overrideMaterial that filters by SELECT_COLOR
 * 2. Sobel edge detection on mask
 * 3. Composite colored edges over scene
 */
export interface SelectionOutlineOptions {
    /** Outline color (default: accent color) */
    outlineColor: Color;
    /** Outline opacity 0-1 (default: 1.0) */
    outlineOpacity: number;
    /** Outline thickness in pixels (default: 2.0) */
    outlineThickness: number;
    /** Show outline for occluded parts (default: true) */
    showOccluded: boolean;
    /** Occluded outline opacity multiplier (default: 0.5) */
    occludedOpacity: number;
}
export declare class SelectionOutlinePass extends Pass {
    private scene;
    camera: Camera;
    private resolution;
    private options;
    private maskRenderTarget;
    private maskDepthRenderTarget;
    private selectionFilterMaterial;
    private selectionFilterMaterialDepth;
    private outlineMaterial;
    private copyMaterial;
    private fsQuad;
    private hasSelection;
    /**
     * FAST TOGGLE:
     * - `bypass = false`: Full outline rendering (normal mode)
     * - `bypass = true`: Pass runs but just copies input to output (very fast, no mask render)
     */
    bypass: boolean;
    constructor(scene: Scene, camera: Camera, resolution: Vector2, options?: Partial<SelectionOutlineOptions>);
    /**
     * Notify the pass whether there is an active selection.
     * No data transfer needed — the GPU reads selection state from vertex colors.
     */
    setHasSelection(hasSelection: boolean): void;
    /**
     * Legacy method — kept for backward compatibility.
     * With the GPU-based approach, this just toggles hasSelection.
     */
    updateSelectionGeometry(positions: Float32Array | null): void;
    /**
     * Get whether there's an active selection
     */
    get hasActiveSelection(): boolean;
    /**
     * Update outline options
     */
    setOptions(options: Partial<SelectionOutlineOptions>): void;
    render(renderer: WebGLRenderer, writeBuffer: WebGLRenderTarget, readBuffer: WebGLRenderTarget, _deltaTime?: number, _maskActive?: boolean): void;
    private _renderCopyPass;
    setSize(width: number, height: number): void;
    dispose(): void;
}
