Class: BlendModePipe
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:27
Internal
This Pipe handles the blend mode switching of the renderer. It will insert instructions into the InstructionSet to switch the blend mode according to the blend modes of the scene graph.
This pipe is were wwe handle Advanced blend modes. Advanced blend modes essentially wrap the renderables in a filter that applies the blend mode.
You only need to use this class if you are building your own render instruction set rather than letting PixiJS build the instruction set for you by traversing the scene graph
Implements
InstructionPipe<AdvancedBlendInstruction>
Constructors
Constructor
> new BlendModePipe(renderer): BlendModePipe
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:39
Parameters
renderer
Returns
BlendModePipe
Methods
buildEnd()
> buildEnd(instructionSet): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:76
Internal
called when the instruction build process is finished, ensuring that if there is an advanced blend mode active, we add the final render instructions added to the instruction set
Parameters
instructionSet
The instruction set we are adding to
Returns
void
Implementation of
buildStart()
> buildStart(): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:69
Internal
called when the instruction build process is starting this will reset internally to the default blend mode
Returns
void
Implementation of
destroy()
> destroy(): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:78
Internal
Returns
void
popBlendMode()
> popBlendMode(instructionSet): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:52
Pop the last blend mode from the stack and apply the new top-of-stack mode.
Parameters
instructionSet
The instruction set being built.
Returns
void
prerender()
> prerender(): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:40
Returns
void
pushBlendMode()
> pushBlendMode(renderable, blendMode, instructionSet): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:47
Push a blend mode onto the internal stack and apply it to the instruction set if needed.
Parameters
renderable
The renderable or RenderGroup associated with the change.
blendMode
The blend mode to activate.
instructionSet
The instruction set being built.
Returns
void
setBlendMode()
> setBlendMode(renderable, blendMode, instructionSet): void
Defined in: node_modules/pixi.js/lib/rendering/renderers/shared/blendModes/BlendModePipe.d.ts:61
Ensure a blend mode switch is added to the instruction set when the mode changes. If an advanced blend mode is active, subsequent renderables will be collected so they can be rendered within a single filter pass.
Parameters
renderable
RenderGroup | Renderable | null
The renderable or RenderGroup to associate with the change, or null when unwinding.
blendMode
The target blend mode.
instructionSet
The instruction set being built.
Returns
void