Filter#Filter

new Filter(game, uniforms, fragmentSrc)

This is a base Filter class to use for any Phaser filter development.

The vast majority of filters (including all of those that ship with Phaser) use fragment shaders, and
therefore only work in WebGL and are not supported by Canvas at all.

Parameters
Name Type Description
game Phaser.Game

A reference to the currently running game.

uniforms object

Uniform mappings object

fragmentSrc Array | string

The fragment shader code. Either an array, one element per line of code, or a string.

Source code: core/Filter.js (Line 19)
doc_phaser
2017-02-14 10:45:55
Comments
Leave a Comment

Please login to continue.