new PIXI.NoiseFilter (noise, seed) overrides
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
noise |
number |
<optional> |
0.5 |
The noise intensity, should be a normalized value in the range [0, 1]. |
seed |
number |
<optional> |
A random seed for the noise generation. Default is |
Extends
Members
The amount of noise to apply, this value should be in the range (0, 1].
- Default Value:
- 0.5
A seed value to apply to the random noise generation. Math.random()
is a good value to use.
Inherited Properties
From class PIXI.Filter
autoFit boolean inherited
If enabled, PixiJS will fit the filter area into boundaries for better performance. Switch it off if it does not work for specific shader.
- Default Value:
- true
blendMode PIXI.BLEND_MODES inherited
Sets the blend mode of the filter.
- Default Value:
- PIXI.BLEND_MODES.NORMAL
enabled boolean inherited
If enabled is true the filter is applied, if false it will not.
legacy boolean readonly inherited
Legacy filters use position and uvs from attributes (set by filter system)
multisample PIXI.MSAA_QUALITY | null inherited
The samples override of the filter instance.
If set to null
, the sample count of the current render target is used.
- Default Value:
- PIXI.Filter.defaultMultisample
padding number inherited
The padding of the filter. Some filters require extra space to breath such as a blur. Increasing this will add extra width and height to the bounds of the object that the filter is applied to.
resolution number | null inherited
The resolution of the filter. Setting this to be lower will lower the quality but
increase the performance of the filter.
If set to null
or 0
, the resolution of the current render target is used.
- Default Value:
- PIXI.Filter.defaultResolution
state PIXI.State inherited
The WebGL state the filter requires to render.
From class PIXI.Shader
program PIXI.Program inherited
Program that the shader uses.
uniforms Dict<any> readonly inherited
Shader uniform values, shortcut for uniformGroup.uniforms
.
Inherited Methods
From class PIXI.Filter
apply (filterManager, input, output, clearMode, _currentState) void inherited
Applies the filter
Name | Type | Attributes | Description |
---|---|---|---|
filterManager |
PIXI.FilterSystem |
The renderer to retrieve the filter from |
|
input |
PIXI.RenderTexture |
The input render target. |
|
output |
PIXI.RenderTexture |
The target to output to. |
|
clearMode |
PIXI.CLEAR_MODES |
<optional> |
Should the output be cleared before rendering to it. |
_currentState |
object |
<optional> |
It's current state of filter. There are some useful properties in the currentState : target, filters, sourceFrame, destinationFrame, renderTarget, resolution |