Classes
- AlphaFilter
- BlurFilter
- BlurFilterPass
- ColorBlend
- ColorBurnBlend
- ColorDodgeBlend
- ColorMatrixFilter
- DarkenBlend
- DifferenceBlend
- DisplacementFilter
- DivideBlend
- ExclusionBlend
- Filter
- HardLightBlend
- HardMixBlend
- LightenBlend
- LinearBurnBlend
- LinearDodgeBlend
- LinearLightBlend
- LuminosityBlend
- NoiseFilter
- PinLightBlend
- SubtractBlend
Interface Definitions
-
Options for AlphaFilter
Properties:
Name Type Default Description alphanumber 1Amount of alpha from 0 to 1, where 0 is transparent
-
Options for BlurFilter
Properties:
Name Type Default Description kernelSizenumber 5The kernelSize of the blur filter.Options: 5, 7, 9, 11, 13, 15.
qualitynumber 4The quality of the blur filter.
strengthnumber 8The strength of the blur filter.
strengthXnumber 8The horizontal strength of the blur.
strengthYnumber 8The vertical strength of the blur.
-
Options for BlurFilterPass
Properties:
Name Type Description horizontalboolean Do pass along the x-axis (
true) or y-axis (false). -
Options for DisplacementFilter
-
The options to use when creating a new filter.
Properties:
Name Type Description antialiasFilterAntialias | boolean If true the filter will make use of antialiasing. Although it looks better this can have a performance impact. If set to 'inherit', the filter will detect the antialiasing of the render target and change this automatically. Definitely don't set this to true if the render target has antialiasing set to false. As it will antialias, but you won't see the difference. (default 'off')
This can be a boolean or FilterAntialias string.
blendModeBLEND_MODES optional blend mode used by the filter when rendering (defaults to 'normal')
blendRequiredboolean If this is set to true, the filter system will grab a snap shot of the area being rendered to and pass this into the shader. This is useful for blend modes that need to be aware of the pixels they are rendering to. Only use if you need that data, otherwise its an extra gpu copy you don't need! (default false)
paddingnumber the amount of pixels to pad the container with when applying the filter. For example a blur extends the container out as it blurs, so padding is applied to ensure that extra detail is rendered as well without clipping occurring. (default 0)
resolutionnumber | "inherit" the resolution the filter should be rendered at. The lower the resolution, the more performant the filter will be, but the lower the quality of the output. (default 1) If 'inherit', the resolution of the render target is used. Consider lowering this for things like blurs filters
-
Options for NoiseFilter
Properties:
Name Type Description noisenumber The amount of noise to apply, this value should be in the range (0, 1].
seednumber A seed value to apply to the random noise generation.
Math.random()is a good value to use.
Type Definitions
Various blend modes supported by Pixi
5x4 matrix for transforming RGBA color and alpha
The antialiasing mode of the filter. This can be either:
on- the filter is always antialiased regardless of the render target settingsoff- (default) the filter is never antialiased regardless of the render target settingsinherit- the filter uses the antialias settings of the render target