import { THREE, BaseViewer, Plugin, PluginConfig } from "@x-viewer/core"; /** * Ground grid plugin. */ export interface GroundGridPluginConfig extends Partial { /** If ground grid is visible. It is visible by default. */ visible?: boolean; /** World-space Y height of the grid plane. Default 0. */ height?: number; } /** * Infinite anti-aliased ground grid rendered on a horizontal plane at configurable world Y. * Uses a shader-based approach (Fyrestar/THREE.InfiniteGridHelper technique) * so the grid always follows the camera and fades with distance. * Can be used by Viewer3d. */ export declare class GroundGridPlugin extends Plugin { static readonly DEFAULT_ID = "GroundGridPlugin"; protected readonly NAME = "GROUND_GRID"; protected cfg: GroundGridPluginConfig; protected gridMesh?: THREE.Mesh; constructor(viewer: BaseViewer, cfg?: GroundGridPluginConfig); protected init(): void; /** World-space Y of the grid plane. */ getHeight(): number; setHeight(height: number): void; protected applyGridHeight(): void; setVisible(visible: boolean): void; isVisible(): boolean; protected onModelLoaded: () => void; /** * Creates an infinite grid mesh using a shader-based approach. * A unit PlaneGeometry is scaled in the vertex shader to fill the visible * area, always centred on the camera, so no finite boundary is ever visible. */ protected createInfiniteGrid(): THREE.Mesh; destroy(): void; }