A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://developer.mozilla.org/en-US/docs/Web/API/WebGLRenderingContext/framebufferTexture2D below:

WebGLRenderingContext: framebufferTexture2D() method - Web APIs

WebGLRenderingContext: framebufferTexture2D() method

Baseline Widely available

Note: This feature is available in Web Workers.

The WebGLRenderingContext.framebufferTexture2D() method of the WebGL API attaches a texture to a WebGLFramebuffer.

Syntax
framebufferTexture2D(target, attachment, textarget, texture, level)
Parameters
target

A GLenum specifying the binding point (target). Possible values:

gl.FRAMEBUFFER

Collection buffer data storage of color, alpha, depth and stencil buffers used to render an image.

When using a WebGL 2 context, the following values are available additionally:

gl.DRAW_FRAMEBUFFER

Used as a destination for drawing, rendering, clearing, and writing operations.

gl.READ_FRAMEBUFFER

Used as a source for reading operations.

When binding, gl.FRAMEBUFFER sets both the gl.DRAW_FRAMEBUFFER and gl.READ_FRAMEBUFFER binding points. When referencing, gl.FRAMEBUFFER refers to the gl.DRAW_FRAMEBUFFER binding

attachment

A GLenum specifying the attachment point for the texture. Possible values:

When using a WebGL 2 context, the following values are available additionally:

When using the WEBGL_draw_buffers extension:

When using the WEBGL_depth_texture extension:

textarget

A GLenum specifying the texture target. Possible values:

texture

A WebGLTexture object whose image to attach.

level

A GLint specifying the mipmap level of the texture image to be attached. Must be 0.

Return value

None (undefined).

Exceptions Examples
gl.framebufferTexture2D(
  gl.FRAMEBUFFER,
  gl.COLOR_ATTACHMENT0,
  gl.TEXTURE_2D,
  texture,
  0,
);
Specifications Browser compatibility See also

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4