import type { CellMetrics } from "./measure"; export type RendererBackend = "webgpu" | "webgl2" | "canvas2d"; /** Relative luminance of an 0-255 RGB triple, in the same (sRGB-encoded) * space the glyph shader compares foreground colours in. */ export declare function rgbLuma(rgb: [number, number, number]): number; export interface GlRenderer { supported: boolean; backend?: RendererBackend; maxDimension: number; /** Coverage gamma for glyph antialiasing. 1 leaves coverage untouched; * above 1 thins light-on-dark text. See GLYPH_FS. */ setTextGamma(gamma: number): void; resize(width: number, height: number): void; render(bgVerts: Float32Array, glyphVerts: Float32Array, atlasCanvas: HTMLCanvasElement | undefined, atlasVersion: number, cursorVisible: boolean, cursorCol: number, cursorRow: number, cursorStyle: number, cursorBlinkOn: boolean, cell: CellMetrics, bgColor: [number, number, number], focused?: boolean): void; dispose(): void; } /** * Software fallback when WebGL2 is not available (e.g. headless compositor * without GPU). Reads the same vertex buffers produced by the WASM terminal * and paints them with Canvas 2D. */ export declare function createCanvas2dRenderer(canvas: HTMLCanvasElement): GlRenderer; export declare function createGlRenderer(canvas: HTMLCanvasElement, /** Called once if the drawing context is lost. The renderer is unusable from * that point on — see the `webglcontextlost` handler below. */ onLost?: () => void): GlRenderer; //# sourceMappingURL=gl-renderer.d.ts.map