import { ComplexPrimitiveShader } from './shader/complex.js'; import { FastShader } from './shader/fast.js'; import { NormalShader } from './shader/normal.js'; import { PrimitiveShader } from './shader/primitive.js'; import { StripShader } from './shader/strip.js'; import type { IdentifiedWebGLRenderingContext } from './util.js'; /** The structural subset of a shader that the manager binds. */ export type ManagedShader = { _UID: string; program: WebGLProgram | null; attributes: (number | undefined)[] | null; }; export declare class WebGLShaderManager { gl: IdentifiedWebGLRenderingContext; primitiveShader: PrimitiveShader | null; complexPrimitiveShader: ComplexPrimitiveShader | null; defaultShader: NormalShader | null; fastShader: FastShader | null; stripShader: StripShader | null; maxAttibs: number; attribState: (boolean | undefined)[]; tempAttribState: (boolean | undefined)[]; stack: ManagedShader[]; currentShader: ManagedShader | null; _currentId: string | null; /** * Initializes the shader manager with a WebGL context. */ constructor(); /** * Initializes the shader manager with a WebGL context. * @param {WebGLRenderingContext & { id: number }} gl - The WebGL rendering context. */ setContext(gl: IdentifiedWebGLRenderingContext): void; /** * Sets up the shader manager for WebGL rendering. * @param {number[]} attribs - The attribute locations to set up. */ setAttribs(attribs: (number | undefined)[]): void; /** * Sets up the shader manager for WebGL rendering. * @param {NormalShader} shader - The shader to set up. * @returns {boolean} Whether the shader setup was successful. */ setShader(shader: ManagedShader): boolean; /** * Destroys the manager. */ destroy(): void; } //# sourceMappingURL=shader_manager.d.ts.map