import type { ReadonlyVec } from "@thi.ng/vectors";
import type { WeblGLCanvasOpts } from "./api/canvas.js";
import type { WebGLExtensionMap } from "./api/ext.js";
export declare const glCanvas: (opts?: Partial<WeblGLCanvasOpts>) => {
    canvas: HTMLCanvasElement;
    gl: WebGLRenderingContext;
    ext: Pick<WebGLExtensionMap, keyof WebGLExtensionMap>;
    resize: (width: number, height: number) => void;
};
export declare const getExtensions: <K extends keyof WebGLExtensionMap>(gl: WebGLRenderingContext, ids: K[], required?: boolean) => Pick<WebGLExtensionMap, K>;
/**
 * Sets clear color to given RGB(A) `color` and clears viewport's
 * `COLOR_BUFFER_BIT` and (by default) also `DEPTH_BUFFER_BIT`.
 *
 * @remarks
 * If the given color vector only contains RGB values, alpha will default to
 * 1.0.
 *
 * @param gl
 * @param color
 * @param depth
 */
export declare const clearCanvas: (gl: WebGLRenderingContext, [r, g, b, a]: ReadonlyVec, depth?: boolean) => void;
/**
 * Resets viewport to full drawing buffer size.
 *
 * @param gl
 */
export declare const defaultViewport: (gl: WebGLRenderingContext) => void;
//# sourceMappingURL=canvas.d.ts.map