Add SpriteFX Pipeline to const and default array

This commit is contained in:
Richard Davey 2021-10-11 18:49:13 +01:00
parent b73d889ca9
commit 7af3693fb5
3 changed files with 18 additions and 3 deletions

View file

@ -16,6 +16,7 @@ var MultiPipeline = require('./pipelines/MultiPipeline');
var PointLightPipeline = require('./pipelines/PointLightPipeline');
var RopePipeline = require('./pipelines/RopePipeline');
var SinglePipeline = require('./pipelines/SinglePipeline');
var SpriteFXPipeline = require('./pipelines/SpriteFXPipeline');
var UtilityPipeline = require('./pipelines/UtilityPipeline');
/**
@ -26,7 +27,7 @@ var UtilityPipeline = require('./pipelines/UtilityPipeline');
* The `WebGLRenderer` owns a single instance of the Pipeline Manager, which you can access
* via the `WebGLRenderer.pipelines` property.
*
* By default, there are 8 pipelines installed into the Pipeline Manager when Phaser boots:
* By default, there are 9 pipelines installed into the Pipeline Manager when Phaser boots:
*
* 1. The Multi Pipeline. Responsible for all multi-texture rendering, i.e. Sprites and Tilemaps.
* 2. The Graphics Pipeline. Responsible for rendering Graphics and Shape objects.
@ -36,6 +37,7 @@ var UtilityPipeline = require('./pipelines/UtilityPipeline');
* 6. The Single Pipeline. Responsible for rendering Game Objects that explicitly require one bound texture.
* 7. The Bitmap Mask Pipeline. Responsible for Bitmap Mask rendering.
* 8. The Utility Pipeline. Responsible for providing lots of handy texture manipulation functions.
* 9. The Sprite FX Pipeline.
*
* You can add your own custom pipeline via the `PipelineManager.add` method. Pipelines are
* identified by unique string-based keys.
@ -88,7 +90,8 @@ var PipelineManager = new Class({
[ CONST.ROPE_PIPELINE, RopePipeline ],
[ CONST.LIGHT_PIPELINE, LightPipeline ],
[ CONST.POINTLIGHT_PIPELINE, PointLightPipeline ],
[ CONST.GRAPHICS_PIPELINE, GraphicsPipeline ]
[ CONST.GRAPHICS_PIPELINE, GraphicsPipeline ],
[ CONST.SPRITEFX_PIPELINE, SpriteFXPipeline ]
]);
/**

View file

@ -94,7 +94,18 @@ var PIPELINE_CONST = {
* @const
* @since 3.50.0
*/
UTILITY_PIPELINE: 'UtilityPipeline'
UTILITY_PIPELINE: 'UtilityPipeline',
/**
* The Sprite FX Pipeline.
*
* @name Phaser.Renderer.WebGL.Pipelines.SPRITEFX_PIPELINE
* @type {string}
* @const
* @since 3.60.0
*/
SPRITEFX_PIPELINE: 'SpriteFXPipeline'
};
module.exports = PIPELINE_CONST;

View file

@ -22,6 +22,7 @@ var Pipelines = {
PostFXPipeline: require('./PostFXPipeline'),
RopePipeline: require('./RopePipeline'),
SinglePipeline: require('./SinglePipeline'),
SpriteFXPipeline: require('./SpriteFXPipeline'),
UtilityPipeline: require('./UtilityPipeline')
};