import { n as ImageBuffer, r as ImageConverterInstance, t as BitmapWithFormat } from "../sdcCoreInternalSdkCommonGeometry-BF4xvjjS.js"; //#region src/main/private/ImageConverterBase.d.ts type CanvasType = HTMLCanvasElement | OffscreenCanvas; type CanvasContextType = CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D; declare abstract class ImageConverterBase implements ImageConverterInstance { protected readonly options: { quality: number; }; protected canvas?: CanvasType; protected context?: CanvasContextType; protected static readonly JPEG_IMAGE_MIME_TYPE = "image/jpeg"; constructor(options: { quality: number; }); /** * Should return a new canvas for the current runtime. Usually an HTMLCanvasElement or an OffscreenCanvas. */ protected abstract getNewCanvas(width: number, height: number): CanvasType; /** * Should convert the canvas to a JPEG blob. */ protected abstract canvasToBlob(canvas: CanvasType): Promise; get quality(): number; convertToJpeg(imageBuffer: ImageBuffer, orientation: number): Promise; convertToBitmap(imageBuffer: ImageBuffer): BitmapWithFormat; private validateAndExtractImageData; private prepareCanvas; private processImageData; private validateImageData; private convertToJpegBytes; private ensureCanvas; private createImageDataFromBuffer; private isYUVFormat; private isRGBAFormat; private isRGBFormat; private isGrayscaleFormat; private createImageDataFromRGBAPlanes; private createImageDataFromRGBPlanes; private createImageDataFromGrayscalePlanes; private getPixelFromPlane; private applyRotation; } //#endregion export { ImageConverterBase };