diff --git a/.eslintrc.json b/.eslintrc.json index b8d7d05..aaab877 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -103,7 +103,7 @@ "no-unused-labels": 1, "no-useless-call": 1, "no-useless-concat": 1, - "no-useless-escape": 1, + "no-useless-escape": 0, "no-void": 1, "no-warning-comments": 0, "no-with": 1, diff --git a/.eslintrc.json b/.eslintrc.json index b8d7d05..aaab877 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -103,7 +103,7 @@ "no-unused-labels": 1, "no-useless-call": 1, "no-useless-concat": 1, - "no-useless-escape": 1, + "no-useless-escape": 0, "no-void": 1, "no-warning-comments": 0, "no-with": 1, diff --git a/src/core/graphics/webgl/utils/buildRectangle.js b/src/core/graphics/webgl/utils/buildRectangle.js index f2bba78..84f44b6 100644 --- a/src/core/graphics/webgl/utils/buildRectangle.js +++ b/src/core/graphics/webgl/utils/buildRectangle.js @@ -58,10 +58,10 @@ const tempPoints = graphicsData.points; graphicsData.points = [x, y, - x + width, y, - x + width, y + height, - x, y + height, - x, y]; + x + width, y, + x + width, y + height, + x, y + height, + x, y]; buildLine(graphicsData, webGLData); diff --git a/.eslintrc.json b/.eslintrc.json index b8d7d05..aaab877 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -103,7 +103,7 @@ "no-unused-labels": 1, "no-useless-call": 1, "no-useless-concat": 1, - "no-useless-escape": 1, + "no-useless-escape": 0, "no-void": 1, "no-warning-comments": 0, "no-with": 1, diff --git a/src/core/graphics/webgl/utils/buildRectangle.js b/src/core/graphics/webgl/utils/buildRectangle.js index f2bba78..84f44b6 100644 --- a/src/core/graphics/webgl/utils/buildRectangle.js +++ b/src/core/graphics/webgl/utils/buildRectangle.js @@ -58,10 +58,10 @@ const tempPoints = graphicsData.points; graphicsData.points = [x, y, - x + width, y, - x + width, y + height, - x, y + height, - x, y]; + x + width, y, + x + width, y + height, + x, y + height, + x, y]; buildLine(graphicsData, webGLData); diff --git a/src/mesh/Mesh.js b/src/mesh/Mesh.js index d9f6c69..21e5a61 100644 --- a/src/mesh/Mesh.js +++ b/src/mesh/Mesh.js @@ -36,9 +36,9 @@ * @member {Float32Array} */ this.uvs = uvs || new Float32Array([0, 0, - 1, 0, - 1, 1, - 0, 1]); + 1, 0, + 1, 1, + 0, 1]); /** * An array of vertices @@ -46,9 +46,9 @@ * @member {Float32Array} */ this.vertices = vertices || new Float32Array([0, 0, - 100, 0, - 100, 100, - 0, 100]); + 100, 0, + 100, 100, + 0, 100]); /* * @member {Uint16Array} An array containing the indices of the vertices diff --git a/.eslintrc.json b/.eslintrc.json index b8d7d05..aaab877 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -103,7 +103,7 @@ "no-unused-labels": 1, "no-useless-call": 1, "no-useless-concat": 1, - "no-useless-escape": 1, + "no-useless-escape": 0, "no-void": 1, "no-warning-comments": 0, "no-with": 1, diff --git a/src/core/graphics/webgl/utils/buildRectangle.js b/src/core/graphics/webgl/utils/buildRectangle.js index f2bba78..84f44b6 100644 --- a/src/core/graphics/webgl/utils/buildRectangle.js +++ b/src/core/graphics/webgl/utils/buildRectangle.js @@ -58,10 +58,10 @@ const tempPoints = graphicsData.points; graphicsData.points = [x, y, - x + width, y, - x + width, y + height, - x, y + height, - x, y]; + x + width, y, + x + width, y + height, + x, y + height, + x, y]; buildLine(graphicsData, webGLData); diff --git a/src/mesh/Mesh.js b/src/mesh/Mesh.js index d9f6c69..21e5a61 100644 --- a/src/mesh/Mesh.js +++ b/src/mesh/Mesh.js @@ -36,9 +36,9 @@ * @member {Float32Array} */ this.uvs = uvs || new Float32Array([0, 0, - 1, 0, - 1, 1, - 0, 1]); + 1, 0, + 1, 1, + 0, 1]); /** * An array of vertices @@ -46,9 +46,9 @@ * @member {Float32Array} */ this.vertices = vertices || new Float32Array([0, 0, - 100, 0, - 100, 100, - 0, 100]); + 100, 0, + 100, 100, + 0, 100]); /* * @member {Uint16Array} An array containing the indices of the vertices diff --git a/src/mesh/webgl/MeshRenderer.js b/src/mesh/webgl/MeshRenderer.js index d2625d4..bca810c 100644 --- a/src/mesh/webgl/MeshRenderer.js +++ b/src/mesh/webgl/MeshRenderer.js @@ -77,7 +77,6 @@ if (mesh.dirty !== glData.dirty) { - glData.dirty = mesh.dirty; glData.uvBuffer.upload(mesh.uvs); } @@ -88,7 +87,6 @@ glData.indexBuffer.upload(mesh.indices); } - glData.vertexBuffer.upload(mesh.vertices); renderer.bindShader(glData.shader);