export declare enum InterpolationMethod { Nearest = "nearest" } /** * Resizes an image from the source dimensions to target dimensions. * * @param {Uint8ClampedArray} imageData The source image data in Uint8ClampedArray format. * @param {number} srcWidth The width of the source image. * @param {number} srcHeight The height of the source image. * @param {number} targetWidth The width of the target image. * @param {number} targetHeight The height of the target image. * * @returns {Uint8ClampedArray} The target image data in Uint8ClampedArray format. * * @example * const targetData = resizeImage(sourceData, 800, 600, 400, 300); * * @note The function uses a "nearest neighbor" algorithm for resizing, * which is fast but might not provide the best quality for all images. */ export declare const resizeImage: (imageData: Uint8ClampedArray, srcWidth: number, srcHeight: number, targetWidth: number, targetHeight: number) => Uint8ClampedArray; /** * Upsamples an image using the bilinear interpolation method. The input image is expected to be in * Float32Array format. The output image is in Uint8ClampedArray format. The input image is expected * to be in the [0, 1] range. The output image is in the [0, 255] range. * * @param {Float32Array} input The input image data in Float32Array format. * @param {number} srcWidth The width of the source image. * @param {number} srcHeight The height of the source image. * @param {number} targetWidth The width of the target image. * @param {number} targetHeight The height of the target image. * * @returns {Uint8ClampedArray} The upsampled image data in Uint8ClampedArray format. * */ export declare function bilinearUpsample(input: Float32Array, srcWidth: number, srcHeight: number, targetWidth: number, targetHeight: number): Uint8ClampedArray; /** * Upsamples an image using the Lanczos3 interpolation method. The input image is expected to be in * Float32Array format. The output image is in Uint8ClampedArray format. The input image is expected * to be in the [0, 1] range. The output image is in the [0, 255] range. * * @param {Float32Array} input The input image data in Float32Array format. * @param {number} srcWidth The width of the source image. * @param {number} srcHeight The height of the source image. * @param {number} targetWidth The width of the target image. * @param {number} targetHeight The height of the target image. * * @returns {Uint8ClampedArray} The upsampled image data in Uint8ClampedArray format. */ export declare function lanczos3Upsample(input: Float32Array, srcWidth: number, srcHeight: number, targetWidth: number, targetHeight: number): Uint8ClampedArray; export declare function compileShader(gl: WebGL2RenderingContext, shader_type: number, source: string): WebGLShader; export declare function linkProgram(gl: WebGL2RenderingContext, vertex_shader: WebGLShader, fragment_shader: WebGLShader): WebGLProgram; /** * Determines if a URI is already resolved. * A resolved URI is either: * - A blob URL (starts with 'blob:') * - A fully qualified URL (e.g., http:// or https://) * * @param uri - The URI to check. * @returns Whether the URI is already resolved. */ export declare function isResolvedUri(uri: string): boolean; export declare const toAbsoluteURI: (relativeURL: string, baseURL?: string) => string;