diff --git a/src/core/shader/generateUniformsSync.js b/src/core/shader/generateUniformsSync.js index b8cdfdc..8c01351 100644 --- a/src/core/shader/generateUniformsSync.js +++ b/src/core/shader/generateUniformsSync.js @@ -119,7 +119,7 @@ } // console.log(' --------------- ') - console.log(func); + // console.log(func); return new Function('uniformData', 'uniformValues', 'gl', func); // eslint-disable-line no-new-func } diff --git a/src/core/shader/generateUniformsSync.js b/src/core/shader/generateUniformsSync.js index b8cdfdc..8c01351 100644 --- a/src/core/shader/generateUniformsSync.js +++ b/src/core/shader/generateUniformsSync.js @@ -119,7 +119,7 @@ } // console.log(' --------------- ') - console.log(func); + // console.log(func); return new Function('uniformData', 'uniformValues', 'gl', func); // eslint-disable-line no-new-func } diff --git a/src/mesh/Mesh.js b/src/mesh/Mesh.js index 3747883..f0aaa89 100644 --- a/src/mesh/Mesh.js +++ b/src/mesh/Mesh.js @@ -130,8 +130,10 @@ } /** - * Returns the bounds of the mesh as a rectangle. The bounds calculation takes the worldTransform into account. + * Updates the bounds of the mesh as a rectangle. The bounds calculation takes the worldTransform into account. + * there must be a aVertexPosition attribute present in the geometry for bounds to be calcualted correctly. * + * @private */ _calculateBounds() { @@ -143,21 +145,16 @@ // TODO - we can cache local bounds and use them if they are dirty (like graphics) this._bounds.addVertices(this.transform, vertices, 0, vertices.length); } - else - { - return core.Rectangle.EMPTY; - } - } - /** + /** * Tests if a point is inside this mesh. Works only for TRIANGLE_MESH * - * @param point {PIXI.Point} the point to test + * @param {PIXI.Point} point the point to test * @return {boolean} the result of the test */ - containsPoint(point) - { + containsPoint(point) + { if (!this.getBounds().contains(point.x, point.y)) { return false; @@ -192,8 +189,9 @@ } return false; - } + } } + /** * Different drawing buffer modes supported *