mirror of
https://github.com/photonstorm/phaser
synced 2024-12-03 18:10:10 +00:00
Renamed Renderer spriteBatch to just batch.
This commit is contained in:
parent
a271a52ec7
commit
8de992175e
4 changed files with 10 additions and 10 deletions
|
@ -24,7 +24,7 @@ Phaser.Renderer.WebGL.GameObjects.Image = {
|
|||
var tint = src.color._glTint;
|
||||
var bg = src.color._glBg;
|
||||
|
||||
renderer.spriteBatch.addToBatch(src, verts, uvs, index, alpha, tint, bg);
|
||||
renderer.batch.add(src, verts, uvs, index, alpha, tint, bg);
|
||||
|
||||
/*
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ Phaser.Renderer.WebGL.GameObjects.Sprite = {
|
|||
// Would be good to get this down to 1 check, or even none.
|
||||
if (src._mask || src._filters)
|
||||
{
|
||||
var spriteBatch = renderer.spriteBatch;
|
||||
var spriteBatch = renderer.batch;
|
||||
|
||||
// push filter first as we need to ensure the stencil buffer is correct for any masking
|
||||
if (src._filters)
|
||||
|
|
|
@ -366,7 +366,7 @@ Phaser.Renderer.WebGL.BatchManager.prototype = {
|
|||
}
|
||||
},
|
||||
|
||||
addToBatch: function (gameObject, verts, uvs, textureIndex, alpha, tintColors, bgColors)
|
||||
add: function (gameObject, verts, uvs, textureIndex, alpha, tintColors, bgColors)
|
||||
{
|
||||
// console.log('addToBatch', gameObject.frame.name);
|
||||
|
||||
|
|
|
@ -140,10 +140,10 @@ Phaser.Renderer.WebGL = function (game)
|
|||
|
||||
/**
|
||||
* Manages the rendering of sprites
|
||||
* @property spriteBatch
|
||||
* @property batch
|
||||
* @type WebGLSpriteBatch
|
||||
*/
|
||||
this.spriteBatch = new Phaser.Renderer.WebGL.BatchManager(this, 2000);
|
||||
this.batch = new Phaser.Renderer.WebGL.BatchManager(this, 2000);
|
||||
|
||||
/**
|
||||
* Manages the filters
|
||||
|
@ -234,7 +234,7 @@ Phaser.Renderer.WebGL.prototype = {
|
|||
gl.enable(gl.BLEND);
|
||||
|
||||
this.shaderManager.init();
|
||||
this.spriteBatch.init();
|
||||
this.batch.init();
|
||||
this.filterManager.init();
|
||||
this.stencilManager.init();
|
||||
|
||||
|
@ -453,7 +453,7 @@ Phaser.Renderer.WebGL.prototype = {
|
|||
|
||||
// console.log('render');
|
||||
|
||||
this.spriteBatch.begin();
|
||||
this.batch.begin();
|
||||
|
||||
// this.filterManager.begin();
|
||||
|
||||
|
@ -461,7 +461,7 @@ Phaser.Renderer.WebGL.prototype = {
|
|||
|
||||
stage.render(this, stage);
|
||||
|
||||
this.spriteBatch.end();
|
||||
this.batch.end();
|
||||
|
||||
// debugger;
|
||||
|
||||
|
@ -775,12 +775,12 @@ Phaser.Renderer.WebGL.prototype = {
|
|||
this.offset = null;
|
||||
|
||||
this.shaderManager.destroy();
|
||||
this.spriteBatch.destroy();
|
||||
this.batch.destroy();
|
||||
this.maskManager.destroy();
|
||||
this.filterManager.destroy();
|
||||
|
||||
this.shaderManager = null;
|
||||
this.spriteBatch = null;
|
||||
this.batch = null;
|
||||
this.maskManager = null;
|
||||
this.filterManager = null;
|
||||
|
||||
|
|
Loading…
Reference in a new issue