All swapped to using renderer matrices to make pipelines smaller

This commit is contained in:
Richard Davey 2020-10-28 16:52:59 +00:00
parent 327b31d561
commit 4ba2b0eb7b
15 changed files with 21 additions and 21 deletions

View file

@ -38,7 +38,7 @@ var DynamicBitmapTextWebGLRenderer = function (renderer, src, camera, parentMatr
var spriteMatrix = result.sprite;
var calcMatrix = result.calc;
var fontMatrix = pipeline._tempMatrix4;
var fontMatrix = renderer._tempMatrix4;
var crop = (src.cropWidth > 0 || src.cropHeight > 0);

View file

@ -34,7 +34,7 @@ var BlitterWebGLRenderer = function (renderer, src, camera, parentMatrix)
var cameraScrollX = camera.scrollX * src.scrollFactorX;
var cameraScrollY = camera.scrollY * src.scrollFactorY;
var calcMatrix = pipeline._tempMatrix1;
var calcMatrix = renderer._tempMatrix1;
calcMatrix.copyFrom(camera.matrix);

View file

@ -177,11 +177,11 @@ var PointLight = new Class({
renderWebGL: function (renderer, src, camera, parentTransformMatrix)
{
var pipeline = renderer.pipelines.set(this.pipeline);
renderer.pipelines.set(src.pipeline);
var camMatrix = pipeline._tempMatrix1;
var lightMatrix = pipeline._tempMatrix2;
var calcMatrix = pipeline._tempMatrix3;
var camMatrix = renderer._tempMatrix1;
var lightMatrix = renderer._tempMatrix2;
var calcMatrix = renderer._tempMatrix3;
var width = src.width;
var height = src.height;

View file

@ -32,10 +32,10 @@ var ParticleManagerWebGLRenderer = function (renderer, emitterManager, camera, p
var pipeline = renderer.pipelines.set(this.pipeline);
var camMatrix = pipeline._tempMatrix1;
var calcMatrix = pipeline._tempMatrix2;
var particleMatrix = pipeline._tempMatrix3;
var managerMatrix = pipeline._tempMatrix4;
var camMatrix = renderer._tempMatrix1;
var calcMatrix = renderer._tempMatrix2;
var particleMatrix = renderer._tempMatrix3;
var managerMatrix = renderer._tempMatrix4;
if (parentMatrix)
{

View file

@ -28,7 +28,7 @@ var ArcWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix1.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -28,7 +28,7 @@ var CurveWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX + src._curveBounds.x;
var dy = src._displayOriginY + src._curveBounds.y;

View file

@ -28,7 +28,7 @@ var EllipseWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -27,7 +27,7 @@ var GridWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
calcMatrix.translate(-src._displayOriginX, -src._displayOriginY);

View file

@ -27,7 +27,7 @@ var IsoBoxWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var size = src.width;
var height = src.height;

View file

@ -27,7 +27,7 @@ var IsoTriangleWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var size = src.width;
var height = src.height;

View file

@ -27,7 +27,7 @@ var LineWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
pipeline._tempMatrix3.copyFrom(result.calc);
renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -28,7 +28,7 @@ var PolygonWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -28,7 +28,7 @@ var RectangleWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
pipeline._tempMatrix3.copyFrom(result.calc);
renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -28,7 +28,7 @@ var StarWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
var calcMatrix = pipeline._tempMatrix3.copyFrom(result.calc);
var calcMatrix = renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;

View file

@ -28,7 +28,7 @@ var TriangleWebGLRenderer = function (renderer, src, camera, parentMatrix)
var result = GetCalcMatrix(src, camera, parentMatrix);
pipeline._tempMatrix3.copyFrom(result.calc);
renderer._tempMatrix3.copyFrom(result.calc);
var dx = src._displayOriginX;
var dy = src._displayOriginY;