Phaser API Documentation

  Version: 
pushFramebuffer(framebuffer, [updateScissor], [resetTextures], [setViewport])

Description:

Pushes a new framebuffer onto the FBO stack and makes it the currently bound framebuffer.

If there was another framebuffer already bound it will force a pipeline flush.

Call popFramebuffer to remove it again.

Parameters:

name type arguments Default description
framebuffer WebGLFramebuffer

The framebuffer that needs to be bound.

updateScissor boolean <optional> false

Set the gl scissor to match the frame buffer size? Or, if null given, pop the scissor from the stack.

resetTextures boolean <optional> false

Should the WebGL Textures be reset after the new framebuffer is bound?

setViewport boolean <optional> true

Should the WebGL viewport be set?

Returns:
Description:

This WebGLRenderer instance.

Examples:
Since: 3.50.0