import type { FramebufferProps } from '@luma.gl/api'; import { Device } from '@luma.gl/api'; import GL from '@luma.gl/constants'; import { WEBGLTexture } from '@luma.gl/webgl'; import Renderbuffer from './renderbuffer'; import Texture from './texture'; import { WEBGLFramebuffer } from '@luma.gl/webgl'; export declare type TextureAttachment = [Texture, number?, number?]; export declare type Attachment = WEBGLTexture | Renderbuffer | TextureAttachment | null; export declare type Attachments = Record; /** @deprecated backwards compatibility props */ export declare type ClassicFramebufferProps = FramebufferProps & { attachments?: Attachments; readBuffer?: number; drawBuffers?: number[]; check?: boolean; width?: number; height?: number; color?: boolean; depth?: boolean; stencil?: boolean; }; declare type ColorBufferFloatOptions = { colorBufferFloat?: boolean; colorBufferHalfFloat?: boolean; }; /** @deprecated Use device.createFramebuffer() */ export default class ClassicFramebuffer extends WEBGLFramebuffer { attachments: Attachments; readBuffer: GL; drawBuffers: GL[]; ownResources: unknown[]; static readonly FRAMEBUFFER_ATTACHMENT_PARAMETERS: GL[]; /** * Check color buffer float support * @param options.colorBufferFloat Whether floating point textures can be rendered and read * @param options.colorBufferHalfFloat Whether half float textures can be rendered and read */ static isSupported(device: Device | WebGLRenderingContext, options: ColorBufferFloatOptions): boolean; /** * returns the default Classic * Creates a Framebuffer object wrapper for the default WebGL framebuffer (target === null) */ static getDefaultFramebuffer(device: Device | WebGLRenderingContext): ClassicFramebuffer; get MAX_COLOR_ATTACHMENTS(): number; get MAX_DRAW_BUFFERS(): number; constructor(device: Device | WebGLRenderingContext, props?: ClassicFramebufferProps); get color(): WEBGLTexture; get texture(): WEBGLTexture; get depth(): WEBGLTexture; get stencil(): WEBGLTexture; initialize(props: ClassicFramebufferProps): void; checkStatus(): this; getStatus(): number; bind({ target }?: { target?: GL; }): this; unbind({ target }?: { target?: GL; }): this; /** @note Expects framebuffer to be bound */ _setReadBuffer(readBuffer: number): void; /** @note Expects framebuffer to be bound */ _setDrawBuffers(drawBuffers: number[]): void; _createHandle(): WebGLFramebuffer; _deleteHandle(): void; _bindHandle(handle: WebGLFramebuffer): unknown; update(options: { attachments: Record; readBuffer?: number; drawBuffers?: number[]; clearAttachments?: boolean; resizeAttachments?: boolean; }): this; /** Attach from a map of attachments */ attach(attachments: Attachments, { clearAttachments, resizeAttachments }?: { clearAttachments?: boolean; resizeAttachments?: boolean; }): void; clear(options?: { color?: any; depth?: any; stencil?: any; drawBuffers?: any[]; }): this; blit(opts?: {}): any; invalidate(options: { attachments: []; x?: number; y?: number; width: number; height: number; }): this; getAttachmentParameter(attachment: number, pname: GL, keys?: boolean): number; getAttachmentParameters(attachment?: GL, keys?: boolean, parameters?: any): Record; getParameters(keys?: boolean): Record; show(): this; log(logLevel?: number, message?: string): this; _unattach(attachment: GL): void; /** * Attempt to provide workable defaults for WebGL2 symbols under WebGL1 * null means OK to query * TODO - move to webgl1 polyfills * @param pname * @returns */ _getAttachmentParameterFallback(pname: GL): number; } export {}; //# sourceMappingURL=framebuffer.d.ts.map