FrameBuffer

FrameBuffer

Members

Methods

new FrameBuffer(gl, width, height, optionsopt)

Constructs a new FrameBuffer
Parameters
Name Type Attributes Default Description
gl object webgl context
width number width
height number height
options object <optional>
{} options
Properties
Name Type Attributes Default Description
depth boolean <optional>
false using depthTexture

Methods

bind()

Bind the framebuffer

clear()

Clear the framebuffer

setSize(width, height)

Set the size of the framebuffer
Parameters
Name Type Description
width number width
height number height

unbind()

Unbind the framebuffer