aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/RDGE/GLSubpath.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/helper-classes/RDGE/GLSubpath.js')
-rw-r--r--js/helper-classes/RDGE/GLSubpath.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/js/helper-classes/RDGE/GLSubpath.js b/js/helper-classes/RDGE/GLSubpath.js
index 52699f85..fd2f3560 100644
--- a/js/helper-classes/RDGE/GLSubpath.js
+++ b/js/helper-classes/RDGE/GLSubpath.js
@@ -141,6 +141,7 @@ function GLSubpath() {
141 var lineCap = ['butt','round','square']; 141 var lineCap = ['butt','round','square'];
142 ctx.lineCap = lineCap[1]; 142 ctx.lineCap = lineCap[1];
143 ctx.beginPath(); 143 ctx.beginPath();
144
144 var prevAnchor = this.getAnchor(0); 145 var prevAnchor = this.getAnchor(0);
145 ctx.moveTo(prevAnchor.getPosX()-bboxMin[0],prevAnchor.getPosY()-bboxMin[1]); 146 ctx.moveTo(prevAnchor.getPosX()-bboxMin[0],prevAnchor.getPosY()-bboxMin[1]);
146 for (var i = 1; i < numAnchors; i++) { 147 for (var i = 1; i < numAnchors; i++) {
@@ -156,8 +157,15 @@ function GLSubpath() {
156 if (this._isClosed){ 157 if (this._isClosed){
157 ctx.fill(); 158 ctx.fill();
158 } 159 }
159 ctx.stroke();
160 160
161 /*
162 var numPoints = this._samples.length/3;
163 ctx.moveTo(this._samples[0],this._samples[1]);
164 for (var i=0;i<numPoints;i++){
165 ctx.lineTo(this._samples[3*i]-bboxMin[0],this._samples[3*i + 1]-bboxMin[1]);
166 }
167 */
168 ctx.stroke();
161 ctx.restore(); 169 ctx.restore();
162 } //render() 170 } //render()
163 171