import type { Texture } from '../texture.js'; /** The extra texture parameters a sampler uniform may carry, as the consumer supplied them. */ export type ShaderTextureData = { magFilter?: GLenum; minFilter?: GLenum; wrapS?: GLenum; wrapT?: GLenum; luminance?: boolean; repeat?: boolean; flipY?: boolean; width?: number; height?: number; border?: number; }; /** A sampler uniform, whose value is the texture to bind. */ export type SamplerUniform = ShaderUniform & { value: Texture | null; }; /** A vector uniform value, read component-wise by the setter matching its arity. */ export type UniformVector = { x: number; y: number; z?: number; w?: number; }; export type ShaderUniform = { type: string; value: unknown; uniformLocation?: WebGLUniformLocation | null; /** One of the gl uniform setters. Their arities differ by uniform kind, so the stored value is * opaque and applied through callUniformSetter. */ glFunc?: unknown; glMatrix?: boolean; glValueLength?: number; transpose?: boolean; textureData?: ShaderTextureData; _init?: boolean; }; export declare class NormalShader { gl: WebGLRenderingContext & { id: number; }; _UID: string; program: WebGLProgram | null; fragmentSrc: string[]; vertexSrc: string[] | null; textureCount: number; firstRun: boolean; dirty: boolean; uniforms: Record; attributes: number[]; uSampler: WebGLUniformLocation | null; projectionVector: WebGLUniformLocation | null; offsetVector: WebGLUniformLocation | null; dimensions: WebGLUniformLocation | null; aVertexPosition: number; aTextureCoord: number; colorAttribute: number; /** * Creates a new NormalShader instance. * @param {WebGLRenderingContext & { id: number }} gl - The WebGL rendering context. */ constructor(gl: WebGLRenderingContext & { id: number; }); /** * Destroys this shader and cleans up resources. */ init(): void; /** * Binds this shader to the WebGL context. */ initUniforms(): void; /** * Sets a uniform value for this shader. * @param {object} uniform - The uniform to set. */ initSampler2D(uniform: SamplerUniform): void; /** * Sets the shader to use for rendering. */ syncUniforms(): void; /** * Destroys this shader and cleans up resources. */ destroy(): void; } //# sourceMappingURL=normal.d.ts.map